• No results found

Control Strategy for a DC/DC Buck Converter based on a Hamiltonian Model to suppress the Ripples at the Input stage

N/A
N/A
Protected

Academic year: 2021

Share "Control Strategy for a DC/DC Buck Converter based on a Hamiltonian Model to suppress the Ripples at the Input stage"

Copied!
50
0
0

Loading.... (view fulltext now)

Full text

(1)

Degree Project

 

Mutaz Tuffaha, Dhafer Yahia Saleh 1977-07-03 1955-04-08 Subject: Electrical Engineering Level: Advanced, Master

Course code: 5ED06E

(2)

SE-351 95 Växjö / SE-391 82 Kalmar Tel +46-772-28 80 00

(3)

Control Strategy for a DC/DC Buck Converter based on a

Hamiltonian Model to suppress the Ripples at the Input stage

(4)

Abstract

(5)

1

Introduction

AC/DC converters is a fertile arena for research and treatises due to their proliferation in many applications such as battery chargers. The quest of all these researches revolves around increasing the efficiency, reducing the cost and/or size of those converters and reducing the unwanted ripples in the input voltage. This report is about a new control strategy that aims to reduce the ripples of the input voltage which are referred to as the Total Harmonic Distortion (THD) in some litera-ture, see [2] for example.

This report is based on a report presented by M. Lenells [1]-From here on, this report is referred to as [1]- which was based on a problem formulated by MicroPower E.D. Marketing AB. MicroP-ower which has its main operation in Växjö, Sweden, develops and manufactures chargers for tractionary batteries that are used in trucks. They use high power buck converters in the order of 8KW , and they have reasons to think that the ripples in the input voltage cause disturbances in the electrical network which in turn may be harmful to the chargers and other elements of the electrical network [1].

In [1] an explanation to the problem of the ripples in the input voltage was suggested depend-ing on the interaction between the controller and the feeddepend-ing network. A controller is needed for the converter to keep the output voltage regulated. The feeding network contains large inductances and a rectifier with an input filter to transfer the AC input into DC. This feeding network introduces a resonance frequency that interacts with the control signal. One way to tackle this resonance is to increase the output capacitance of the rectifier Cf in fig.1, or to decrease the inductance of the

feeding network Lsin fig.1. However, increasing Cf would be an impractical solution due to the

cost and size of large capacitors [1], while decreasing Lsis not feasible.

Because it was believed that a better controller could be designed such that it would interact more delicately with the feeding network, a mathematical model based on a Hamiltonian system of the three-phase AC/DC converter was suggested (see [1]). In that approach the inductance of the feeding network was modeled as a separate inductor, Lsin fig.1. Such systems are referred to

as Port-Controlled Hamilton (PCH) in some articles like [3].

In addition, that Hamiltonian model was linearized in [1] since converters, in general, are believed to be nonlinear due to the "nonlinearities in the electronic switches and the external disturbances [4]". Then a strategy to find a control law was proposed in [1] to achieve the two important targets: keeping the output voltage constant and reducing the ripples in the input voltage.

In our project, we merely simulated the model of the single-phase DC/DC buck converter sug-gested in [1] using the so-called S-Function (stands for system-function) in MATLAB/SIMULINK. We think that this simulation can be considered as one of the most important results of this project, since simulating a multi-input multi-output system using S-functions as not a common task in lit-erature. From this simulation we prove that the ripples in the input voltage (THD) are caused by the interaction or resonance between the feeding network and the controller of the converter. In addition, we prove that increasing the output capacitance of the rectifier would solve the problem, however as mentioned earlier this would be a very expensive solution. Finally, we could find a control law which could keep the output voltage constant and the ripples in the input voltage mini-mum. Unfortunately, we could not prove that this control strategy would work for the three-phase AC/DC converter because our simulations were for a single-phase DC/DC converter only.

(6)

In section 4 we present another model for the buck DC/DC converter based on transfer functions proposed by B. Johansson [5] together with its simulation in MATLAB then we set a comparison between the simulation of this model with the simulation of the Hamiltonian system to show that they are equivalent.

In section 5 we introduce the linearized Hamiltonian system suggested in [1] to adapt with the nonlinearities in the DC/DC buck converter, then we simulate this model in two different cases; the first when the duty-cycle is constant and the second when the duty-cycle is varying with time. Then we show the simulation of the model based on the transfer functions proposed in [5] again but this time when the duty-cycle is varying with time to compare the results of the two simula-tions and to prove eventually that the linearized Hamiltonian system is equivalent to the transfer functions except at certain ranges of frequencies due to the resonance between the converter and the input filter.

In section 6 we use the simulations explained in section 5 to analyze the ripples in the input voltage to show that they are caused by the resonance between the input filter and the converter, then we show that these ripples can be suppressed by using large capacitance at the output of the filter. In section 7 we introduce a better control strategy proposed in [1] based on augmenting the Hamil-tonian system by adding a suitable target output and finding a suitable control law for this aug-mented system to show eventually that the Hamiltonian system is controllable and it can be used to achieve the two targets mentioned above: keeping the output voltage constant and reducing the ripples in the input voltage as suggested in [1]. Finally, in section 8 we try to point out some conclusions from the results we had and recommendations for future work.

2

Literature Review

Actually, AC/DC converters have been representing a fertile field for researches and studies, and going through them was really troublesome. One can classify these articles into two main cat-egories: low power converters and high power converters. Of course, we are not so interested in the low power converters since most of the researchers in that field attack the problems of the converters from electronic point of view and these components are usually sensitive to high power, for further information the reader is advised to see articles like [6].

On the other hand, many articles try to address the problems of the high power converters by suggesting new topologies. For example, the authors of [2] suggest a new controller for a new converter topology called Single-Ended Primary Inductance Converter (SEPIC). They prove that this controller can "reduce the (THD) of the input current, increase the power factor at the AC side of the converter and at the same time keep the output voltage regulated [2]".

Similarly, L. Yang et al. in [7] proposed a new topology for the three-phase AC/DC converter which "comprises two converters: Buck-boost converter at the input and a forward DC/DC con-verter at the output [7]". Eventually, they proved by simulations that this proposed concon-verter would reduce the (THD), adjust the output voltage and reduce the ripples of the input voltage.

While, Y. W. Li in [8] proposed completely different methods to reduce the ripples caused by this resonance, then he compared between these methods to conclude that the choice of the best method depends on the load. One of the methods he suggested was to use a virtual damping re-sistance [8]. Bearing in mind that a rere-sistance could damp these ripples but this would increase the conduction losses so the efficiency would decrease, Y. W. Li in [8] suggested using multipliers and/or differentiators to give the effect of a resistance without causing losses.

(7)

error between the output voltage and a reference voltage. To find the control law, they used the pole-placement technique. We think that this proposal is the closest from all the literature we have found to that in [1]. However, in [4] the authors did not use the Hamiltonian model. Furthermore, they used the pole-placement technique in which one finds a characteristic polynomial from the state-space model, the degree of this polynomial is equal to the number of states used in the model. Then the coefficients of this polynomial are found such that the poles are placed in the Left Half Plane (LHP) of the s-domain to ensure stability, then the control law can be determined from these coefficients. Apparently, in this technique one needs to choose the locations of the poles of the characteristic polynomial and this usually involves guessing specially when one does not have a clear criterion to locate these poles. In [4], the model suggested has five states, i.e., five poles have to be located and as we understood the only criterion set by the authors for locating these poles is that "the linearized averaged models are generally valid up to about 1/5 of the switching frequency [4]". While, using the technique suggested in [1] to find the control law one has to guess only three parameters as will be shown later, so we think that the latter technique would be less complicated. The Hamiltonian system by itself is not a new strategy, it was suggested "by Maschke et al. (1995), van der Schaft and Maschke (1993) [9]". Since then the Hamiltonian formalism has been used in many articles to describe the converters and their controllers, for example you can see [9]. Another example is in [10], where the authors held a comparison between the port-Hamiltonian systems (PH) and the Brayton − Moser equations (BM) to conclude that they were some discrepancies be-tween the two models so they suggested some kind of criteria to know when one should use either of them.

Actually, we found two articles in which the authors suggested the use of the Hamiltonian sys-tem to model the AC/DC converters. In [3] the authors described the 3-phase AC/DC converters based on the (PCH) theory in "dq rotating frame [3]", which is different from the technique used in [1]. The second is presented in [11], in which the authors compare three approaches to improve the controllers of the AC/DC converters using "Lyapunov control theory, passivity control theory using Euler-Lagrange( EL) model and port controlled Hamiltonian with dissipation (PCHD)model [11]". They concluded that using Lyapunov control theory would make the system too complex, and the (PCHD) would not deliver good dynamic performance, while the EL model would be a better choice. Conversely, in [1] it is believed that the (PCH) would provide better control of the AC/DC converter, unfortunately we could not prove that because our simulations were for a single-phase DC/DC converter. However, the results we had were so promising as will be shown in this report.

