You are on page 1of 6

MODELING AND SIMULATION OF A SWITCHED MODE POWER SUPPLY USING SIMULINK

Narayanaswamy. P.R. Iyer Faculty of Engineering University of Technology Sydney Box 123; Level 24 Broadway; Sydney NSW-2007, Australia. niyer@eng.uts.edu.au Dr. Venkat Ramaswamy Senior Lecturer Faculty of Engineering University of Technology Sydney Box 123; Level 24 Broadway; Sydney NSW-2007, Australia. venkat@eng.uts.edu.au

ABSTRACT
This manuscript describes the SIMULINK model of a Buck Converter using the switching function concept. The principle developed is used to model a Switched Mode Power Supply using Buck Converter. In order to understand the use of PI controller in minimising the output voltage oscillation cycles and its magnitude, the model is provided with a manual switch and PI controller. Using the manual switch provided, a student can either include the PI controller or bypass it. The model of a time varying DC voltage source is provided as the input to simulate the effect of variation of the input voltage from its normal value. Thus the student can visually observe the effect of variation of input voltage on the output, both by including and excluding the PI controller in the same model.

the behaviour of these circuits by using various blocks in the Simulink block set. The blocks can be suitably selected and defined to represent the mathematical equations that define the system being simulated. This is an added feature of software SIMULINK. The systematic development of an educational model for SMPS using Buck Converter, suitable for use in a laboratory class room is presented in this paper. Section 2 describes the development of a SIMULINK model for a Buck converter in CCM, using the switching function concept [1-3]. In section 3, the general block diagram of the educational model of the SMPS using Buck converter is presented. Section 4 describes the actual SIMULINK implementation of this SMPS using Buck converter. Simulation results of SMPS are presented in Section 5.

1.

INTRODUCTION

2.

BUCK CONVERTER MODEL

Computer simulation plays a vital role in the design and analysis of power electronic converters and their controllers. Designing Power electronic systems without computer simulation is extremely laborious, time consuming, error-prone and expensive [1-4]. In the industry, computer simulation of power electronic converters is carried out to shorten the overall design process [5-7]. This necessitates the introduction power electronic converter modelling and simulation in the senior level undergraduate degree course in addition to teaching of their theory and design [6, 8]. There are two types of simulation packages available. One is the electrical and electronic static circuit simulation package like PSPICE, MICROCAP8, PSIM and SIMPLORER [9-12]. The other is the dynamic circuit simulation package like the MATLAB/SIMULINK [13]. PSIM and SIMPLORER are also used for simulation of converter fed electric drives with fixed mechanical load. SIMULINK is used for simulation of power electronic converter fed electric drives with fixed or time varying loads. In addition to simulating the Power electronic circuits using components drawn from SimPowerSystems Block set, it is possible to simulate

The Buck converter circuit is shown in Fig.1 [1, 4, 5, 1417]. Assume that the switch S is turned ON and OFF by a switching pulse whose period is T and duty cycle is D. All components in Fig.1 are assumed to be ideal. The

Analysis of this converter can be found in literature references [5, 14 -17]. The relevant modelling equations of Buck converter are given below:
d i L 1 d t =

(
=

V S

L 1

V O

)
.. .

d i L 1 d t

