Digital Signal Processing Reference
In-Depth Information
The entire software package should be stored in a single folder on the user's computer, and the full
file name of the folder must be placed on the MATLAB or LabVIEW search path in accordance with the
instructions provided by the respective software vendor (in case you have encountered this notice before,
which is repeated for convenience in each chapter of the topic, the software download only needs to be
done once, as files for the entire series of four volumes are all contained in the one downloadable folder).
See Appendix A for more information.
4.3
CORRELATION AT THE ZEROTH LAG (CZL)
A simple concept of numerical correlation is this: if two numbers are both positive, or both negative,
they correlate well; if one is positive, and one is negative, they correlate strongly in a negative or opposite
sense. A way to quantify this idea of correlation is simply to multiply the two numbers. If they are both
positive, or both negative, the product is positive; if one number is positive, and one number is negative,
the product is negative. Thus two numbers having the same sign have a positive correlation value, while
two numbers having opposite signs have a negative correlation value. If one number is zero, the product
is zero, and no correlation between the two numbers can be determined, that is, they are neither alike nor
unalike; in this case they are termed “uncorrelated.”
To correlate two waveforms (i.e., sequences) having the same length N , multiply corresponding
samples and add up all the products. Imagine this as first laying one waveform on top of the other so that
the first sample of one waveform lies atop the first sample of the other, and so forth. Then multiply each
pair of corresponding samples and add the products.
Stated mathematically, the correlation of two sequences A [ n ]
and B [ n ]
having equal lengths N is
N
1
CZL =
A [ n ] B [ n ]
(4.1)
n
=
0
where CZL is the Correlation at the Zeroth Lag of sequences A
. The nomenclature Zeroth
Lag is used in this topic for clarity to denote this particular case, in which two sequences of equal length
are correlated with no offset or delay (lag) relative to one another. In most topics, the process represented
by Eq. (4.1) is usually referred to simply as the “correlation” of sequences A
[
n
]
and B
[
n
]
[
n
]
and B
[
n
]
.
Example 4.1.
Compute the CZL of the sequence
[ ones( 1 , 16 ), zeros( 1 , 16 ) ]
with itself. Follow up by
correlating the sequence with the negative of itself.
Figure 4.1, plots (a) and (b), show two instances of the subject 32-sample sequence. To compute
the correlation value, figuratively lay the first waveform on top of the second. Multiply all overlapping
samples, and add the products to get the answer, which is 16. Since the two waveforms of Fig. 4.1 are in
fact the same, they have a high positive value of correlation, which is expected from the basic concept of
correlation.
The sequence and its negative are shown in plots (c) and (d) of Fig. 4.1. The correlation value in
this case is -16, indicating a strong anti-correlation.
Example 4.2.
Compute the CZL of the two sequences
[
ones ( 1 , 16 ) , zeros ( 1 , 16 ) ]
and
[
zeros ( 1 , 16 ) ,
-ones ( 1 , 16 )
]
.
Search WWH ::




Custom Search