Sunteți pe pagina 1din 4

An effective method for generating initial condition in harmonic balance analysis using method of nonlinear currents

Ahmad Reza Farsaei and Reza Saan Electrical and Computer Engineering Department Isfahan University of Technology Isfahan, Iran
a.farsaei@ec.iut.ac.ir rsafian@cc.iut.ac.ir

Abstract This paper presents a solution to one of the most troublesome sections of Newton algorithm for solving harmonic balance nonlinear system of equations which is choosing an appropriate initial condition. A good initial condition guaranties the convergence of the algorithm. Here, we have used Volterra series analysis to calculate the appropriate initial condition for the harmonic balance analysis. To demonstrate the performance of the Volterra assisted harmonic balance (VAHB) method we have compared the response of a typical nonlinear circuit with two other techniques. These techniques are implemented in the commercial ADS software. They exploit arbitrary initial condition and initial condition based on the transient analysis of the nonlinear circuit. Based on the calculated results the VAHB technique has a superior performance in terms of convergence with respect to other techniques.

Linear H1(f1) Quadratic H2(f1,f2) X(t) Cubic H3(f1,f2,f3)

Y1(t)

Y2(t)
+ +

Y3(t)

+ +

Y(t)

Nth Order Hn(f1,f2,,fn)

Yn(t)

Fig. 1. Model of weakly nonlinear circuit used by the nonlinear transfer function approach.

I. INTRODUCTION Harmonic balance method is a powerful technique for simulating highly nonlinear circuits. It provides the steady state response of the nonlinear circuit [1]. To calculate the solution of a nonlinear circuit in HB method we need to solve a system of nonlinear equations which has several variables. This section is the most troublesome section of harmonic balance (HB) method. To solve the nonlinear equation the HB method forces the initial guess to converge towards an accurate answer through an iterative algorithm. The success of the method which is converging to the accurate response largely depends on the selection of the initial condition. The Newton algorithm is mostly used to perform the iterative procedure of the forced convergence. This method guarantees the convergence if the initial condition is chosen close enough to the nal response of the system of nonlinear equation [2]. But in the case that the initial condition is not chosen close enough to the answer this algorithm may not converge to the right answer. Different techniques can be used to generate the initial guess of HB algorithm. For example, we can use linear answer of the circuit as a initial condition of HB. As another example, we can exploit transient analysis to nd quasi steady state response to be used as the initial condition for HB analysis (transient assisted harmonic balance (TAHB) method) [1]. Another possibility is that we can use the circuit response in the case of the weak nonlinearity as a initial condition for calculating the general response of the circuit. One of the best methods for calculating the answer of a weakly nonlinear circuit to non-commensurate excitations is Volterra Series analysis [1], [3], [4]. This method does not need initial condition and we can nd the answer in closed form equations. More importantly, it can be developed to accommodate large nonlinear circuits with nonlinearities up to degree 5 [5]. Therefore, it is one of the best choices for nding initial condition of a strong or moderate nonlinear circuits. It estimates the real response with the response of the correspondent weakly nonlinear circuit. As it will be shown in the following sections, the answer of the correspondent weakly nonlinear circuit can be found in closed form equations by Volterra Series analysis [1]. In the following two sections a brief introduction to the Volterra series and harmonic balance methods is provided. In section IV the combination of these techniques is used to simulate a typical nonlinear circuit. To demonstrate the applicability of the VAHB method the results are compared to two other techniques. II. VOLTERRA S ERIES T ECHNIQUE Volterra series method is a well known method in the simulation of nonlinear circuits. This method is usually exploited in cases that the circuit nonlinearities are weak with a small input. Hence, we can use the Taylor Series expansion of the nonlinearities around their bias point to nd the response with a good accuracy [1], [3], [4], [6]. Figure 1 shows the general systematic relation between the

978-1-4244-2802-1/09/$25.00 2009 IEEE

1501

Fig. 2.

Schematic of the nonlinear circuit used in the simulations.

