Digital Signal Processing Reference
In-Depth Information
on the instant of zero crossing as well. The error depends on sampling frequency and
decreases when this frequency increases. The error analysis is given in Chap. 9 ,
where it is shown that it is possible to find the coefficients minimizing the error for
given sampling frequency. In the case of half period one can obtain:
N 1 = 2 1
X
j x 1 ð n Þj ¼ S av X 1m
ð 8 : 36 Þ
n ¼ 0
where
p
2N 1
S av ¼ 0 : 5ctg
and then the magnitude can be measured according to the equation:
X
N 1 = 2 1
p
2N 1
X 1m ¼ 2tg
j x 1 ð n Þj:
ð 8 : 37 Þ
n ¼ 0
The equation can be simplified for high sampling frequencies:
N 1 = 2 1
X
p
2N 1
X 1m
j x 1 ð n Þj
ð 8 : 38 Þ
n ¼ 0
The equation can be written for time instant n as follows:
X
N 1 = 2 1
p
2N 1
X 1m ð n Þ¼ 2tg
j x 1 ð n k Þj
ð 8 : 39 Þ
k ¼ 0
and for m half periods:
X
mN 1 = 2 1
p
2N 1
X 1m ; m ¼ m2tg
j x 1 ð n k Þj:
ð 8 : 40 Þ
k ¼ 0
For high number of samples it is also possible to use recursive procedure:
½j x 1 ð n Þj j x 1 ð n N 1 = 2 Þj;
p
2N 1
X 1m ð n Þ¼ X 1m ð n 1 Þþ 2tg
ð 8 : 41 Þ
where x are signal samples and X is magnitude value.
One can avoid the error described above by averaging signal samples squared:
x 1 ð n Þ¼ 0 : 5X 1m f 1 þ cos ð 2nX 1 þ 2u 1 Þg
which, as it is seen, consist of DC component proportional to magnitude squared
and the second harmonic of the signal. It can be noticed easily that averaging it
over the time being multiple of half period gives the result:
Search WWH ::




Custom Search