The Hamiltonian model suggested in [1] was based on previous work. In [12], M. Karlsson et al. used the so-called graph theory to model the switched electrical circuits like converters by a Hamiltonian system of differential algebraic equations. For further information on using the graph theory in Modeling the switching circuits the reader is advised to read [13].

Whereas, H. Cormerais et al. in [14] formulated a Hamiltonian model for a serial converter based on the so-called bond graph formalism which is a different approach to construct models of switching circuit.

In addition to all that, we have found many articles in which the authors treat the signals and parameters as probabilistic or stochastic signals, for example, some of them suggest using fuzzy logic controllers [15]. However, this approach is far from our model presented in this report because we try to treat the controller and its parameters in a deterministic approach. For further reading in that field see [16] and [17].

(8)

is a technique that can be implemented by codes written as M-files in MATLAB, or C-MEX files (using C, C++ or Fortran) or by ready-made blocks in SIMULINK as will be explained later. Many of those who mentioned the use of the S-Functions used the ready-made blocks from the SIMULINK library, minority only use the programming technique. For example, the authors in [? ] used S-function technique to model and simulate aircraft movement, and they implemented it by C-MEX file written by C, which is a clever choice because these languages give more flexibility in programming while we chose to use M-Files.

In summary, we think that the model suggested in [1] with its simulation presented here is different from other treatises in the sense that:

1. It models the inductance of the feeding network as a separate inductance Lsin fig.1 to study

its effect on the ripples in the input voltage.

2. It provides a control strategy that aims to reduce the ripple at the input voltage and keep the output voltage constant simultaneously with less complexity than others like [4] for example.

3. The simulation was made in MATLAB/SIMULINK using S-Functions, and to our best knowledge, we have not seen a simulation like that for multi-input multi-output switching circuits.

3

Hamiltonian Model of the DC/DC converter

A Hamiltonian model of the DC/DC converter was suggested in [1] . This model is expected to be non-linear, and to linearize it a DC-Solution must be found as a first step by simulating the model. In this section the Hamiltonian model is presented. Then the simulation using MATLAB of this model is elucidated in two different techniques to find the DC-Solution. In the first technique the model is treated as a multi-input multi-output system, which makes the simulation so cumbersome. Instead, in the second technique the model is treated as a single-input single-output system as suggested in [1]. Then the results of these simulations which represent the desired DC-Solution are shown and compared to deduce eventually the equivalence of the two techniques.

3.1 Hamiltonian system

The whole idea is to formulate the converter as a Hamiltonian system using the so-called graph theory. The derivation of this Hamiltonian system is beyond our research here, but it is presented in [1]. So we leave the mathematical details of the derivation and start directly with the simulation after presenting the system.

Fig.1 shows a schematic circuit of the model of the DC/DC buck converter. The switch (S) is con-trolled by a signal from the controller denoted by dn, this control signal is actually the pivot around

which this project revolves. dnis supposed to assign the value of the duty-cycle d of the converter,

which is the ratio of the time interval during which the switch is ON (ton) to the switching period

(T ) i.e., d =ton T .

To illustrate the action of the duty-cycle d see fig.2. If the input voltage vmain and d are

con-stant, we can see from fig.2 that the output voltage vo will be constant and equal to vmain during

the time interval tON which is equal to dT and zero for the rest of the switching period T . The

average output voltage denoted in the figure by (v_av) can be calculated as follows: v_av =T1 Z T 0 vmaindt= vmain× dT T = dvmain

(9)

Figure 1: The model of the DC-DC buck converter

Figure 2: A sketch to illustrate the action of the duty-cycle d. Output voltage vo solid, average

(10)

The section of the circuit after the switch (S) models the DC/DC buck converter in its simplest form, while the section before (S) comprises two elements:

• Ls: models the inductance of the conductors of the feeding network.

• Cf: the output capacitance of the rectifier used before the converter.

We restricted ourselves to the notation used in [1] all through the equations in this report. So the capacitances C and Cf were replaced by C1 and C2 respectively, the inductances L and Lsby L1

and L2respectively, while the resistances RCand R were replaced by R4and R5respectively.

In order to model the system one usual defines states according to (see [1]):

x=     x1 x2 x3 x4     =     q1 q2 φ1 φ2     =     C1uC1 C2uC2 L1iL1 L2iL2     (1) where

q1and q2: represent the charges on C1and C2respectively.

φ1and φ2: represent the flux through L1and L2respectively.

i4: corresponds to the current through R4.

iin: corresponds to the current through the main supply as shown in fig. 1.

uC1 and uC2: correspond to the voltages across C1and C2respectively.

iL1 and iL2: correspond to the currents through L1and L2respectively.

Because of the switch (S) the mathematical model of the system will be a state space ABC-system where the matrices shift between two modes. This is done for such a high frequency so one can obtain what is called a continuous state average model of the system. The state vector of this model is here denoted by xawhere the subscript "a" alludes to "average". This system is given by

the following equations (see [1]): ˙ xa= Jx(d) ∂ H(xa) ∂ xa + −N Bx   Mz−1za u  (2)  −za wa  = −N Bx T∂ H(xa) ∂ xa +  −Jz −Bz BTz −JD   Mz−1za u  (3) zand w form the output of this system and they are given by (see [1]):

z=  z1 z2  =  i4 vo  , w = (−iin) (4)

while the input u is given by (see [1]):

u= (vmain) (5)

The rest of the quantities used in equation (2) and (3) are given below (see [1]):

(11)

in the preceding equation d is the duty-cycle we talked about earlier Mx= diag(C1,C2, L1, L2) =     C1 0 0 0 0 C2 0 0 0 0 L1 0 0 0 0 L2     (7) N=     0 1 0 0 1 0 0 0     (8) Bx=     0 0 0 1     (9) Bz=  0 0  (10) Jz=  0 −1 1 0  (11) JD= (0) (12) Mz= diag(R−14 , R5) =  R−14 0 0 R5  (13)

Finally, the variable H represents the Hamiltonian of the system which "expresses the energy of the system [1]". We present a basic definition of the Hamiltonian H as stated, for example, by G. Escobar et al. [9] in their article:

H(x) = 1 2x

T

Qx (14)

where Q is a "diagonal matrix containing the circuit parameters 1\Ci, 1\Li[9]", we think that this

is the most basic definition of the Hamiltonian for further information the reader is recommended to read [1].

It is expected that the Hamiltonian system described by equations (2) and (3) is not linear because of the switch operation and to linearize it (see section.5) one has to begin by finding a point around which the system can be linearized. This point is called here the ’DC-solution’ of the Hamiltonian system which is sufficient -at least at this stage- to provide a good comparison between the two techniques used for the simulation of the Hamiltonian system. Without going through the math-ematical details this ’DC-solution’ can be found from the following equations which results after some manipulations to cancel the term ∂ H(xa)

∂ xa from equations (2) and (3) (see [1]):

(12)

 −zaD waD  = −N Bx T Mx−1xaD+  −Jz −Bz BTz −JD   Mz−1zaD uaD  (16)

The subscript aD here denotes the DC-solution of the system. It should be noted here that the sys-tem described by equations (15) and (16) is considered multi-input multi-output syssys-tem because the input of this system is represented by the vector



Mz−1zaD

uaD



, while the output is considered to be

 −zaD

waD



and this made our task much harder as mentioned earlier.

3.2 Simulation of the Hamiltonian system-First Technique

We used S-function technique in MATLAB, because it extends the capabilities of SIMULINK and it would make it easier for us to edit the program and to adjust our simulation as much as we need. Actually, the S-function technique was not as easy as we expected, but eventually we could deal with it specially for this system which has multiple inputs and outputs. This simulation technique explained here can be considered one of the most important results of this project, because the S-function technique in MATLAB has not been used too often in simulation specially for systems with multiple inputs and/or outputs.

The S-function technique is a tool in MATLAB/SIMULINK to describe a SIMULINK block. This tool can be implemented by: an M-file in MATLAB, a C-MEX file (written by C, C++ or FOR-TRAN) or the S-function builder which contains some kind of ready-made blocks. We used the level-2 M-file language to implement this tool for simplicity, and herein we summarize the steps:

1. Build a block for the model in SIMULINK. No need to use the ready-made blocks, only the To Workspace block to store the output and/or input variables, Level-2 M-file S-Function block to contain in a way the code (which is called M-File) that includes the commands to operate SIMULINK and a Source block to assign the input of the desired type.

