# Help in sketching a CT signal with discontinuities

This is the Original signal:

And I'm supposed to sketch
$[x(t) + x(-t)] .u(t)$
I know that unit step signal will make the signal starts from 0 to $+\infty$
My problem is at key point (0) and key point (1)

• What happens if you sketch $x(-t)$, and then add up the two signals for $t>0$? It should be pretty straightforward. – Matt L. May 23 '16 at 14:30
• I did, but I'm a little confused. at (t=1) its amplitude equals 1 or 2 ? Sorry I'm just studying it for the first time – Hossam Houssien May 23 '16 at 14:42
• At $t=1$ you have a discontinuity. The left-sided limit should be $3$, and the right-sided limit is $1$. – Matt L. May 23 '16 at 15:57
• Firstly, thanks for your help. Secondly, I could solve it till this step. I got that the signal is zero's at $t<0$ and $t>2$ also in interval $0<t<1$ its amplitude is 3 "and it's correct according to solution manual of the book" and in $1<t<2$ its amplitude is equal to $-2t+3$ but this part is wrong "again according to the solution manual it should be $zero$" so any ideas how am I got wrong? – Hossam Houssien May 23 '16 at 17:24
• Your solution is correct, the solution manual is wrong if it says that the resulting signal is zero in the interval $[1,2]$. – Matt L. May 23 '16 at 18:49

You are right, the solution manual is wrong and here is a piecewise linear definition of the signal $[x(t)+x(-t)]u(t)$ based on the acceptance of $\text{u}(0) = 0.5$ (i.e. the value at a discontinuity is the half way between right and left ends) [x(t)+x(-t)]u(t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, t < 0}}\\&[1.5] &\scriptstyle{\text{, t = 0}}\\&3 &\scriptstyle{\text{, 0<t<1}}\\&[2] &\scriptstyle{\text{, t = 1}}\\-&2t+3 &\scriptstyle{\text{, 1<t<2}}\\&[-0.5] &\scriptstyle{\text{, t=2}}\\&0 &\scriptstyle{\text{, t > 2}}\\ \end{align} \end{cases}

Where the values within $[.]$ are points of discontinuities.

Let me put the steps to reach this conclusion in more details: Looking at the provided graph of $x(t)$ we can deduce a piecewise definition of the signal. However we must be causious about the possible discontinuities, for the sake of mathematical (continuous) function theory, those isolated points of discontinuities can be omitted entirely or as an engineering convention the value of the signal can be defined to be the half of the sum of its values at the right and left limits of the function at the discontinuity point. I'll accept this second definition, as DSP is concerned more with engineering than with pure mathematics.

Therefore, we have the definition of $x(t)$ as follows: x(t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, t < -2}}\\ &[-0.5] &\scriptstyle{\text{, t = -2}}\\ &t+1 &\scriptstyle{\text{, -2<t<-1}}\\ &[0.5] &\scriptstyle{\text{, t = -1}}\\ &1 &\scriptstyle{\text{, -1<t<0}}\\ &[1.5] &\scriptstyle{\text{, t=0}}\\ &2 &\scriptstyle{\text{, 0<t<1}}\\ &[1.5] &\scriptstyle{\text{, t=1}}\\ &-t+2 &\scriptstyle{\text{, 1<t<2}}\\ &0 &\scriptstyle{\text{, t>2}}\\ \end{align} \end{cases}

From which we can also deduce $x(-t)$ as follows: x(-t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, -t < -2}}\\ &[-0.5] &\scriptstyle{\text{, -t = -2}}\\ &-t+1 &\scriptstyle{\text{, -2<-t<-1}}\\ &[0.5] &\scriptstyle{\text{, -t = -1}}\\ &1 &\scriptstyle{\text{, -1<-t<0}}\\ &[1.5] &\scriptstyle{\text{, -t=0}}\\ &2 &\scriptstyle{\text{, 0<-t<1}}\\ &[1.5] &\scriptstyle{\text{, -t=1}}\\ &t+2 &\scriptstyle{\text{, 1<-t<2}}\\ &0 &\scriptstyle{\text{, -t>2}}\\ \end{align} \end{cases}

Observe carefully how every occurence of $t$ is replaced with $-t$ both in the defining formula of the function and also in the definition of its intervals. We shall reformat intervals of $x(-t)$ with positive $t$ as follows:

x(-t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, t > 2}}\\ &[-0.5] &\scriptstyle{\text{, t = 2}}\\ &-t+1 &\scriptstyle{\text{, 1<t<2}}\\ &[0.5] &\scriptstyle{\text{, t = 1}}\\ &1 &\scriptstyle{\text{, 0<t<1}}\\ &[1.5] &\scriptstyle{\text{, t=0}}\\ &2 &\scriptstyle{\text{, -1<t<0}}\\ &[1.5] &\scriptstyle{\text{, t=-1}}\\ &t+2 &\scriptstyle{\text{, -2<t<-1}}\\ &0 &\scriptstyle{\text{, t<-2}}\\ \end{align} \end{cases}

Now adjust the order of intervals of $x(-t)$ so that they are in left to right order:

x(-t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, t<-2}}\\ &t+2 &\scriptstyle{\text{, -2<t<-1}}\\ &[1.5] &\scriptstyle{\text{, t=-1}}\\ &2 &\scriptstyle{\text{, -1<t<0}}\\ &[1.5] &\scriptstyle{\text{, t=0}}\\ &1 &\scriptstyle{\text{, 0<t<1}}\\ &[0.5] &\scriptstyle{\text{, t = 1}}\\ &-t+1 &\scriptstyle{\text{, 1<t<2}}\\ &[-0.5] &\scriptstyle{\text{, t = 2}}\\ &0 &\scriptstyle{\text{, t > 2}}\\ \end{align} \end{cases}

Now we can add these two signals for each respective interval. In fact we are here a bit lucky that the signals do have matching intervals, which would not be the case if the original signal $x(t)$ involved nonsymetric pieces in the first place. The addition produces the following signal:

x(t)+x(-t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, t<-2}}\\ &[-0.5] &\scriptstyle{\text{, t=-2}}\\ &(t+1)+(t+2)=2t+3 &\scriptstyle{\text{, -2<t<-1}}\\ &[0.5]+[1.5]=[2] &\scriptstyle{\text{, t=-1}}\\ &1+2=3 &\scriptstyle{\text{, -1<t<0}}\\ &[1.5]+[1.5]=[3] &\scriptstyle{\text{, t=0}}\\ &2+1=3 &\scriptstyle{\text{, 0<t<1}}\\ &[1.5]+[0.5]=[2] &\scriptstyle{\text{, t = 1}}\\ &(-t+1)+(-t+1)=-2t+3 &\scriptstyle{\text{, 1<t<2}}\\ &[-0.5] &\scriptstyle{\text{, t = 2}}\\ &0 &\scriptstyle{\text{, t > 2}}\\ \end{align} \end{cases}

Finally we shall multiply this with the funciton $\text{u}(t)$ whose piecewise definition is: \text{u}(t) = \begin{cases} \begin{align} &0 &\scriptstyle{\text{, t<0}}\\ &[0.5] &\scriptstyle{\text{, t=0}}\\ &1 &\scriptstyle{\text{, t>0}}\\ \end{align} \end{cases}

And the resulting function $[x(t)+x(-t)]\text{u}(t)$ was already provided in the first part above...

• Thank you so much it really helped me. It's crystal clear now @Fat32 – Hossam Houssien May 25 '16 at 0:12