input x(t) and the output y (t) in a weakly nonlinear circuit [4]. This approach is very useful in systematic analysis of the nonlinear circuits. It helps us to nd the complete nonlinear transfer function of the weakly nonlinear circuit using harmonic input Method [1]. Here, we want to use the Volterra series analysis to calculate an initial condition for a nonlinear circuit. This initial condition will be used as a initial guess in harmonic balance analysis, therefore, it need not to be highly accurate. Hence, complete analysis of the circuit is not necessary at this point. Instead of using harmonic input method which provides the complete and accurate response, we use nonlinear current method to estimate the initial condition. In this method all of the nonlinearities will be expanded by Taylor series around their bias point and all higher order mixing products can be nd by lower order mixing product [1]. This method is more amenable to numerical analysis and it can be easily developed to analyze complex nonlinear circuits [7]. To show applicability of the proposed procedure, we demonstrate the analysis of a simple but very important circuit in the following sections. This circuit is composed of a current source, a nonlinear conductance which is controlled by voltage across it and a load. Its schematic is shown in Fig.2. It can be used as a simple model of the rst stage of a two stage operational amplier. The nonlinear conductance corresponds to the output resistance of the rst stage which is nonlinear in deep sub-micron technologies [7]. In general, the voltage across nonlinear conductance consists of N orders. Here, we will use voltages that produce current in nonlinear conductance up to third order. Therefore, to calculate the answer, we have to go though three steps. Each of the three circuits shown in Fig. 3 is used for one of these three steps. The rst step is to calculate the linear response which can be achieved by solving a rst order circuit which is shown in Fig.3(a). The linear response (v1 (f )) is, v1 (f ) = 1 G + g1
q =+Q

Fig. 3.

The three steps required to nd the solution of Volterra analysis.

calculated using (2). Because input current source only have rst order components then we have to zero input current source which means open circuit it for calculating second order voltage. i2 = 1 G + g1
q1 =1 q2 =1

Is,q1 Is,q2 exp j (wq1 + wq2 )t. (2)


q1 =+1 q2 =+1

The second order voltage component is, v2 = g2 4(G + g1 )3


q1 =1 q2 =1

Is,q1 Is,q2 exp j (wq1 + wq2 )t.


q1 =+1 q2 =+1

(3) Using a similar procedure, the second order voltage component will be used in nding the third order nonlinear current. The third step is to calculate the third order nonlinear current and voltage. For calculating third order nonlinear current we can use Fig. 3(c). The third order current can be calculates as, g2 i3 = 2g2 4(G + g1 )3
q1 =1 q2 =1

Is,q1 Is,q2 exp j (wq1 + wq2 )t +


q1 =+1 q2 =+1

1 2(G + g1 ) q

q1 =1

Is,q exp jwq t +


q2 =1 q2 =1 q3 =1 q2 =+1 q2 =+1 q3 =+1

1 =+1

1 g3 8 (G + g1 )3

Is,q1 Is,q2 Is,q3 exp j (wq1 + wq2 + wq3 )t.

(4)

Is,q exp jwq t, Is,q =


q =Q

Vs,q R

(1)

where, q is the number of harmonic which varies from Q to +Q. Since we are seeking the solution to single tone input then in (1), Q, the index of summation, is equal to 1. This rst order voltage will be used to nd second order nonlinear current in the second step. The second step is to calculate the second order nonlinear current and voltage based on Fig. 3(b). As it can be seen from Fig. 3(b) the second order nonlinear current can be

By means of third order nonlinear current, we are able to determine third order nonlinear voltage component. Based on Fig. 3(c) this voltage can be calculated as, i3 . (5) v3 = G + g1 All the above equations will be used to nd the initial condition in custom HB simulator. However it is not necessary to consider all of the results to nd initial condition. Instead, we can include just one component from each order of the voltage to get a satisfying initial condition. As previously mentioned, these equations are simple, accurate, and more importantly they do not need initial condition.

1502

1.5 Custom Harmonic Balance 1 0.5 0 0.5 1 1.5 2 0

VOut

2 3 Frequency (KHz)