2. Write an M-File i.e. a code in which one should assign the parameters of the simulation to the desired values, start the simulation by invoking the block of the model and plot the required signals.

3. Write another M-File that operates the block. The language used to write this M-File is object-oriented so certain methods must be called as Inputs, Outputs, Derivatives,.. which correspond to the input, output, derivatives,.. of the state-space model of the system and then a code is written for each method.

4. Finally, open the block of the model by double-clicking it to set the second M-File as a source file and to set the parameters used.

To simulate the model described by equations (15) and (16) above by the means of the S-functions we firstly commenced as mentioned above by building the model block shown in fig.3 in SIMULINK (we dropped the aD-subscript in the codes to simplify the notations). In this model we used a DC value of the input voltage u of 350V . This value may not be as close as wanted to the values used by MicroPower, and even not based on a justified reasoning. However, the value by itself is not so important since we are interested in the harmonics only.

(13)

Figure 3: The model used to simulate the system using SIMULINK specifications of MicroPower for their charger listed in [1] and are listed here:

C1 = C = 47µF C2 = Cf = 12.7µF L1 = L = 344µH L2 = Ls = 500µH R4 = RC = 50mΩ R5 = R = 2Ω D = 0.5 (17)

It should be mentioned here that some of the values listed in equations (17) lack the reliability required for this simulation because Ls∈ [100, 500]µH according to [1]. This surely will make

our task harder since we have to check and to try as will be shown later. Actually, determining the value of Ls is an important task by itself, because Ls models the inductance of the feeding

network so it can not be measured it can only be estimated based on the resonance frequency as will be demonstrated later. However, we chose it to be 500µH and this will be justified later (see section.6).

In addition, RC was estimated roughly because we did not have a clear clue about its value.

Finally,R is supposed to be set to suit the output power which is in the order of 8KW , but the output power depends on the output voltage which in turn depends on the duty-cycle so we de-cided to estimate the values randomly and to keep them the same through out all simulations. Actually, this is not as bad as it looks because we believe that the harmonics we are interested in depend mainly on the values of Cf, C, L and Ls.

We decided to plot the signals of the state vector xaDand the output vector

 −zaD

−waD



. Note that waDby definition is negative so we multiplied it by a negative sign just to make the graph smaller.

(14)

M-File is written here: RunConverter65: %RunConverter65 C1=47e-6; C2=12.7e-6; L1=344e-6; L2=500e-6; R4=50e-3; R5=2; D=0.5; tspan = [0 0.1]; optionvec=simset(’MaxStep’,0.01,’RelTol’,1e-5); optionvec=simset(optionvec,’InitialState’,[0 0 0 0]); plot(t,x(:,1),t,x(:,2),’:’,t,x(:,3),’-.’,t,x(:,4),’-’);

figure(2); %Generating the graph in fig.4(a)

title(’The Signals of the State vector’) xlabel(’Time(seconds)’);

ylabel(’Signal Amplitude’);

figure(3) %Generating the graph in fig.4(b)

plot(t,-z1,t,-z2,’:’,t,-w,’-.’);

title(’The signals of the output vector’) xlabel(’Time(seconds)’);

ylabel(’Signal Amplitude’);

The second M-File which we called (msfn_Converter65) is used to tell the block created in SIMULINK for the model how to proceed based on the Hamiltonian system given by equa-tions (15) and (16). To do that, we had to obtain a straight forward formulas for these equaequa-tions, because MATLAB deals with the outputs and the derivatives of the states separately, i.e., in the Derivative and Output methods we had to write directly the formulas of each output and state derivative. In fact we think it is impossible to assign the formulas of the outputs and derivatives of the states otherwise. So we inserted equations (10) to (17) in the Hamiltonian system given by equations (15) and (16) to get:

˙ xaD=           xaD3/L1− zaD2/R5 −DxaD3/L1+ xaD4/L2 −xaD1/C1+ DxaD2/C2− R4zaD1 −xaD2/C2+ uaD           (18)  −zaD waD  =       −xaD3/L1+ zaD2/R5 −xaD1/C1− R4zaD1 −xaD4/L2       (19)

Now, we could easily assign to each output and state derivative its own formula as shown in the M-File below:

(15)
(16)

C1 = block.DialogPrm(1).Data; R4 = block.DialogPrm(5).Data; x1 = block.ContStates.Data(1); z1 = block.OutputPort(1).Data; block.Dwork(1).Data = -x1/C1 + R4*z1; function Derivative(block) C1 = block.DialogPrm(1).Data; C2 = block.DialogPrm(2).Data; L1 = block.DialogPrm(3).Data; L2 = block.DialogPrm(4).Data; R4 = block.DialogPrm(5).Data; R5 = block.DialogPrm(6).Data; D = block.DialogPrm(7).Data: u = block.InputPort(3).Data; x1 = block.ContStates.Data(1); x2 = block.ContStates.Data(2); x3 = block.ContStates.Data(3); x4 = block.ContStates.Data(4); z2 = block.OutputPort(2).Data; z1 = block.OutputPort(1).Data; block.Derivatives.Data(1)=x3/L1 + z2/R5; block.Derivatives.Data(2)=-D*x3/L1 +x4/L2; block.Derivatives.Data(3)=-x1/C1 + x2*D/C2 + R4*z1; block.Derivatives.Data(4)=-x2/C2 + u;

In the above M-File several methods were used, each method is invoked by the command function method name (block)

To explain thoroughly this M-File the methods are listed here:

a. setup: It is a compulsory method used to assign the various factors required for the simulation of the block such as the number of input ports and output ports and the dimension of each one, the number of the parameters (i.e. the constants) needed for the simulation, the number of the states, the feedback possibility and the other methods required in the rest of the M-File. b. DoPostPropSetup: It is used to activate and define one (Dwork) vector (or more) which is

(are) used to store any variable(s) temporarily. In this method the dimension and name of each (Dwork) vector must be assigned.

c. InitConditions: It is used to set the initial conditions of the states and the (Dwork) vector. d. Output: It is used to set a formula for each output in the output vector according to the

state-space description of the model. The parameters used in these formulas must be declared before being used.

e. Update: It is used to update the (Dwork) vector because it is temporary. The parameters used in these formulas must be declared before being used.

f. Derivative: It is used to set a formula for each state derivative according to the state-space description of the model. The parameters used in these formulas must be declared before being used.

We assigned three input ports, namely: u, R4z1and Rz15, and three output ports: z1, z2 and w, that

(17)

achieve the desired inputs as shown in fig.3. With this feedback MATLAB could not calculate the output even if the initial values were assigned, so it was necessary to use the (Dwork) function, which we used to store the output z2in a (Dwork) vector to be used later.

In fact, this code took us too much time to design. As will be shown later, the complexity of this code was avoidable given that the Hamiltonian system described in equations (15) and (16) can be simplified by a usual, single-input single-output state-space description. However, M. Lennels recommended us to include this complex technique to show that MATLAB and SIMULINK have a strong ability for simulation even for complex systems.

3.2.1 Results and Analysis by the First Technique

After running theses codes in MATLAB we got two graphs; fig.4(a) which shows the variation of the states xaD1 to xaD4 with time, and fig.4(b) which shows the variation of the output signals

with time. These results form the DC-solution sought. Actually, the results coincide with our expectations bearing in mind that zaD2 = vo,aDand waD= iin,aD. We notice that the output voltage

vo is constant and equal to 175V , which is true since the input voltage u and the duty cycle D

used are both constant and their values are (350V ) and (0.5) respectively. At this stage, we have to document also the final values of the states because we will need them later:

(18)

(a)

(b)

Figure 4: (a) The graph representing the solutions of the state-vector (xaD). (b)The graph

repre-senting the solutions of the output vector 

−zaD

−waD

(19)

3.3 Simulation of the Hamiltonian system-Second Technique

Now we present another technique to simulate our Hamiltonian model using S-Functions in MATALB. Other equations which describe the linearized solution of the system were derived in [1] to sim-plify the simulation. This system of equations was described in the usual state-space form and contained one input and one output (We mean by one output here one vector which may con-tain several elements). We could imitate this system to present an easier technique for the ’DC-solution’ described previously because it made our simulation much easier than the first technique described earlier, the system is presented here (see [1]):

˙ xaD= Fx,xxaD+ Fx,uuaD (21) zaD= Fz,xxaD+ Fz,uuaD (22) waD= BTxMx−1xaD+ BTzMz−1zaD− JDuaD (23) where Fx,x= (Jx(D) − NMz−1(I − JzMz−1)−1NT)Mx−1 (24) Fx,u= (Bx− NMz−1(I − JzMz−1)−1Bz) (25) Fz,x= (I − JzMz−1)−1N T Mx−1 (26) Fz,u= (I − JzMz−1)−1Bz (27)

