平成20年度電気関係学会四国支部連合大会

391

17-22

Peak Search Algorithm for Frequency Analysis
Akiko Kusaka

Yoshihiro Yamagami(Tokushima University)

Yoshifumi Nishio

1. Introduction
In the peak search of the frequency characteristics, it
is diﬃcult to ﬁnd the peak for large scale circuits. If wecarry out frequency analysis as changing the frequency,
we have to increase the frequency gradually. However,if the changing step is large, we may miss the peaks.
Also there is no guarantee that the peak values exist
at the frequencies.
In this article, we propose an algorithm to ﬁnd thepeak of the frequency characteristics by combining thefrequency analysis of SPICE with the cubic spline interpolation and the Newton method.

Figure 1: Example circuit. R = 1 [kΩ], C = 1 [nF],
L = 10 [mH], e = E cos ωt [V], E = 1 [V].

2. Peak search algorithm
The peak value of linear reactance circuits is considered to be decided by the character of |Z| or |Y | whichis the impedance/admittance matrix of the given circuits. Therefore, we consider that it is enough to examine a speciﬁc node to ﬁnd the peak. In our algorithm, we carry out frequency analysis of SPICE andobtain the frequency characteristics f (ω) for a speciﬁcnode. The peaks correspond to the frequency satisfying f 0 (ω) = 0. In order to calculate f 0 (ω) from thediscrete data of f (ω) obtained from SPICE, the following numerical diﬀerentiation is used.
f 0 (ω) =f (ω + ∆) − f (ω)
∆(1)

(2)

can be determined.
Next, in order to solve the equation f 0 (ω) = 0, weuse the Newton method.
ωi+1 = ωi − f 0 (ωi )/f 00 (ωi )(b)Figure 2: Frequency characteristics of the circuit inFig. 1. (a) Ladder is 3. (b) Ladder is 5.

The peak values obtained from the discrete data of
the curves in Fig. 2 are summarized in Table 1. Bycomparing the calculated peak values with the frequency characteristics curves, we can say that our proposed algorithm works well for the circuit.
Table 1 Calculated peak values.

where ∆ is a small variation of frequency ω.
In order to interpolate the discrete data of f 0 (ω),
we use the cubic spline approximation method. Using the four successive points of f 0 (ω), the coeﬃcientsa0 , a1 , a2 , a3 of the cubic spline function
f 0 (ω) = a0 + a1 ω + a2 ω 2 + a3 ω 3(a)(3)

If we decide a convergence radius θ with a suitablevalue and |ωi+1 − ωi | < θ is satisﬁed, we consider ωi+1
to be a solution.

3. Simulation result
We consider the RLC ladder circuit as shown inFig. 1. Figures 2(a) and (b) show the frequency characteristics for the cases that the numbers of the ladderare 3 and 5, respectively, obtained by using the ACanalysis of SPICE.

# of ladder
35

peak 1
19.83
10.47

peak 259.43
39.67

peak 3—62.77

4. Conclusions
In this study, we have proposed an algorithm calculating the peak values of the frequency characteristics
curves obtained by the AC analysis of SPICE. The discrete data were interpolated by using the cubic spline
function and the frequency giving the peak was calculated by the Newton method.
The proposed algorithm will be applied to nonlinear
large scale circuits if accurate frequency characteristics
can be obtained. Hence, we will combine the proposed
algorithm with the previously proposed Sine-Cosine
circuits to obtain accurate frequency characteristics.

References[1] A.Ushida and M.Tanaka, “Computer Simulationof Electronic Circuits,” Corona Publishing Co.
Ltd., 2002.