Fig. 5. Logarithmic magnitude of harmonics of the Output Voltage using Custom Harmonic Balance simulator. TABLE I ADS HB AND C USTOM HB RESULTS FOR THE LOGAROTHMIC MAGNITUDE OF HARMONICS OF THE O UTPUT VOLTAGE Frequency (Hz) 0 1 2 3 4 5 Magnitude (Commercial HB) 0.0410 1.0750 -1.4690 0.4410 -1.7520 0.1020 Magnitude (Costume HB) 0.0408 1.0746 -1.4687 0.4409 -1.7519 0.1017

Fig. 4.

Solution algorithm of Custom HB using Volterra initial condition.

III. H ARMONIC BALANCE A NALYSIS Harmonic Balance analysis is a powerful tool for analyzing strong nonlinear circuits such as class B power ampliers and oscillators. The solution algorithm switches between time and frequency domains therefore we can call it mixed mode analysis in comparison to Volterra series technique which all of the solution procedure is in frequency domain. The HB procedure is based on dividing the circuit to two sections, linear and nonlinear, and calculating the voltage across each of these sections parts separately [1]. The criteria for the voltage to be accurate is that the current error which is obtained by KCL at ports connecting linear and nonlinear section be less than a specic error [1]. There are many ways to solve HB equation, such as relaxation methods [8], [9], Optimization methods [1], and Newton method. Nowadays there is a consensus that Newton method is the best methods for HB analysis. Newton method is a numerical solution to nd a root of a system of nonlinear equations in multiple variables. In general, almost all of these numerical techniques need an initial condition and Newton algorithm is not an exception [3]. There are many methods to estimate an initial guess for Newton algorithm based on the circuit such as linear estimation, time assisted harmonic balance (TAHB) estimation. We can also choose arbitrary initial condition such as zero. But, linear estimation in not accurate enough and TAHB cannot be used in circuits that have parts which are modeled in frequency domain. Here, instead of using arbitrary initial condition or TAHB estimation or linear estimation, we will use Volterra series technique to nd an initial estimate to the solution. This combination is more accurate than linear estimation because we incorporate the effect of nonlinear terms in addition to linear term and contrary to TAHB, Volterra estimation can be used in circuits that have parts which are modeled

in frequency domain. Also, it will be shown that Volterra estimation can improve the convergence of the Newton algorithm. IV. SIMULATION RESULTS To demonstrate the applicability of the Volterra assisted harmonic balance (VAHB) method we have compared the performance of the method to two other methods. Figure 4 shows three different approaches to harmonic balance analysis. Each approach consists of two main parts. The rst part is initial condition generator and the second part is the harmonic balance simulator. Here, we have used three different initial condition generator, transient, arbitrary, and Volterra. In the second part there are two different HB simulators, one of them is the ADS which is a commercial software and the other one is the custom HB code which we have developed. Since the ADS software does not have the option to use the Volterra series as the initial condition generator we have exploited the custom HB code to implement the VAHB technique. To verify the accuracy of the custom HB code we have compared the results to ADS software for a specic problem with an arbitrary initial condition. We have analyzed the nonlinear circuit in Fig. 2 with nonlinear coefcients g1 = 1e 3, g2 = 0.5e 3, g3 = 1e 4, g4 = 0.5e 4, and g5 = 1e 5. The amplitude of the voltage source is 500 V and the resistance of the load is 500 . The results are plotted in Fig.5. and compared to ADS simulator results in Table II. It can be seen that output of these simulators, ADS and Custom HB, produce the same results. Hence the accuracy of the custom HB code is veried.

1503

12 10

Current Error at Output Node (Amperes)

8 6 4 2 0 2 0

200

400

600

800

1000

Number of Iteration

Fig. 6. Logarithmic scale of current error of the output node without using Volterra initial condition.