Of course the vectors xaD, zaDand waDare the same as those described earlier. The matrices Jx(D),

Mx, N, Bx, Bz, Jz, JDand Mzare also given by equations (10) to (17) respectively. As mentioned

earlier, this form of matrix equations is not practical to use in S-functions, so we had to find the outputs and the derivatives of the states directly as shown below:

˙ xaD=             −xaD1 C1(R4+R5)+ R5xaD3 L1(R4+R5) −DxaD3 L1 + xaD4 L2 −R5xaD1 C1(R4+R5)+ DxaD2 C2 − R4R5xaD3 L1(R4+R5) −xaD2 C2 + uaD             (28) zaD=    −xaD1 C1(R4+R5)+ R5xaD3 L1(R4+R5) R5xaD1 C1(R4+R5)+ R4R5xaD3 L1(R4+R5)    (29) waD=  xaD4 L2  (30)

(20)

Figure 5: The model used to simulate the system described by equations (21) and (22).

order to the model to operate and it was called RunConverter65_1st. The other contained the equations needed to operate the model and it was called msfn_converter65_1st. The model block is shown in fig.5 below. Unlike the model in fig.3 we had here one input: u which represented uaDin the previous equations and it was chosen to be 350V as in the previous model,

and one output zaD.

The first M-File used for this simulation is presented here, the values of the various parameters used here were as same as the values used in the previous simulation:

RunConverter65_1st: %RunConverter65_1st C1=47e-6; C2=12.7e-6; L1=344e-6; L2=500e-6; R4=50e-3; R5=2; D=0.5; tspan = [0 0.1]; optionvec=simset(’MaxStep’,0.01,’RelTol’,1e-5); optionvec=simset(optionvec,’InitialState’,[0 0 0 0]); ([t,x])=sim(’ModelConverter65_1st’,tspan,optionvec);

figure(4) %Generating the graph in fig.6(a)

plot(t,x(:,1),t,x(:,2),’:’,t,x(:,3),’-.’,t,x(:,4),’-’); title(’The Signals of the State vector’);

xlabel(’Time(seconds)’); ylabel(’Signal Amplitude’);

figure(5) %Generating the graph in fig.6(b)

plot(t,z_aD(:,1),t,z_aD(:,2),’:’);

title(’The signals of the output vector’) xlabel(’Time(seconds)’);

ylabel(’Signal Amplitude’);

figure(6) %Generating the graph in fig.6(c)

(21)

title(’The signals of w_aD’) xlabel(’Time(seconds)’);

ylabel(’Signal Amplitude in (A)’);

The second M-File used in this simulation is written here, and in this M-File the details of equa-tions (28) and (29) are included:

(22)

block.Derivatives.Data(1)=-x1/(C1*(R4+R5))+R5*x3/(L1*(R4+R5)); block.Derivatives.Data(2)=-D*x3/L1+x4/L2;

block.Derivatives.Data(3)=-R5*x1/(C1*(R4+R5))+D*x2/C2-R4*R5*x3/(L1*(R4+R5)); block.Derivatives.Data(4)=-x2/C2+u;

This M-File is much easier than (msfn_Converter65), as can be seen the methods DoPost-PropSetup and Update were not used here. The dimensions of the output port was set to two because zaDis a 2x1 vector, while the dimension of the input port was set to one because u is a

scalar.

3.3.1 Results and Analysis of the Second Technique

This simulation was designed to give three graphs, they are depicted in fig.6 below. Fig.6(a) shows the variations of the states xaD1 to xaD4 with time, fig.6(b) shows the variation of the output zaD

which is a 2x1 vector with time, while fig.6(c) shows the variation ofxaD4L

2 with time which is equal

(23)

(a)

(b)

(c)

Figure 6: (a)The graphs representing (a) The solutions of the state vector (xaD) (b) Tthe solutions

(24)

Obviously, the results presented in fig.6 are identical to those presented in fig.4 and shown in equation (20), which means that the two techniques are identical. For simplicity we used this easier technique in the next simulations.

In summary of this section, we presented the Hamiltonian model of the DC/DC Buck converter, we explained in details two techniques that can be used to simulate that model using the so-called S-functions in MATLAB and we proved that the two techniques give the same results. In addition, the results obtained from these simulations were documented as a DC-Solution in equation (20) to be used later to linearize the Hamiltonian system.

4

Transfer Functions

B. Johansson in his PhD thesis [5] formulated different transfer functions for several kinds of DC-DC converters. In this section we introduce his model for the DC-DC/DC-DC buck converter represented by transfer functions, then we present a simulation of this model using same values used in pre-vious simulations and finally we compare the results of this simulation with the results we had in the preceding section to show that the Hamiltonian model suggested in [1] matches the transfer functions suggested by in [5] at least when the duty-cycle signal is constant with time.

4.1 Transfer functions of the DC/DC buck converter

For buck converters the author of [5] used a model similar to our model presented in fig.1, but he did not consider the input part components Ls and Cf, because his work was concentrated on

the converter itself, while we are more concerned with the interaction between the converter, the rectifier and the feeding network. However, this model still resemble our model and thus we think that a comparison between our results in the previous section and the results of the simulation of his model will be of great help.

Of these transfer functions we chose two which will be easier to compare with our results. The transfer functions are presented here keeping the same notation used through our report (see [5]):

Vo(s) D(s) = H1(s) = R5u(1 + sR4C1) R5+ s(L1+ R4R5C1) + s2(R4+ R5)L1C1 (31) IL1(s) D(s) = H2(s) = u(1 + s(R4+ R5)C1) R5+ s(L1+ R4R5C1) + s2(R4+ R5)L1C1 (32) Where of course, the symbols C1, L1, R4, R5, u and vo(t) represent the same quantities as before.

iL1(t) is the current through the inductor L shown in fig.1 which was called L1, while d(t) is the

signal used to control the duty cycle.

4.2 Simulation

The following M-file was used to simulate the transfer functions presented above in equations (31) and (32):

(25)

Ad=0;

H1=tf([R4*R5*C1*u R5*u],[(R4+R5)*L1*C1 (R4*R5*C1+L1) R5]); H2=tf([(R4+R5)*C1*u u],[(R4+R5)*L1*C1 (R4*R5*C1+L1) R5]); t=linspace(0,1,2000);

d=D+Ad*sin(w_in*t);

figure(1) %Generating the graph in fig.8(a) and fig.12(a)

lsim(H1,d,t)

title(’Signal Of Output Voltage with time’, ’fontsize’,14) ylabel(’v_o(t) (V)’, ’fontsize’, 12)

xlabel(’Time’,’fontsize’,12)

figure(2) %Generating the Bode diagram in fig.7(a)

bode(H1),grid

title(’Bode Diagram of H_1(j\omega)’,’fontsize’,14)

figure(3) %Generating the graph in fig.8(b) and fig.12(b)

lsim(H2,d,t)

title(’Signal Of the current i_{L_1}’, ’fontsize’,14) xlabel(’Time’,’fontsize’,12)

ylabel(’i_{L_1}(t) (A)’,’fontsize’,12)

figure(4) %Generating the Bode diagram in fig.7(b)

bode(H2),grid

title(’Bode Diagram of H_2(j\omega)’,’fontsize’,14)

The same values of the parameters were used to ensure fair comparison with the results shown in equation (20), fig.4 and fig.6.

Actually, we are interested in the interaction between the DC/DC converter and the input filter. More precisely, we intend to study the effect of the control signal d(t) on the ripples at the input of the converter. So, the control signal d(t) was set in the code above to the function D + Adsin(ωint),

which consists of two parts:

a) The DC-part set to a value of 0.5.

b) The time-varying part because this code is used later when the control signal d(t) is assumed to be varying with time to study the relation between the controller and the input filter. For the simulation purposes the time-varying part of d(t) was assumed to be sinusoidal of amplitude Ad and angular frequency ωin= 2π finwhere fin is the proposed frequency of the variation of

the duty-cycle signal that controls the switch (S) in fig.1 and it is different from the switching frequency itself. From here on this frequency will be called the input frequency and denoted by fin, while switching frequency is denoted by fs.

For this simulation, the time-varying part was canceled by setting its coefficient Ad to zero just

like in the simulation of the Hamiltonian system presented earlier in section.3.

4.3 Results and Analysis

After running the code above four diagrams were obtained; fig.7 which depicts the the bode dia-grams of the transfer functions H1( jω) and H2( jω). And fig.8 which depicts the signals vo(t) and

iL1(t).

The results are quiet identical to those obtained from the simulation of the Hamiltonian model shown in equation (20), fig.4 and fig.6. The output voltage vo(t) is constant and equal to 175V ,