(- V

for 0 <= t <= D.T (1)


O

...

L 1

for D.T <= t <= T (2)

Now for the switch S, switching function SF is defined as follows:


SF = 1 = 0 fo r fo r 0 t D .T t T ...(3 )

D .T

Using equation 3 in equations 1 and 2, we have the following:


d i L 1 d t

(S

VS L 1

- V O

....( 4 )

the Buck converter SMPS is shown in Fig.3. The output voltage Vo is attenuated using potential divider network, whose output VPOT is subtracted from VREF using error amplifier. Selector switch SS1 either includes or bypasses the PI controller. The output from SS1 is applied to a comparator where it is compared with the output Vc of a triangle carrier generator. The resulting PWM output of comparator is used to turn ON and OFF switch S in the Buck converter. The duty cycle of the comparator output pulse adjusts to a value to maintain Vo close to the desired normal value.

VO

(R

iL 1 * R L L .C F .s + 1

4.

SIMULINK MODEL

(5 )

To test the performance of the Buck converter SMPS model, the following values were used. Normal Input Voltage Vs = 15 Volts. Normal Output Voltage Vo = 9 Volts. Variation of Input voltage = +12 Volts to +18 Volts. Load Resistance RL = 10 Ohms. Inductance L1 = 300e-6 Henries . Filter Capacitance CF = 200e-6 Farads. Switching Frequency Fsw = 100 kHz. PI Controller Kp = 0.1 and Ki = 6. By combining Fig.2 and 3, the SIMULINK model shown in Fig.4 is obtained. Referring to Fig.4, the gain1 block is the potential divider and provides VPOT output. Constant block VREF provides the reference voltage. Input voltage Vs is modelled using look-up table to simulate the effect of variation of the input voltage from the normal value. The 100 kHz square pulse generator with a peak of 20 volts and duty cycle 0.5, along with Fcn2 block generating function (u(1) 10), Integrator, gain2 block with a gain multiplier of 1e5 and Fcn3 block generating function 1.1*(u(1) 2.5), generates the 100 kHz triangular carrier wave. The SS1 output either from VERR or through PI controller is compared with the output of the triangle carrier generator in a relational operator also called comparator block. The comparator output is logic 1 if VERR is greater than or equal to VTRI, else the output is logic 0. The resulting PWM output of the comparator block is the Switching Function SF. The Convert block is used to convert Boolean data to unsigned integer data. The MUX with inputs SF, Vs and Vo, the Fcn1 block, Integrator and Transfer Fcn block is the Buck converter model which is already explained in section 2.

The SIMULINK model of Fig.1, based on equations 4 and 5, is given in Fig.2. In fig.2, due to the instantaneous switching action caused by SF, the initial

inductor current in L1 is automatically taken care of. The pulse generator block in SIMULINK generates SF defined in equation 3. The input voltage Vs uses the constant block in Sources block set. The MUX with inputs SF, Vs, Vo and the Fcn1 block solves equation 4. The output of Fcn1 block is integrated to obtain iL1 during the ON and OFF periods of the switch. The inductor current iL1 multiplied by the transfer function represented by Transfer Fcn block generates load voltage Vo. Fig.2 is valid as long as iL1 is continuous.

3. BUCK CONVERTER MODE POWER SUPPLY

SWITCHED

The general block diagram of the educational model of

5.

SIMULATION RESULTS

The simulation of the Buck converter SMPS was carried out using SIMULINK6 [13]. The ode23tb( stiff/TRBDF2 ) with a relative tolerance of 1e-3 was used. The simulation results of Vs and Vo of SMPS bypassing and including the PI controller are shown in fig.5(A), (B), ( C) and in fig.6(A), (B), ( C ) respectively. By double clicking the manual switch icon in Fig.4, the students can either bypass or include the PI controller and can visually observe the variation of output voltage Vo, as the input voltage Vs varies with time.

INPUT AND OUTPUT VOLTAGE WITHOUT PI CONTROLLER

20

15
input and output voltage

10

5
Y-AXIS: VOLTS Fig.5(A)

blue - input voltage green - output voltage 0.04


time in seconds
10 T r ia n g le c a r r ie r a n d e r r o r v o lt a g e blue - triangle carrier green - error voltage

0.02

0.06

0.08

0.1

TRIANGULAR CARRIER, ERROR VOLTAGE AND SWITCH FUNCTION WITHOUT PI CONTROLLER 5 T ria n g u la r C a rrie r, E rro r V o lt a g e a n d S w it c h F u n c t io n 4 3 2 1 0 -1 -2 -3 -4

TRIANGULAR CARRIER AND ERROR VOLTAGE WITHOUT PI CONTROLLER

Fig.5(B)

Fig.5(C)
5

-5 0.0799

0.08 time in seconds

0.0801

-5

6.

DISCUSSION OF RESULTS

Examination of the simulation results in fig.5(A) and Fig..6(A) indicates the following points: Without PI controller the number of initial switching cycles is as high as 11 for the first 0.01 seconds. With PI controller, the number of initial switching cycles is reduced from 11 to 7 for the first 0.01 seconds.

0.04 0.06 0.08 0.1 time in seconds The peak to peak of the initial switching cycle is reduced by around 2.4 volts with PI controller as compared to without the PI controller.

0.02

The duty cycle of SF adjusts to a suitable value to maintain the output voltage Vo close to 9 Volts. The change in output voltage for a given change in input voltage or regulation of the SMPS is

INPUT AND OUTPUT VOLTAGE WITH PI CONTROLLER


20

15
input and output voltage

10

5
Fig.6(A)

Y-AXIS: VOLTS

blue - input voltage green - output voltage 0.04


time in seconds
5 4

0.02

0.06

0.08

0.1

TRIANGULAR CARRIER, ERROR VOLTAGE AND SWITCH FUNCTION WITH PI CONTROLLER 5 T ria n g u la r C a rrie r, E rro r V o lt a g e a n d S w it c h F u n c t io n 4 3 2 1 0 -1 -2 -3 -4

TRIANGULAR CARRIER AND ERROR VOLTAGE WITH PI CONTROLLER

Fig.6(B)
T r ia n g le c a r r ie r a n d e r r o r v o lta g e

Fig.6(C)

blue - triangle carrier green - error voltage

3 2 1 0

-1 -2 -3 -4

-5 0.0799

0.08 time in seconds

0.0801

-5

0.02

0.04

0.06

0.08

0.1

more with PI controller as compared to without the PI controller. The normal output voltage is close to 9 volts for a normal input voltage of 15 volts in both cases.

7.

CONCLUSIONS

time in seconds An educational model of the Buck converter SMPS suitable for class room application is presented. Using this model, students can visually observe on the scope screen, the variation of output voltage as input voltage varies with time, the initial number of oscillation cycles and its peak to peak magnitude both by bypassing and including the PI controller, which by

hardware experiment is difficult to understand. Thus the students will have a visual effect on the advantage of SMPS over conventional power supply. In this way they will also be able to appreciate the use of PI controller in SMPS. Also note that further reduction in the number of initial oscillation cycles and its peak magnitude is possible with PI controller, but will considerably reduce the normal output voltage for a normal input voltage of 15 volts. Thus user requirement limits the optimum values of PI controller parameters. Simulation results reveal that PI controller can be used in SMPS where input voltage variation is within a very narrow range of around 7 %. If a similar SMPS is designed for a hardware project, students can select the optimum values for the R, L, C components above their critical values given by formula and PI controller parameters by simulation of the above model. Thus they can also understand the necessity of power electronic simulation in an industrial environment with regard to the time in shortening the overall design process as compared to assembling and testing the components in the laboratory and deciding on the optimum values for components and controller parameters.

Applications and Design, John Wiley and Sons; 1995; Ch.4, pp. 61-76. [6] Ned Mohan, W.P. Robbins and T.M. Undeland, R. Nilssen and Olive Mo: Simulation of Power Electronic and Motion Control Systems; Proceedings of the IEEE, Vol.82, No.8, August 1994, pp. 1287 1292 Bimal K. Bose: Power Electronics An Emerging Technology, IEEE Transactions on Industrial electronics, Vol.36, No.3, August 1989, pp. 410 411. D.W. Hart: Circuit Simulation as an Aid in Teaching the Principles of Power Electronics, IEEE Transactions on Education, Vol.36, No.1, February 1993, pp. 10-16. www.orcad.com: ORCAD 10 demo version www.spectrum-soft.com: MICROCAP8. www.powersimtech.com: PSIM www.ansoft.com: SIMPLORER www.mathworks.com: MATLAB/SIMULINK Release 14 Notes, 2004. D.W. Hart: Introduction to Power Electronics, Prentice Hall Inc., 1997; pp. 187 196. M.H. Rashid: Power Electronics: Circuits, devices and Applications, Pearson education Inc., Pearson Prentice Hall, 2004, pp. 186 190. Issa Battarseh: Power Electronic Circuits, John Wiley and Sons Inc., 2004, pp. 136 147. Venkat Ramaswamy: Power Electronics, Lecture Notes, Faculty of Engineering, University of Technology Sydney, 2003, pp. 8-57.

. [7]

[8]

[9]

[10]

8.
[1]

REFERENCES
[11] V.F. Pires and J.F.A. Silva: Teaching Nonlinear Modelling, Simulation and Control of Electronic Power Converters Using MATLAB/SIMULINK, IEEE Transactions on Education; Vol.45, No.3, August 2002; pp. 253 256. B. Baha: Modelling of resonant switchedmode converters using SIMULINK, IEE Proceedings, Electric Power Applications, Vol.145, No.3, May 1998, pp. 159 -163. B. Baha: Simulation of Switched-Mode Power Electronic Circuits, IEE International Conference on Simulation, 1998, pp. 209 214 [16] A.N. Melendez, J.D. Gandoy, C.M. Penalver and A. Lago: A New Complete Non-Linear Simulation Model of A Buck DC-DC Converter, IEEE-ISIE99, 1999, pp. 257 261. Ned Mohan, T.M. Undeland and W.P. Robbins: Power Electronics: Converters, [12] [13]

[2]

[14]

[15] [3]

. [4]

[17]

[5]

You might also like