After verifying our results with a well-known circuit simulator, it is now time to demonstrate the idea of Volterra initial condition generator. First, we changed the coefcients of the nonlinearity so that our custom harmonic balance and ADS harmonic balance simulator using arbitrary initial condition fail to converge. The selected nonlinear coefcients are g1 = 1e 3, g2 = 2, g3 = 2e 3, g4 = 0, g5 = 0. The amplitude of the voltage source is 500 V and the resistance of the load was chosen as 500 . Simulating in ADS, HB simulator still was not able to converge. The current error of custom HB is shown in Fig. 6. It shows that the numerical algorithm is trapped and is not able to converge to the right solution. Now it is time to use Volterra initial condition. The Volterra initial conditions of the solution can be obtained from the equations derived in section II (equations (1), (3), and (5)). Although, we use the VAHB method for a specic simple nonlinear circuit but, the method can be easily applied to large and complex nonlinear circuits. This is due to the fact that nding these initial conditions using the Volterra series method does not need any iterative computations and it is calculated analytically. With these nonlinear coefcients transient analysis of ADS also does not converge. To somehow help the ADS simulator to converge we used the results of Volterra analysis to calculate the initial voltage and used it as the initial node set in ADS transient assisted harmonic balance. The results of using Custom HB simulator with Volterra initial condition are shown in Figs. 7(a) and (b). Figure 7(a) shows error current in logarithmic scale demonstrating improvement of the nal answer and decreasing trend of the error current versus iterations in Newton algorithm. Using TAHB in ADS the results in table II was obtained. These results are completely similar to the results obtained by Volterra Assisted Harmonic Balance. V. C ONCLUSIONS We proposed a method to estimate the initial condition of a nonlinear circuit by means of Volterra series approach. This method is more accurate than linear response and it is completely consistent with modeling in frequency domain contrary to time domain analysis. We showed that in some circuits selecting initial condition inappropriately can make the analysis non-convergent and by using Volterra initial

Fig. 7. (a) Logarithmic scale of the current error (b) Logarithmic scale of the Magnitude of the voltage harmonics. TABLE II ADS TAHB AND C USTOM HB (VAHB) RESULTS FOR THE LOGARITHMIC SCALE MAGNITUDE OF HARMONICS IN O UTPUT VOLTAGE .

Frequency (Hz) 0 1 2 3

Log (Vout ) (Commercial HB using TAHB) +3.301 -3.602 -10.506 -13.315

Log (Vout ) (Costume HB using VAHB) +3.301 -3.602 -10.505 -13.340

condition the convergence of the method is substantially improved. Our method does not need initial condition and the solution of it can be derived with closed form equations. On the other hand, the computational cost of its implementation is small and the speed of its calculation is very fast. Moreover it can be programmed for calculation with specic degree of accuracy for complex nonlinear circuits. R EFERENCES
[1] S. Mass, Nonlinear Microwave Circuits, Artech House, Norwood, Ma. 2003. [2] E. Atkinson, An Introduction to Numerical Analysis, John Wiley & Sons, 1988. [3] P. Wambacq, W. Samsen, Distortion Analysis of Analog Integrated Circuits, Kluwer Academic Publishers,1998. [4] D.D. Wiener and J.E. Spina, Sinusoidal Analysis and Modeling of Weakly Nonlinear Circuit, Van Nostrant, New York, 1980. [5] A, Heiskanen, and T. Rahkonen, 5th order multi-tone volterra simulator with component level output, Proc. 2002 IEEE International Symposium on Circuits and Systems, Phoenix, AZ, 2002, pp. 591594. [6] M. Schetzen, The Volterra and Wiener Theories of Nonlinear System, John Wiley & Sons 1980. [7] J. Vuolevi and T. Rahkonen, Distortion in RF Power Ampliers, 1st ed. Artech House, 2003. [8] R.G. Hicks and P.J. Khan, Numerical Analysis of Nonlinear Solid-State Device Excitation in Microwave Circuits, IEEE Trans. Microwave Theory Tech., Vol. MTT-30, 1982, p.251. [9] A.R. Kerr, A Technique for Determining the Local Oscillator Waveforms in a Microwave Mixer, IEEE trans. Microwave Theory Tech., Vol. MTT-23, 1975, p.828.

1504

S-ar putea să vă placă și