so is iL1(t) and it is equal to 87.5A. It may not be so clear that iL1(t) is as same as the value

(26)

(a) (b)

Figure 7: The bode diagrams of the transfer functions (a)H1( jω), and (b)H2( jω) given in

equa-tions (31) and (32) suggested by B. Johansson [5].

(a) (b)

Figure 8: Results of the simulation of the model of the transfer functions suggested by B. Jo-hansson [5] when d(t) is constant: (a)vo(t), and (b)iL1(t). The graphs are zoomed in to show the

behavior of the signals before reaching stability.

that iL1 =

x3

L1 from equation (1), and x3 was obtained to be constant and equal to 0.0301 in

equa-tion (20)from the simulaequa-tion of the Hamiltonian model, so inserting the value of the parameter L1= 344 × 10−6Hwe get that iL1=

0.0301

344×10−6 = 87.5A which is equal to the value obtained in fig.8.

In conclusion of this section, we can say that from this humble comparison that the Hamiltonian model suggested in [1] describes the model of the DC/DC buck converter identically to the transfer functions proposed in [5], at least when the control signal is constant. In the next section we check the case when the control signal d(t) is not constant.

5

The Linearized Hamiltonian Model

(27)

show that the two systems are equivalent when the duty-cycle signal is not constant but for merely certain ranges of input frequencies. Furthermore, we show that these frequencies in which the equivalence between the two systems is invalid are due to the resonance in the input circuit of our model.

5.1 Linearizing of The Hamiltonian Model

There are a few different strategies to linearize a signal (see). One of the most well-known strate-gies is to find a DC point and consider the variations of that signal around it within a small range. This DC point was already found in section.3 and it was called there the ’DC-solution’ and it is given by equation (20). The equations of the linearized system are similar to those used before with a slight difference that will be explained after presenting them (see [1]):

˙˜xl= Jx(D)Mx−1x˜l+ BDd˜+  −N Bx   Mz−1˜zl ˜ u  (33)  −˜zl ˜ wl  = −N Bx T Mx−1x˜l+  −Jz −Bz BTz −JD   Mz−1˜zl ˜ u  (34) The difference between equations (15), (16) and equations (33), (34) is the tilde sign, which de-notes the linearized difference of each variable from its ’DC-solution’ as follows (see [1]):

˜ xl= x − xaD, ˜zl = z − zaD (35) and ˜ wl= w − waD, ˜u= u − uaD, ˜d= d − D (36) and BD= (Jx(d) − Jx(D))Mx−1xaD=            0 −xaD3 L1 xaD2 C2 0            (37)

Of course, we need to prove that this linearized Hamiltonian system represented by equations (33) and (34) above is equivalent to the transfer functions proposed in [5] in equations (31) and (32). It would be reasonable to find the transfer functionVo(s)

D(s) or IL1(s)

D(s) from this Hamiltonian system above

in (33) and (34) and compare them with the transfer functions H1(s) and H2(s) in equations (31)

and (32), but this would be a tedious task to do due to the complexity of the Hamiltonian system. So, instead we compare the results after carrying out the two simulations at different frequencies, and from this comparison we show the equivalence of the two systems.

At this stage, we need to say that the values of the ’DC-solution’ of the state-vector xaDin

equa-tion eq:xadresults were needed in this simulaequa-tion as can be seen in equaequa-tion (37), therefore all the parameters given in equation(17) were kept the same.

5.2 The simulation of the linearized Hamiltonian system

In section.3 two different techniques for the simulation of the Hamiltonian system were presented. It was proven that the two techniques are identical, but the second one was much easier than the first one. So, the second technique was used here also. This easier technique is described by the following equations (see [1]):

(28)

Figure 9: The model used to simulate the linearized Hamiltonian system described by equa-tions (38), (39) and (40) using SIMULINK

˜zl= Fz,xx˜l+ Fz,uu˜ (39)

˜

wl = BTxMx−1x˜l+ BTzMz−1˜zl− JDu˜ (40)

As we did in section.3 with the S-functions in MATLAB, we first constructed a block for the lin-earized model in SIMULINK as shown in the fig.9 below. In this model ˜d(t) was chosen to be a function of time in the form (Adsin(ωint)) because according to equation (36)

d(t) = d(t) − D = D + Adsin(ωint) − D = Adsin(ωint)

Thus we could change the control signal to get several simulations by changing the input frequency finof this signal. However, the value of ˜uwas set to zero here, because ˜u= u − uaDand as in the

earlier simulations uaD= 350V and u = 350V also.

Then we constructed two M-Files: the first was called RunConverter83_84, and the second msfn_Converter83_84. As explained earlier we needed to get an explicit formula for each of the derivatives and the outputs to insert them in the M-File. So, we inserted equations (24), (25), (26) and (27) in equations (38), (39) and (40) to get:

˙˜xl =              − ˜xl1 C1(R4+R5)+ R5x˜l3 L1(R4+R5) −D ˜xl3 L1 + ˜ xl4 L2 − xaD3 L1 ˜ d −R5x˜l1 C1(R4+R5)+ Dx˜l2 C2 − R4R5x˜l3 L1(R4+R5)+ xaD2 C2 ˜ d − ˜xl2 C2 + ˜u              (41) ˜zl=    − ˜xl1 C1(R4+R5)+ R5x˜l3 L1(R4+R5) R5x˜l1 C1(R4+R5)+ R4R5x˜l3 L1(R4+R5)    (42) ˜ wl =  ˜xl4 L2  (43) The first M-File is written here:

(29)

C2=12.7e-6; L1=344e-6; L2=500e-6; R4=50e-3; R5=2; D=0.5; tspan = [0 0.1]; optionvec=simset(’MaxStep’,0.01,’RelTol’,1e-5); optionvec=simset(optionvec,’InitialState’,[0 0 0 0]); ([t,x_tilde])=sim(’ModelConverter83_84’,tspan,optionvec);

figure(1) %Generating the graphs in fig.10(a) and fig.11(a)

plot(t,x_tilde(:,1),t,x_tilde(:,2),’:’,t,x_tilde(:,3),’-.’,t,x_tilde(:,4),’-’); title(’Signals of stae vector x_l’,’fontsize’,16)

xlabel(’Time(sec)’,’fontsize’,12)

ylabel(’Amplitude of the signal’,’fontsize’,12)

figure(2) %Generating the graphs in fig.10(b) and fig.11(b)

plot(t,z_tilde(:,1),t,z_tilde(:,2),’:’);

title(’Signals of output vector z_l’,’fontsize’,16) xlabel(’Time(sec)’,’fontsize’,12)

ylabel(’Amplitude of the signal’,’fontsize’,12)

figure(3) %Generating the graphs in fig.10(c) and fig.11(c)

plot(t,x_tilde(:,4)/L2)

title(’Signal of w_l’,’fontsize’,16) xlabel(’Time(sec)’,’fontsize’,12)

ylabel(’Amplitude of the signal (A)’,’fontsize’,12)

(30)

function Output(block) C1 = block.DialogPrm(1).Data; L1 = block.DialogPrm(3).Data; R4 = block.DialogPrm(5).Data; R5 = block.DialogPrm(6).Data; x_tilde1=block.ContStates.Data(1); x_tilde3=block.ContStates.Data(3); block.OutputPort(1).Data(1)=-x_tilde1/(C1*(R4+R5))+R5*x_tilde3/(L1*(R4+R5)); block.OutputPort(1).Data(2)=R5*x_tilde1/(C1*(R4+R5))+ R4*R5*x_tilde3/(L1*(R4+R5)); function Derivative(block) C1 = block.DialogPrm(1).Data; C2 = block.DialogPrm(2).Data; L1 = block.DialogPrm(3).Data; L2 = block.DialogPrm(4).Data; R4 = block.DialogPrm(5).Data; R5 = block.DialogPrm(6).Data; D = block.DialogPrm(7).Data; u_tilde=block.InputPort(2).Data; d_tilde=block.InputPort(1).Data; x_tilde1=block.ContStates.Data(1); x_tilde2=block.ContStates.Data(2); x_tilde3=block.ContStates.Data(3); x_tilde4=block.ContStates.Data(4); block.Derivatives.Data(1)=-x_tilde1/(C1*(R4+R5))+R5*x_tilde3/(L1*(R4+R5)); block.Derivatives.Data(2)=-D*x_tilde3/L1+x_tilde4/L2-0.0301*d_tilde/L1; block.Derivatives.Data(3)=-R5*x_tilde1/(C1*(R4+R5))+D*x_tilde2/C2-R4*R5*x_tilde3/(L1*(R4+R5)) +0.0044*d_tilde/C2; block.Derivatives.Data(4)=-x_tilde2/C2+u_tilde;

