I have this system:
$$ y[n] = -\frac{1}{2} x[n+2] - y[n+1] $$
I have no idea how to prove if the system is linear or not, because, it depends on future outputs...
Thanks for the help
I have this system:
$$ y[n] = -\frac{1}{2} x[n+2] - y[n+1] $$
I have no idea how to prove if the system is linear or not, because, it depends on future outputs...
Thanks for the help
Matt's original answer, regarding linearity, is correct.
Let $\mathbb{T}\{ . \}$ be the linear operator that maps input $x[n]$ to output $y[n]$.
$$ y[n] = \mathbb{T}\{ x[n] \} $$
the sole necessary definition for linearity is simply whether superposition applies for all possible inputs. for a discrete-time system, if, for two completely arbitrary inputs, $x_1[n]$ and $x_2[n]$, this
$$ y_1[n] + y_2[n] = \mathbb{T}\{ x_1[n] \} + \mathbb{T}\{ x_2[n] \} = \mathbb{T}\{ x_1[n] + x_2[n] \} \quad \forall n \in \mathbb{Z}$$
is true, then the system is Linear. that is the sole criterion.
the scaling property
$$ \begin{align} a \cdot y[n] &= a \cdot \mathbb{T}\{ x[n] \} \\ & = \mathbb{T}\{ a \cdot x[n] \} \quad \forall n \in \mathbb{Z}, a \in \mathbb{C} \\ \end{align} $$
can be derived directly from the superposition property, first for integer $a$, then for reciprocal integer $a$, then for real and rational $a$. a little more handwaving regarding continuity and limits is needed to extend this to any real $a$, and not much else is needed to extend to $a \in \mathbb{C} $.
Linearity is solely a property of the system. it is not a property of the input. so if it is true for one particular input, if the system is Linear, it's also true for any other input.
similarly, for Time-Invariance, if, for a discrete-time $y[n] = \mathbb{T}\{ x[n] \}$, then
$$ y[n-N] = \mathbb{T}\{ x[n-N] \} \quad \forall n,N \in \mathbb{Z} $$
if the discrete-time system satisfies that criterion, it's Time-Invariant. likewise, Time-Invariancy is a property solely of the system, not of the inputs to the system.
if a system satisfies both criteria for Linearity and Time-Invariancy, then it is "LTI" and we get to use all this cool Fourier and Z-transform technique on it.
the system as depicted by the OP is LTI, however, it is also anti-causal (which is also "acausal", but "acausal" is a less specific property than "anti-causal") .
For linearity it is irrelevant if the output depends on future values. This only affects the system's causality. For linearity you just need to check whether the response to the signal
$$ax_1[n] + bx_2[n]$$
equals
$$ay_1[n] + by_2[n]$$
where $y_1[n]$ and $y_2[n]$ are the individual responses to inputs $x_1[n]$ and $x_2[n]$, respectively.
And of course you can write the input/output relation as
$$y[n+1] = -\frac12 x[n+2] - y[n]\tag{1}$$
I will now characterize all sequences that satisfy the recursion (1) for the specific input signal $x[n]=\delta[n]$. Applying the $\mathcal{Z}$-transform to (1) we get (with $X(z)=1$)
$$Y(z)=-\frac12\frac{z^2}{1+z}\tag{2}$$
The function $Y(z)$ corresponds to one left-sided sequence and to one right-sided sequence. Note that left-sided and right-sided doesn't necessarily mean anti-causal and causal, but it only means that $y(n)=0$ for $n>N$ or for $n<N$, respectively, for some positive or negative integer $N$. These two sequences are given by
$$y_{p1}[n]=\frac12 (-1)^{n}u(n+1)\tag{3}$$ and $$y_{p2}[n]=-\frac12 (-1)^n u(-n-2)\tag{4}$$
Note that neither (3) nor (4) is causal. The sequences $y_{p1}[n]$ and $y_{p2}[n]$ are particular solutions of the difference equation (1) for $x[n]=\delta[n]$. They are in fact impulse responses of two different linear time-invariant (LTI) systems described by the difference equation (1). The impulse response $y_{p1}[n]$ was mentioned by Dilip Sarwate in a comment below, and something similar to $y_{p2}[n]$ was mentioned by Robert B.-J. I completely agree with them that the difference equation (1) describes an LTI system, if it is used to describe a system with either (3) or (4) as impulse response.
However, the sequences (3) and (4) are not the only sequences that satisfy (1). Looking at the homogeneous difference equation
$$y[n+1]=-y[n]\tag{5}$$
we see that
$$y_h[n]=c(-1)^n,\quad c\in\mathbf{R}\tag{6}$$
is a solution of (5). Consequently, the general solution of (1) (with $x[n]=\delta[n]$) can be written as
$$y[n]=y_{p1}[n]+y_h[n]=\frac12 (-1)^{n}u(n+1) + c(-1)^n\tag{7}$$
Of course we could as well have used $y_{p2}[n]$ to define the general solution. Note that $y_{p2}[n]$ is obtained from (7) by choosing $c=-1/2$.
Now assume that we scale the input signal and use $x[n]=2\delta[n]$ instead. Obviously, the solutions $y_{p1}[n]$ and $y_{p2}[n]$ will change accordingly, but the general solution (7) will not (unless $c=0$ or $c=-1/2$), because the homogeneous solution (6) does not depend on $x[n]$. This is why I claim that the difference equation (1) does not necessarily describe an LTI system. In our case, it describes exactly two LTI systems and an infinite number of systems which are neither linear nor time-invariant.
So in this case, I have:
ay1(n) = a(-0.5x1(n+2) - y(n+1)) by2(n) = b(-0.5x2(n+2) - y(n+1))
And the response to ax1(n)+bx2(n) is:
-0.5(ax1(n+2)+bx2(n+2)) - y(n+1)
But this is not equal to y1(n)+y2(n) so I guess my system is not linear right ?
Thanks again !
– johnny Oct 01 '14 at 15:37so, using Matt's original criterion for the property of "Linearity": if $y_1[n]$ is the output when $x_1[n]$ is the input and $y_2[n]$ is the output when $x_2[n]$ is input, is
$$a \ y_1[n] + b \ y_2[n]$$
the output of the same system when
$$a \ x_1[n] + b \ x_2[n]$$
is the input?
since the system is fully and solely described as
$$ y[n] = -\frac12 x[n+2] - y[n+1] $$
, this depends on whether equality is maintained with the above substitution. is
$$ a \ y_1[n] + b \ y_2[n] \ = \ -\frac12 \left(a \ x_1[n+2] + b \ x_2[n+2] \right) - \left(a \ y_1[n+1] + b \ y_2[n+1] \right) $$
true or not? if it's true, the system is linear according to the criterion Matt L first held out. if not, it's not linear.