Professional Documents
Culture Documents
=
= = =
0
] [ ] [ ] [ ] [ ] [ ] [ ] [
k k
k n x k h k n x k h n x n h n y
where, n = 0,1,.,(M-1) and M = N
1
+ N
2
-1
This is a multiply and accumulate operation and DSP device manufacturers
have developed signal processors that perform this action.
Correlation
There are two forms of correlation :
1. Auto-correlation
2. Cross-correlation
1. The cross-correlation function (CCF) is a measure of the similarities or shared properties
between two signals. Applications are cross-spectral analysis, detection/recovery of signals
buried in noise, pattern matching etc.
Given two length-N sequences x[k] and y[k] with zero means, an estimate of their
cross-correlation is given by:
( )
( )
( ) ( ) | |
,... 2 , 1 , 0
0 0
2
1
= = n
r r
n r
n
yy xx
xy
xy
Where, r
xy
(n) is an estimate of the cross covarience
The cross-covarience is defined as
( )
| | | |
=
+
=
=
= =
=
= +
=
1
0
2
1
0
2
1
0
1
0
] [
1
) 0 ( , ] [
1
) 0 (
,... 2 , 1 , 0 ] [ ] [
1
,... 2 , 1 , 0 ] [ ] [
1
N
k
yy
N
k
xx
n N
k
n N
k
xy
k y
N
r k x
N
r
n k y n k x
N
n n k y k x
N
n r
2. An estimate of the auto-correlation of an length-N sequence x[k]
with zero mean is given by
] [n
xx
2 , 1 , 0 ,
] 0 [
] [
] [ = = n
r
n r
n
xx
xx
xx
Digital Filtering
The equation for finite impulse response (FIR) filtering is
=
=
1
0
] [ ] [ ] [
N
k
k n x k h n y
Where, x[k] and y[k] are the input and output of the filter respectively and h[k]
for k = 0,1,2,,N-1 are the filter coefficients
z
-1
+
z
-1
z
-1
+ +
z
-1
y(n)
x(n)
x x x x
b
0
b
1
b
2
b
N-1
Filter structure
| | | |
=
=
1
0
N
k
k
k n x b n y
A common filtering objective is to remove or reduce noise from a wanted signal.
(a) (b) (c)
(d) (e) (f)
Figure : Reconstructed bi-level text images for degradation caused by h
1
and AWGN.
(a) Original, (b) 2D Inverse, (c) 2D Wiener, (d)PIDD, (e) 2D VA-DF, (f) PEB-FCNRT
Discrete Transformation
Discrete transforms allow the representation of discrete-time signals in the
frequency domain or the conversion between time and frequency domain
representations.
Many discrete transformations exists but the discrete Fourier transform (DFT) is
the most widely used one.
DFT is defined as:
N
j
N
n
nk
e W where W n x k X
t 2
1
0
] [ ) (
=
= =
N n W k X
N
n x
N
k
kn
N
MATLAB function for DFT
function [Xk] = dft (xn,N)
% Computes Discrete Fourier Transform
% -------------------------------------------------------
% Xk = DFT coefficient array over 0<= k <= N-1
% xn = N-point finite duration sequence
% N = Length of DFT
%
n = [ 0:1:N-1];
k= [0:1:N-1];
WN = exp(-j*2*pi/N);
nk = n.*k;
WNnk = WN .^ nk;
Xk = xn * WNnk;
Matlab Function for IDFT
function [xn] = idft(Xk,N)
% Computes the Inverse Discrete Transform
n = [ 0:1:N-1];
k= [0:1:N-1];
WN = exp(-j*2*pi/N);
nk=n*k;
WNnk = WN .^(-nk);
xn = (Xk * WNnk) / N;
Example
Let x[n] be a 4-point sequence
s s
=
otherwise
n
n x
, 0
3 0 , 1
] [
>>x=[1, 1, 1, 1];
>>N = 4;
>>X = dft(x,N);
>>magX = abs(X) ;
>>phaX = angle(X) * 180/pi;
magX=
4.0000 0.0000 0.0000 0.0000
phaX=
0 -134.981 -90.00 -44.997
Modulation
Discrete signals are rarely transmitted over long distances or stored in large
quantities in their raw form.
Signals are normally modulated to match their frequency characteristic to
those of the transmission and/or storage media to minimize signal distortion,
to utilize the available bandwidth efficiently, or to ensure that the signal have
some desirable properties.
Two application areas where the idea of modulation is extensively used are:
1. telecommunications
2. digital audio engineering
High frequency signal is the carrier
The signal we wish to transmit is the modulating signal
Three most commonly used digital modulation schemes for transmitting
Digital data over bandpass channels are:
Amplitude shift keying (ASK)
Phase shift keying (PSK)
Frequency shift keying (FSK)
When digital data is transmitted over an all digital network a scheme known
As pulse code modulation (PCM) is used.