Note that the values of the state-vector xaDgiven in equation (20) were used in this M-File, this

may be a poor technique and it may affect the efficiency of the simulation of the linearized model.

5.3 Results and analysis

The simulation explained above were run and the results are discussed in the following subsec-tions:

5.3.1 When d(t) = D

The signal d(t) was set to the constant value D = 0.5, i.e. ˜d(t) = 0 in the model in fig.9. Af-ter running the simulation above we got the results shown in fig.10 which shows that all of the variables have zero values, and this makes sense because the tilde-signed variables represent the difference between the real values and the DC-solution as shown in equations (35) and (36), and in this case here they both are the same because the time-varying part of the duty-cycle was canceled by setting Adto zero, that is why the difference is zero.

5.3.2 When d(t) = D + Adsin(ωint)

The signal d(t) = D + Adsin(ωint) was then tried in our model of fig.9 to check the behavior of

this model when the duty-cycle signal is changing with time,i.e. ˜d(t) = Adsin(ωint) as mentioned

(31)

(a) (b) (c)

Figure 10: Graphs of the signals of (a) State vector ˜xl (b) output vector ˜zl(c) ˜wl. The tilde sign was

dropped from the figure for simplicity.

compared to the DC-part would be more realistic.

The real switching frequency fsused by MicroPower is around 50KHz. Note that the input

fre-quency finused to express the variation of the duty-cycle signal d(t) is different from the switching

frequency fs. To study the behavior of the system when the duty-cycle varies with time different

frequencies were tried, for example let us commence with the case when the input frequency fin

(32)

(a)

(b)

(c)

Figure 11: Graphs of: (a) The state vector ˜xl(b) The output vector ˜zl(c) ˜ xl4

L2 = ˜wlwhen fin= 1KHz.

(33)

(a) (b)

Figure 12: Results of the simulation of the transfer function model suggested by B. Johansson [5] when d(t) = 0.5 + 0.05sin(2π × 1000t): (a)vo(t), and (b)iL(t) = iL1(t). The graphs are zoomed in

by taking a window from 0 to 0.008s.

While the simulation of the transfer functions H1(s) and H2(s) in equations (31) and (32)

gave the results shown in fig.12 when the values of the Ad and ωin in the code given in

sec-tion.4 (TransferFunctions_vo/d and il/d) were set to 0.05 and 2π × 1000 respec-tively. Comparing fig.11 with fig.12 we see that both show that the signals oscillate about the DC-solutions obtained previously, bearing in mind that ˜zl2 = vo− vo,aDand

˜ xl3

L1 = iL1− iL1,aD. This

means that the signal of vo is oscillating around the DC-value vo,aD= 175V and similarly iL1 is

oscillating around iL1,aD= 87.5A.

Then, the oscillations themselves had to be compared. We began with the results of the simula-tion of the transfer funcsimula-tion in equasimula-tion (31) shown in fig.12(a), from which the amplitude and frequency of the oscillations could be determined. By taking peak values the frequency was found to be 1000Hz which was identical to the input frequency finused. While the amplitude was found

to be190−1602 = 15V . To check this amplitude it looked intuitive to calculate the amplitude of the transfer function H1(s) in dB at s = jωin= j2π × 1000, so:

|H1( jωin)| = 20 log(0.0515 ) = 49.5dB

From bode diagram in fig.7(a), it can be seen that this value is acceptable. The results of the sim-ulation of the linearized Hamiltonian system shown in fig.11(b) show that the frequency is again 1000Hz and the amplitude of the oscillation is 12V .

The preceding calculations were carried out for a wide spectrum of input frequencies to provide a good comparison between the two simulations. The results are presented in table(2) below, in which for every different input frequency the two simulations were run and different values were obtained:

• fin,T: The frequency of the ripples of vo(t) measured from the simulation of the transfer

function H1(s) in equation (31).

• Av,T: The amplitude of the ripples of vo(t) measured from the simulation of the transfer

function H1(s) in equation (31).

• fin,L: The frequency of the ripples of vo(t) measured from the simulation of the Hamiltonian

system defined by equations (33) and (34).

• Av,L: The amplitude of the ripples of vo(t) measured from the simulation of the Hamiltonian

(34)

• |H1( jωin)|: The magnitude of the transfer function H1(s) given by equation(31) obtained

from the bode diagram in fig.7(a).

Simulation of transfer function H1(s) Simulation of Hamiltonian system

fin(KHz) fin,T(KHz) Av,T(V ) 20 log( Av,T Ad )(dB) fin,L(KHz) Av,L(V ) |H1( jωin)|(dB) 0.5 0.5 17.0 50.6 1 16.3 50.5 1 1 15.0 49.5 1 12 49.5 2 2 6.0 41.6 2 11.2 43.0 2.5 2.5 4.2 38.5 2.5 31.4 38.6 3 3 3.0 35.6 3 5.6 36 4 4 1.7 30.6 4 2.0 31 4.5 4.5 1.3 28.3 4.5 1.5 28.5 5 5 1.0 26 5 1.1 26 7.5 7.5 0.5 20 7.5 0.45 20.5 10 10 0.27 14.6 10 0.2 15 12.5 12.5 0.175 10.9 12.5 0.15 11 15 15 0.12 8 15 0.1 6.0 20 20 0.07 2.9 20 0.016 3.5 25 25 0.045 -0.9 25 0.045 -1.0 30 30 0.032 -3.8 25 0.035 -3.5 40 40 0.02 -8.0 25 0.018 -7.5

Table 1: Comparison between the results of the simulation of the transfer function H1(s) in

equa-tion(31) obtained by B. Johansson in his PhD thesis [5] and the linearized Hamiltonian system in equations (33) and (34).

From table(2) many observations can be made:

1. The frequencies of the oscillations of vo(t) obtained by the two simulations are identical and

equal to the switching frequency in each case as expected, except at high frequencies where the oscillations obtained from the Hamiltonian system in equations (33) and (34) were less. 2. The values of 20log(Av,T

Ad ) are very close to the magnitude of the transfer function H1( jωin)

as expected.

3. The values of Av,Lare far from the values of Av,T when the input frequency fin∈ [1000, 3000]Hz,

and they are close otherwise.

The last observation is peculiar and it needs investigating. Here we have to remember that the author in [5] did not consider the inductance of the conductors of the feeding network Lsand the

output capacitance of the rectifier Cf-as mentioned earlier- when he proposed the transfer function

H1(s). Although it looks intuitive to cancel Lsand Cf in the Hamiltonian system by setting them

to zero and a very large value respectively, this is unfeasible because MATLAB does not accept zero as a value for Ls.

Actually, the values Lsand Cf play a crucial role in this project because it is believed that the main

reason of the unwanted ripples in the input signal is the resonance created by the inductance of the feeding network represented by Lswhich was set to 500µH and the rectifier output capacitance at

the input of the converter Cf which was set to 12.7µF, so:

fresonance= 1 2π√LsCf =

1

2π×√500×10−6×12.7×10−6 = 1997.25Hz

(35)

obtained by the two simulations since the resonance frequency ∼ 2000Hz is transfered to the out-put voltage which causes magnification in the amplitude of the outout-put voltage when the inout-put frequency is around 2000Hz.

Anyways, we will leave the issue of the resonance frequency to the next section and we conclude this section by the following result: The linearized Hamiltonian system describes the model of the DC/DC buck converter identically to the transfer functions even when the duty-cycle signal is changing with time at least when the input frequency finis not close to the resonance frequency.

6

Resonance frequency

The problem formulated by MicroPower is about unwanted ripples in the input voltage believed to be caused by the resonance between the inductance of the feeding network Ls and the output

capacitance of the rectifier Cf. We believe that the resonance is transfered to the output voltage

as explained in the end of the last section. So, in this section we try to estimate these resonance frequencies for different values of Lsby estimating the input frequencies at which the amplitudes

of the oscillations of the output voltage are magnified. Thus, we try to justify our choice of the value of 500µH for Ls. Then, we study the signal of the input voltage and show that increasing

the capacitance Cf decreases the amplitude of its ripples (i.e. suppresses these oscillations or in

other words shift them to lower frequencies), and thus makes the output signal obtained from the simulation of the linearized Hamiltonian system look more similar to that obtained from the simulation of the transfer function H1(s) presented in the previous section.

6.1 Resonance frequencies for different values of Ls

As we did in the last section we commenced by comparing the signal of vo(t) obtained by the

sim-ulation of the linearized Hamiltonian system in equations (33) and (34) suggested in [1] with that obtained from the simulation of the transfer function H1(s) in equation(31) suggested in [5] for

