Let's consider the simple system having
p=1
p
1
and
q=0
q
0
.
yn=ayn-1+bxn
yn
a
y
n1
b
xn
(1)
To compute the output at some index, this difference equation
says we need to know what the previous output
yn-1
y
n
1
and what the input signal is at that moment of
time. In more detail, let's compute this system's output to a
unit-sample input:
xn=δn
x
n
δ
n
. Because the input is zero for negative indices, we
start by trying to compute the output at
n=0
n
0
.
y0=ay-1+b
y0
a
y
-1
b
(2)
What is the value of
y-1
y
-1
? Because we have used an input that is zero for all
negative indices, it is reasonable to assume that the output
is also zero. Certainly, the difference equation would not
describe a
linear
system if the input that is zero for
all time did not produce a zero output.
With this assumption,
y-1=0
y
-1
0
, leaving
y0=b
y
0
b
. For
n>0
n
0
, the input unit-sample is zero, which leaves us with
the difference equation
∀n,n>0:yn=ayn-1
n
n
0
yn
a
y
n1
. We can envision how the filter responds to this
input by making a table.
yn=ayn-1+bδn
yn
a
y
n1
b
δn
(3)
Coefficient values determine how the output behaves. The
parameter bb can be any value,
and serves as a gain. The effect of the parameter
aa is more complicated (Figure 1). If it equals zero, the
output simply equals the input times the gain
b b. For all non-zero values of
aa, the output lasts forever;
such systems are said to be IIR (
Infinite Impulse
Response). The reason for this
terminology is that the unit sample also known as the impulse
(especially in analog situations), and the system's response
to the "impulse" lasts forever. If
aa is positive and less than one,
the output is a decaying exponential. When a=1
a1, the
output is a unit step. If aa is
negative and greater than
-11,
the outputoscillates while decaying exponentially. When
a=1
a1, the output changes sign forever, alternating
between bb and
-bb. More
dramatic effects when
|a|>1
a
1
; whether positive or negative, the output signal
becomes larger and larger, growing
exponentially.
Positive values of aa are used in
population models to describe how population size increases
over time. Here, nn might
correspond to generation. The difference equation says that
the number in the next generation is some multiple of the
previous one. If this multiple is less than one, the
population becomes extinct; if greater than one, the
population flourishes. The same difference equation also
describes the effect of compound interest on deposits. Here,
nn indexes the times at which
compounding occurs (daily, monthly, etc.),
aa equals the compound interest
rate plus one, and
b=1
b1 (the bank provides no gain). In signal processing
applications, we typically require that the output remain
bounded for any input. For our example, that means that we
restrict
|a|=1
a
1
and chose values for it and the gain according to
the application.