# Autocorrelation Function

Theoretical Introduction

Correlation Functions are useful mathematical tools adopted in many fields of science, from engineering to physics and chemistry. Cross-Correlation function is often defined as a sliding inner (dot) product and it represents the measure of similarity of two signals as a function of a shift applied to one of them:

(1)

where and are two general non-discrete functions without discontinuity, is the complex conjugate of and is the lag (time delay for signal analysis). This representation is closely related to the convolution theorem by the following relationship:

(2)

In our case the signal must be compared with itself to find periodic patterns or anomalous high “similarity” degree within a time interval. To fulfill our purpose we can use Autocorrelation Function (ACF) wich is a simply cross-correlation of a signal with it self (). Next equation define ACF that results from a simple revaluation of equation number 1:

(3)

Within a discrete data set composed by records we can easily calculate autocorrelation from:

(4)

where is a lagged data by of and is a average value of the original data set. Entire denominator is used to keep the normalization condition, indeed can assume a value between -1 (perfect anticorrelation) and +1 (perfect correlation). A complete correlation can be only achieved with a perfect overlap of the analyzed function with it self; the simple way to verify that is when .

#### Example 1: STANAG 4285

The first example will be a NATO standard known as STANAG 4285. You can download a .wav sample from HERE. We start to collect some information about the structure of this signal: a good starting point is the official declassified NATO document dated 1989. The main frame structure can be found at Annex A-3/5 with a graphical view at Annex A-7, also reported below:

• 1 x 80 bits of synchronization pattern
• 4 x 32 bits of data
• 3 x 16 bits of reference

Therefore, a full sequence will be composed as the sum of all symbols reported above: 256 symbols recursively transmitted at the ratio of 2400 bauds means a redundancy of 106.66 ms.
To analyze an unknown signal I strongly recommend Signal Analyzer (SA). SA is actually one of the most valuable and priceless software available by Sergey Makarov (Макаров Сергей Михайлович, sadly passed away on 29 May 2012) and it used to perform several tests on data sample coded as .wav or .mp3 file. The signal waterfall is reported below:

When an Autocorrelation function is applied on selected data frame (see above), the result shows a clear recursive pattern with a gap of 106.244 ms between every peak as expected. An ACF refinement can be done into WaveForm windows where we can also notice an identical structure as reported by the specifications:

1 – Synchronisation pattern is composed by 2400*33.013E-3=79.2 (80) symbols
2 – Data group contain 2400*13.348E-3=32.0 (32) symbols
3 – Reference sequence is formed by 2400*6.674E-3=16.02 (16) symbols

This site uses Akismet to reduce spam. Learn how your comment data is processed.