different values of the inductance of the feeding network Ls. Since Ls∈ [100, 500]µH according

to [1] we carried out this comparison for two other values of Ls: 100 × 10−6Hand 250 × 10−6H.

Tables (3) and (4) show these comparisons.

Just like table (2), tables (3) and (4) show that the frequencies of the oscillations of vo(t) obtained

from the simulation of the linearized Hamiltonian system in equations (33) and (34) are equal to the input frequencies used for the time-varying part of the duty-cycle unless the input frequency is high (> 30KHz). We can notice also that the amplitudes of those ripples are very close to the amplitudes of the ripples of vo(t) obtained from the simulation of the transfer function H1(s) in

equation(31) except the case when the input frequency is close to the resonance frequency, where the amplitudes are magnified. From tables (3) and (4) we can say that we have resonance when: fin∈ [4000, 5000]Hz for Ls= 100µH

fin∈ [2500, 3000]Hz for Ls= 250µH

Which seems realistic since the resonance frequency for Ls= 100µH can be calculated as follows:

fresonance= 1 2π√LsCf = 1 2π×√100×10−6×12.7×10−6 ≈ 4500Hz And when Ls= 250µH: fresonance=√1 LsCf = 1 2π×√250×10−6×12.7×10−6 ≈ 2800Hz

(36)

simulation of transfer function H1(s) Simulation of Hamiltonian system fin(KHz) Av,T(V ) fin,L(KHz) Av,L(V ) 0.5 17.0 0.5 17.0 1.0 15.0 1.0 14 2.0 6.0 2.0 5.9 2.5 4.2 2.5 3.8 3.0 3.0 3.0 2.8 4.0 1.7 4.0 2.2 4.5 1.3 4.5 7.6 5.0 1.0 5.0 2.6 7.5 0.5 7.5 0.5 10.0 0.27 10.0 0.23 12.5 0.175 12.5 0.16 15.0 0.12 15.0 0.13 20.0 0.07 20.0 ∼ 0.07 25.0 0.045 25.0 ∼ 0.04 30.0 0.032 24.0 ∼ 0.02 40.0 0.02 27.0 ∼ 0.02

Table 2: Comparison between the results of the simulation of the transfer function H1(s) in

equa-tion (31) suggested by B. Johansson [5] and the linearized Hamiltonian system in equaequa-tions (33) and (34) when Ls= 100 × 10−6H.

simulation of transfer function H1(s) Simulation of Hamiltonian system

fin(KHz) Av,T(V ) fin,L(KHz) Av,L(V ) 0.5 17.0 0.5 16.8 1.0 15.0 1.0 13.4 2.0 6.0 2.0 5.5 2.5 4.2 2.5 5.3 3.0 3.0 3.0 22.0 4.0 1.7 4.0 2.5 5.0 1.0 5.0 1.2 7.5 0.5 7.5 0.45 10.0 0.27 10.0 0.21 12.5 0.175 12.5 ∼ 0.17 15.0 0.12 15.0 ∼ 0.07 20.0 0.07 20.0 ∼ 0.07 25.0 0.045 25.0 ∼ 0.043 30.0 0.032 24.0 ∼ 0.023 40.0 0.02 27.0 ∼ 0.018

Table 3: Comparison between the results of the simulation of the transfer function H1(s) in

(37)

Furthermore, we have to mention another important result here about the choice of the value of Ls.

We said earlier in section.3 that determining the value of Lsis a crucial task and we said that we set

it to 500µH and here is the justification for this choice. The output capacitance of the rectifier Cf

has a value of 12.7µF from the schematic diagrams and specification sheets of the charger used by MicroPower listed in [1]. The inductance Lswas used to model the inductance of the conductors

in the feeding network of the charger, so it was very hard to estimate it. In addition to that, we did not have solid measurements of the resonance frequencies to depend on, but we understood that the unwanted ripples have a frequency around 2000Hz. So, assuming that the value of Cf is fixed

it looked reasonable to choose the value of Lsto be 500µH to get a resonance at a frequency of

2KHz.

Once again, this value was an estimation only and we did not intend to find good approximations of these values in our report, we were just trying to simulate the Hamiltonian system and to show that it is very close to the reality.

6.2 Increasing Cf and shifting resonance

One of the solutions suggested to the problem of the unwanted ripples at the input voltage is to increase the rectifier output capacitance Cf to shift the resonance frequency down to a very low

frequency. Despite the fact that this could be an expensive and impractical solution for the prob-lem, we used our simulation of the linearized Hamiltonian system to show that increasing the value of Cf eventually suppressed the ripples in the input voltage.

In order to show that, we should extract the signal of the input voltage from our simulation. This could be easily done using equation (1), from which we could see that the second state

x2= C2uC2

where, C2= Cf and uC2 is the voltage across that capacitor which is the input voltage for the buck

DC/DC buck converter. Therefore, we can say that: vin(t) = uC2 =

x2

C2

and thus, we could obtain the signal of the input voltage just by dividing the second state signal by the capacitance Cf= C2. In order to do that, we changed one line in the M-file RunConverter83_84

presented in the previous section to: plot(t,x_tilde(:,2)/C_2)

As an example, setting Ls, Cf to 500µH, 12.7µF respectively, and ˜d to 0.05sin(2π × 1000t)

we obtained the graph shown in fig.13. From that graph we could determine the amplitude and frequency of the oscillations. Actually these measurements were not as accurate as we wished be-cause the oscillations of the input voltage contain, in addition to the input frequency, the resonance frequency which distort the signal. However, we claim that these measurements were obtained to a satisfactory accuracy. Of course we have to bear in mind that the second state signal from our simulation of the linearized Hamiltonian system represents ˜xl2 not x2, this means that the

oscilla-tions that we obtained here were for the signal: ˜

xl2 = x2− xaD2 = C2v˜in= C2(vin− vinaD)

Where, the subscript aD denotes the DC-solution of each signal as mentioned earlier. Ls and

Cf was kept at 500µH and 12.7µF respectively. The duty-cycle signal ˜d(t) was also kept at

Adsin(ωint) with Ad= 0.05 and the input frequency fin varying to cover a wide range as we did

previously, then the amplitude and frequency of the oscillations of the input voltage were mea-sured. Table (5) shows these results against the old results of the output voltage, in which:

• fx˜2: represents the measured frequency of the oscillation of

˜ xl2 C2.

• Av, ˜x2: represents the measured amplitude of the oscillations of

˜ xl2 C2.

These measurements were repeated for two more values of Cf; 12.7 × 10−5F and 12.7 × 10−5F,

(38)

Figure 13: Signal ˜vin(t) when Cf = 12.7µF, Ls= 500µH and fin= 1000Hz zoomed in from 0.01s

to 0.015s. The tilde sign was dropped for simplicity.

fin(KHz) Av,L(V ) fx˜2(KHz) Av, ˜x2(V ) 1.0 12 1.0 25 2.0 11.2 2.0 75 3.0 5.6 3.0 51.7 4.0 2.0 4.0 21 5.0 1.1 5.0 13.5 10.0 0.2 10.0 0.5 20.0 0.016 20.0 2.7

(39)

Cf = 12.7 × 10−5F Cf = 12.7 × 10−4F fin(KHz) Av,L(V ) Av, ˜x2(V ) fin(KHz) Av,L(V ) Av, ˜x2(V ) 0.65 17.8 71.2 0.2 17.3 68.3 1.0 18.5 20.1 1.0 15.2 1 2.0 6.8 4 2.0 6.0 0.31 3.0 3 2.1 3.0 2.9 0.17 4.0 1.6 1.5 4.0 1.7 0.15 5.0 1.1 1.2 5.0 1.1 0.1 10.0 0.022 0.5 10.0 0.22 0.05 20.0 0.004 0.14 20.0 0.044 0.012

Table 5: Comparison between the oscillations of the input and output voltages as obtained from the simulation of the linearized Hamiltonian system in equations (33) and (34) when Cf = 12.7 ×

10−5F(Left) and Cf = 12.7 × 10−4F (Right).

Comparing the results in tables (5) and (6) we can extract the following observations:

1. The dominant frequency of the oscillations of the input voltage was equal to the input fre-quency fin.

2. The amplitudes of these oscillations were maximum at the resonance frequencies. The resonance frequencies for the three cases when Cf = 12.7 × 10−6F, 12.7 × 10−5F and

12.7 × 10−4F above are calculated here: fresonance,1= 1 2π√LsCf = 1 2π×√500×10−6×12.7×10−6 ≈ 2000Hz fresonance,2= 2π×500×101−6×12.7×10−5 ≈ 630Hz fresonance,3= 2π×500×101−6×12.7×10−4 ≈ 200Hz

