Как выбрать гостиницу для кошек
14 декабря, 2021
Because of the characteristics of digitizing equipment, the samples in a digitized data record are generally evenly spaced. Numerical integration procedures based on evenly spaced data are called Newton-Coates methods. A number of different Newton-Coates methods are available, and the effect of the choice of an integration method on the quality of the results should be examined.
The objective in calculating the DFT is to evaluate integrals of the form
where
or
t See Hunt (6).
We must make assumptions on the shape of y(t) between sampling points in formulating different numerical integration schemes. Each different integration procedure is based on a different assumption on the shape of y(t) between samples. For the specific case of evaluating the DFT, we have complete knowledge of the behavior of one of the factors (sin cot or cos cot) in y(r). Thus we may develop our numerical integration procedure either by making an assumption on the form of y(t) between points or by making an assumption on x(t) between points.
Let us consider first the simplest numerical procedure, which involves a direct evaluation of Eq. (4.3.5). (We will use the complex form to simplify the discussion, but the reader will appreciate the equivalence with an analysis based on the trigonometric form.)
F'(jco) = (l/N) £ XP exp( ~jo)tp) (4.5.4)
P = 0
or
F’Ucj) = (l/N) £ xpe-^’
P = 0
This is equivalent to
F'(ja>) = X УР
p-0
y(t)
t
Fig. 4.8. Interpolation assumption in trapezoid rule.
where yp = (l/N)xpe~JapM. Now consider the numerical integration scheme based on the assumption that y(r) varies linearly between points (see Fig. 4.8). This is called the trapezoid rule. In this case,
f y(t) dt = {y(tp) + ±[y(tp+ j) — y(rp)]} Ar = |[y(tp+ j) + y(tp)] At (4.5.7)
J‘p
|
|
|
|
|
|
|
|
|
|
|
The second factor is identical with the trapezoid DFT result of Eq. (4.5.10). Thus we see that the staircase DFT is related to the trapezoid DFT by a simple factor. If the analyst has reason to believe that x(t) is nearly a staircase function, then results from a trapezoid DFT may be transformed into the staircase DFT using Eq. (4.5.11).
Another approximation is that x(t) varies linearly between points. We will call this the ramp DFT. The reader should note that this is not the same as assuming that x(t) e~jat varies linearly between points as in the trapezoid DFT. It may be shown that an integration based on this assumption gives
This shows that the ramp DFT may be obtained by multiplying the trapezoid DFT by
(1 — e^’Xl — 2[1 — cos(w At)]
(со At)2 (со At)2 1 ‘
As with the staircase DFT, the ramp DFT may be obtained by multiplying the trapezoid DFT by a simple factor.
It should be noted that the correction factors will cancel if the ratio of two DFTs is calculated. Thus the corrections to the DFT are unnecessary in that case, but the individual DFTs may differ significantly from exact results.
TABLE 4.2 DFT Analysis of a Square Wave
|
The correction of the trapezoid DFT to give the staircase DFT and the ramp DFT may be demonstrated with two examples. Consider first a square wave. The staircase DFT should give exact results. (See Section 2.5 for an evaluation of the exact results.) Table 4.2 shows trapezoid DFT results and results obtained using Eqs. (4.5.11) and (4.5.9) to convert trapezoid DFT results into staircase DFT results and ramp DFT results for several different numbers of samples. The corrected staircase results agree perfectly with the exact theoretical values. A second example involves the triangular wave shown in Fig. 4.10. In this case, the ramp DFT should give exact results. Table 4.3 shows trapezoid DFT results and results obtained using Eq. (4.5.19). Again we find that the appropriate correction procedure gives the exact result.
Fig. 4.10. A triangular wave. |
TABLE 4.3 DFT Analysis of a Triangular Wave
|