which agree exactly with the results shown in the tables above, since the amplitudes Av, ˜x2(V )

at the three frequencies for the three capacitances were 75V , 71.2V and 68.3V respectively. 3. As the input frequency got farther from the resonance frequency the amplitude of the

oscil-lations of the input voltage decreased for each value of the capacitance used.

4. Expectedly, the higher the value of the capacitance Cf was, the less the amplitude of the

oscillations of the input voltage. This confirms the thought that increasing this capacitance would suppress the input voltage oscillations. Unfortunately, we could not decide a certain value for such a capacitance since we did not have concrete measurements from the real converter and we did not have a clear definition of the word ’suppress’, i.e. it was hard to determine a threshold value of the amplitude of the input voltage oscillations Av, ˜x2(V ) for

which the oscillations could be considered suppressed.

5. The higher the value of the capacitance Cf was, the closer the amplitudes of the oscillations

of the output voltage Av,L obtained from the simulation of the linearized Hamiltonian

sys-tem to Av,T which represented also the amplitudes of the oscillations of the output voltage

obtained from the simulation of the transfer function H1(s). This observation can be noticed

clearly if we compare the values of Av,Lin table (6) specially when Cf = 12.7 × 10−4with

those of Av,T in table (2). Actually, this result was very relieving, because it proved again

that the two simulations presented previously for the linearized Hamiltonian system and the transfer function H1(s) are equivalent. This can be understood from the fact that increasing

the capacitance Cf would smoothen the signal of the input voltage or suppress its

(40)

case in the model suggested in [5] since the author did not consider Ls neither Cf and he

assumed a DC input voltage.

In conclusion, we showed that a possible remedy of the problem of the input voltage oscilla-tions would be increasing the capacitance Cf. However, this solution is expensive and impractical

because we know that increasing the capacitance that much requires too much space and cost. Therefore, we try in the next section to investigate another solution for this problem.

7

Augmented System

An alternative way to suppress the fast oscillations in the input voltage was suggested in [1]. An augmented system was suggested, because it is believed that by finding a suitable control law the fast oscillations in the input voltage can be suppressed efficiently without affecting the stability of the output voltage. In this section we present this augmented system and show its simulation after finding that control law. In addition to that we try to find the suitable parameters which guarantee a suitable control law that suppresses the fast oscillations in the input voltage.

7.1 The Augmented System and Control Law

A new system was proposed in [1] by augmenting the linearized Hamiltonian system by adding a target output function called yauxgiven in the Laplace transform by (see [1]):

Yaux(s) = Tauxs 1 + Tauxs αfU˜f(s) + 1 1 + Tauxs αoU˜o(s) (44)

where, uf is the voltage across the capacitor Cf in the circuit shown in fig.1 which was called

uC2 in equation(1), and uo is the output voltage which has been called vothrough this report. The

tilde-sign, just as in section.5, denotes the difference between the signal and its DC-value. Finally, αf and αoare strictly positive constants with the limitation αo+ αf = 1 to be determined later.

This target output function yaux represents a combination of the two main targets of this

con-trol strategy: the stability of the output voltage and the ripples in the input voltage. In addition, this target output is proposed to bring these two components to zero so it has to be decaying with time. Finally, because it is believed that in practice one is interested in suppressing the fast ripples (high frequency) in the input voltage, the input voltage uf should dominate at high frequencies.

That is why the term with uf is multiplied by s in the above equation. Taking the inverse Laplace

transform we get(see [1]): dyaux dt = − 1 Taux yaux+ αfCf du˜f dt + αo Taux ˜ uo (45)

Thus, without going through the mathematical details, the augmented system would be (see [1]: ˙˜xaug= Faugx˜aug+ Baug,dd˜+ Baug,uu˜ (46)

(41)

and Faug=                 −1 C1(R4+R5) 0 R5 L1(R4+R5) 0 0 0 0 −DL 1 1 L1 0 −R5 C1(R4+R5) D C2 −R4R5 L1(R4+R5) 0 0 0 −1C 2 0 0 0 αoR5 C1(R4+R5)Taux 0 −αfD L1 + R4R5 L1(R4+R5) αf L2 −1 Taux                 (48) furthermore, Baug,d=                0 −xaD3 L1 xaD2 C2 0 −αfxaD3 L1                , Baug,u=               0 0 0 1 0               (49)

To find the control law LQR theory was used in which one tries to minimize a quadratic cost func-tion by the usual Riccati equafunc-tion. The cost funcfunc-tion for our model can be defined by (see [1]:

J( ˜d) =

Z

0

( ˜xTl Mx−1x˜l+ qyyy2aux+ ρ ˜d2)dt (50)

where, ρ and qyyare parameters to be found later. It was proved in [1] that when ˜u= 0 (as in our

case here) the solution which could minimize the cost function above is (see [1]: ˜

d= −Laugxaug= −Laug

 ˜ xl yaux  (51)

and, Laugis the control law we are searching for, and it can be found by (see [1]:

Laug= ρ−1BTaug,dP¯ (52)

and ¯Pis given by (see [1]):

¯ P= lim

T→∞P(t, T ) (53)

furthermore, P(t, T ) is a symmetric matrix which satisfies (see [1]): 

− ˙P= PFaug+ FaugT P− PBaug,dR−1BTaug,dP+ Q

P(T, T ) = 0 (54)

(42)

To find the control law in equation(52), we had to find ¯P. First of all, we assumed that: ˙¯

P= 0

because according to equation(53), ¯Pis the limit of P(t, T ) when T approaches ∞, and in infin-ity the function P(t, T ) reaches a constant value, this assumption was motivated by the argument provided by T. Glad and L. Ljung in their book [19]. By this assumption equation(54) could be rewritten as:

0 = ¯PFaug+ FaugT P¯− ¯PBaug,dR−1BTaug,dP¯+ Q (56)

The last equation represents the usual Riccati equation in matrix form, which could be solved numerically using MATLAB for the matrix ¯P. Then the matrix Q given by equation(55) was sim-plified using equation(7) to get:

Q=        1 C1 0 0 0 0 0 C1 2 0 0 0 0 0 L1 1 0 0 0 0 0 L1 2 0 0 0 0 0 q2yy        (57)

Finally, we assumed that the positive definite matrix R = (1) the identity matrix. Now, with the matrices Faugand Baug,d as in equations (48) and (49) respectively, all the ingredients of the recipe

were available and ready to find the control law Laug, all we needed to do was to write a simple

M-file as the following: ControlLaw: %Control_Law C1=47e-6; C2=12.7e-6; L1=344e-6; L2=500e-6; R4=50e-3; R5=2; D=0.5; alpha_o=0.5; alpha_f=1-alpha_o; x_ad2=0.0044; x_ad3=0.0301; qyy=10; T_aux=0.1; rho=40; F_aug=[-1/(C1*(R4+R5)) 0 R5/(L1*(R4+R5)) 0 0; 0 0 -D/L1 1/L2 0; -R5/(C1*(R4+R5)) D/C2 -R4*R5/(L1*(R4+R5)) 0 0; 0 -1/C2 0 0 0;

alpha_o*R5/(C1*(R4+R5)*T_aux) 0 -alpha_f*D/L1+R4*R5/(L1*(R4+R5)) alpha_f/L2 -1/T_aux]; B_aug=[0; -x_ad3/L1; x_ad2/C2; 0; -alpha_f*x_ad3/L1];

Q=([1/C1 0 0 0 0; 0 1/C2 0 0 0; 0 0 1/L1 0 0; 0 0 0 1/L2 0; 0 0 0 0 qyy^2]); ([P_bar,E,K])=care(F_aug,B_aug,Q);

References

Related documents

Utöver de mer ekonomiska fördelarna för det civila samhällets organisationer av projekt som Allmänna arvsfonden finansierar ser vi alltså i de utvärderingar vi analyserat

För att kunna förfina modellen bör även mätningar från andra ställen i systemet användas för att på så sätt kunna kalibrera modellen på flera ställen, inte bara i

hemundervisning av religiösa skäl bidrar till bristande socialisation och kunskap, snarare än att hemundervisning är socialisationslovande och bidrar med goda akademiska

Any spectral clustering algorithm that takes an affinity matrix and a number of clusters as input (i.e. it implements the CLUSTER function) could be used without major modifications

Men bara för att alla läser den dramatiska texten utifrån ett regissörperspektiv betyder det såklart inte att alla kommer tolka texten likadant, utan teaterpedagogen har ett

Here we find the load capacitance value by substituting the resonant point value obtained by plotting the frequency response of transfer function of a simulink modeled

On the figure above, the left is the simulation results in Modelica, the right is the results in Matlab. After comparing the simulation results of the output voltage from two