1 2022 International Electrical Engineering Congress (iEECON) | 978-1-6654-0206-4/22/$31.00 ©2022 IEEE | DOI: 10.1109/iEECON53204.2022.9741689 Application of port-Hamiltonian Approach in Controller Design for Buck Boost Converter Walarcheth Thongrailuck Electrical and Computer Engineering,Faculty of Engineering King Mongkut’s University of Technology North Bangkok Bangkok, Thailand s6101011811519@email.kmutnb.ac.th Abstract—Controlling output voltage of the DC-DC BuckBoost converter has been a challenging topic for many years, since its averaged dynamics is a non-minimum phase system with highly load variation. Several methods avoid this difficulty by controlling the voltage via the inductor current. This paper presents a nonlinear energy-based controller design approach, which can directly control the output voltage without internal current loop. Due to damping assignment technique, the damping of the closed-loop system can be determined, and the problem with load variation is solved. To verify the performance of the proposed approach, the controller is test with a simulation and with existing converter. The result confirms the achievement of the proposed controller. Keywords—Port Hamiltonian, Buck-Boost DC/DC Converter, Energy Shaping (ES), Current Controller I. INTRODUCTION Controlling the output voltage of DC-DC Buck-Boost converter is a challenging topic. Firstly, the converter is a nonlinear variable structure system and the average model of the converter has non-minimum zero [1]. The highly load variation affects system stability, and it is, therefore, troublesome to control output voltage directly [2]. By using an inner loop or current controller, the problem with nonminimum phase system can be avoided, and the output voltage can be controlled through the regulation of inductor current [3]. However, the load variation must be concerned, because many study show the load variation has considerable effect on the performance of the closed-loop system [3], [4]. The portHamiltonian system theory is developed on the basis of portbased modeling and Hamiltonian dynamics. This combination yields an efficient approach for modeling and analysis of multi-physics system, which uses energy for communication among the components. Besides, based on port-Hamiltonian system concept, many energy-based methods in controller design e.g., damping assignment-passivity based control or energy shaping are developed [8]. The advantage of energybased approach is the ability to manage the variable structure system in a tidy manner [6], [9]. In this paper, energy balancing method and damping assignment are utilized to solve the non-minimum phase and load variation issue. The developed controller is tested by simulation and experiments. The result certifies the success of the proposed method. II. PORT-HAMILTONIAN CONTROLLER DESIGN APPROACH A. Port Hamiltonian System According to the concept of port-Hamiltonian, a physical system has three elements: (1) energy-storage, (2) energydissipative and (3) energy-routing, as shown in Fig.1. All energy-storage components in the system are merged as a Witthawas Pongyart Electrical and Computer Engineering,Faculty of Engineering King Mongkut’s University of Technology North Bangkok Bangkok,Thailand witthawas.p@eng.kmutnb.ac.th single unit indicated by S, and in the same manner, all energydissipative components are lumped together as a single unit indicated by R. The energy exchange among the components occurs via a pair of equally dimensioned vectors of flow and effort variables, shown by (f,e) in Fig. 1. Each pair of (f,e) vectors establishes a port joining to the system, and the inner product of flow and effort is the power flowing through the port. The internal ports (fS,eS) and (fR,eR) connect the energystorage element and the energy-dissipative element to the system respectively. The external port (fP,eP) connects the system to exterior components for instance controller, voltage source including disturbance. Finally, the coupling of all the energy-routing is represented as a single energy-routing structure designated by D, to represent the geometric notion of Dirac structure which determine energy flow-path of the system [6]. In addition, the Dirac structure provides a power continuous interconnection among the ports [5]. Assuming H(x) is total energy in the system and x is the vector of state variables, the dynamic of energy in the system can be expressed by the port-Hamiltonian concept as in (1). The flow and effort of the system are shown by the vector x& and ∂H ( x) / ∂x respectively. The interconnection matrix J(u) describes the interaction of the stored energy and the damping matrix R represents the energy dissipation of the system. Both matrixes, J(u) and R, are defined in (2). The input matrix g(u) defines the connection to external source E. The variable u play an important role in (1), since it controls the energy flow in and into the system via the matrix J(u) and g(u) respectively. The model in (1) is chosen for this research, since it is suitable for variable structure system [6], [9]. S (storage) eR eS D fS fR eP R (dissipation) fP Fig. 1 Structure of port-Hamiltonian System with Dissipation =( ( )− ) ℎ ( ) + ( ) ( ) = − ( ), ≥0 (1) (2) The 2022 International Electrical Engineering Congress (iEECON2022), March 9 - 11, 2022, Khon Kaen, THAILAND 978-1-6654-0206-4/22/$31.00 ©2022 IEEE Authorized licensed use limited to: King Mongkut's University of Technology North Bangkok. Downloaded on September 08,2022 at 09:56:15 UTC from IEEE Xplore. Restrictions apply. 2 B. Buck-Boost Converter Model The circuit of DC-DC Buck-Boost converter is shown in Fig.2. The inductor and capacitor serve as energy storage elements and the variable resistor r is the energy dissipative element of the system. The energy interaction in the system and with the external source E is controlled by the transistor. Based on port-Hamiltonian principle, the mathematical model of the converter can be written in (3). The state variable and total energy, or Hamiltonian function are defined in (4) and (5) respectively. The interconnection matrix J(u) is shown in (6) and the damping matrix R is in (7). According to (6) the converter is a variable structure system. Besides the load variation has direct effect on transient response of the system. TR E ir(t) D vC(t) + L iL(t) C vr(t) + iC(t) ℎ ( )= ( ) r =[ # % $ ( ) $ & ( )= )*+ + 0 1− 0 + (3) !] (4) # ' $ ( ) , $ ( ( ( )− 0 .( / (6) (7) III. ENERGY BALANCING CONTROLLER DESIGN ℎ . )*+ = −0 .( . )= = .( ) .( ( )+ + 1 / . ) /( ≥0 0 .( ) =8 ), ) 1 1 . 0 / 0 / 2( ) ≜ − 1 2 2( ) = < # = = > 2$ 0 #:,∴ .( ( ) ) + ( ) 4( ) 15 = . 9 # 6 ∗ / 0 (12) (13) =0 (14) 0 0 (15) / # @ = + − $ ? / $ ? 2# ( ) $ + − A (16) (17) The control law in (18) is obtained by solving (16). The parameter α in (19) is used for tuning purpose and the constant C1 in (21) is determined at the equilibrium point. The completed control law is presented in (22), and it is to be noted that the parameter u* in (23) depends on the command v*. Hence the developed controller has adaptive feedforward gain. The structure of the control system is shown in Fig.3. + + $ = B $ B =1− = ?# = ∗ (8) (9) (10) − 2$ ( ) To avoid the effect of load variation and improve the system behavior the desired closed-loop system is determined in (8), where the closed loop system energy Hd(x) in (9), and the closed loop damping matrix Rd is defined and (10). The controller shapes the closed loop system energy Hd(x) by adding additional energy Ha(x) to the H(x) as in (8). Besides, the controller adjusts the system damping matrix by adding Ra to the existing matrix R, and the effect of load variation is reduced. Actually the energy-based controller design approach can rearrange the interconnection also, but in this paper the matrix J(u) is left untouched. Since the energy function Hd(x) is a positive definite function, and its derivative is negative as in (11), the stability of the closed-loop system is ensured. .) )= ℎ (5) − 0 0 0 1=, 0 =( ( )− . )2( By substituting the damping matrix Ra and Rd are in (12) and (16) is derived. A necessary and sufficient condition for the K(x) in (13) to be a gradient function is given in (17) [7]. Since the inductor current x1 is not fixed, the control law u depends on the x2 only, the equation (16) becomes ordinary differential equation in (18). Fig.2 Circuit of DC-DC Buck-Boost converter =( ( )− ) (12) is solvable for Ha(x) with the constraint as shown in (14) that the resulting Hd(x) has minimum at x*. To avoid the load variation, the injected damping matrix Ra is defined in (15). vC* = + = H∗ ( $) / @ E $ ?# ∗ (18) ? (19) (20) ∗ ( $∗ )E F ∗G $ $ (21) E , where H ∗ = Controller 1 ? u(t) (22) (23) ∗ $ Plant vC(t) (11) To achieve the desired closed loop system the control law u must be determined. The energy-shaping and damping assignment can be obtained, when the matching equation in Fig.3 Structure of the control system The 2022 International Electrical Engineering Congress (iEECON2022), March 9 - 11, 2022, Khon Kaen, THAILAND Authorized licensed use limited to: King Mongkut's University of Technology North Bangkok. Downloaded on September 08,2022 at 09:56:15 UTC from IEEE Xplore. Restrictions apply. 3 IV. SIMULATION AND EXPERIMENTAL RESULT To verify the performance of the developed controller, the controller is tested with MATLAB simulation. Then the controller is tested with the existing DC-DC Buck-Boost converter and converter parameters are s in Table I. Those parameters are used in the simulation as well. The controller is tuned by letting α = 0.1 in every test. The closed-loop system becomes faster, when this parameter is reduced. TABLE I. dropping of load resistance, the inductor current increases to a new level. Even under load fluctuation the system is still stable and has pretty good transient behavior. SPECIFICATIONS OF THE CONVERETER Component Value Inductor : L 25 mH Capacitor : ? Nominal value of Load Resistance : r 30 Ω Input Voltage 15 V Switching Frequency : Hz 20 kHz Sampling Period : NO Fig.5 Response for step input 10-20 V 47 µF 22 20 50PQ 18 16 14 0.05 A. Simulation Result To observe the tracking performance of the controller, a step command v* 0-10 V is applied. The result is shown in Fig. 4. Obviously, the capacitor voltage vC(t) tracks the command and reaches to steady state with in 0.004 second. The response has some overshoot but no steady state error. Also, the inductor current iL(t) shows the same behavior. 0.06 0.07 0.08 0.09 0.1 0.11 0.09 0.1 0.11 Time in ms 7 6 5 4 0.05 0.06 0.07 0.08 Time in ms Fig.4 Response for step input 0-10 V Then after reaching steady state, another test is performed by stepping the input from 10 to 20 V, and the result is shown in Fig. 5. The capacitor voltage vC(t) reaches to equilibrium with some overshoot, but the transient period is shorter than the one in the previous test, since it takes only 0.6 millisecond. There is no steady state error in the response, but a small undershoot, due to non-minimum phase zero, can be seen. The inductor current shows the same behavior but no undershoot. Finally, the disturbance rejection is investigated. The load resistance is reduced by 20 %, and the output voltage and inductor current are shown in Fig. 6. The voltage vC(t) drops and recovers in two millisecond, and iL(t) increases to maintain the output voltage. Finally, to investigate system performance under highly load variation, the load resistance is decreased by 50 %. The output voltage and inductor current are shown in Fig. 7. The output voltage drops more and returns to the set point value within two millisecond. Due to the iL (t) [A] vC (t) [V] Fig.6 Load resistance reduced by 20 % Fig.7 Load resistance reduced by 50 % B. Experimental Result The developed controller is realized on a microcontroller and tested with the existing converter in the laboratory. The process is similar to the test in previous section. The step response of a step command from 0-10 V is shown in Fig. 8. The blue line shows the inductor current and the red one is the capacitor voltage. The result has similar characteristic as the simulation result in Fig. 4 does. The vC(t) tracks the command with some overshoot and requires about 0.004 second to reach the steady state. There is no steady state error in the output, and the inductor current shows the same behavior. The 2022 International Electrical Engineering Congress (iEECON2022), March 9 - 11, 2022, Khon Kaen, THAILAND Authorized licensed use limited to: King Mongkut's University of Technology North Bangkok. Downloaded on September 08,2022 at 09:56:15 UTC from IEEE Xplore. Restrictions apply. 4 v C (t) [V] 30 20 10 0 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.3 0.35 0.4 0.45 0.5 Time in ms 6 iL (t) [A] 4 2 0 0 0.05 0.1 0.15 0.2 0.25 Time in ms v C (t) [V] Fig.8 Experiment: response for step command 0-10 V voltage vC(t), the red line, reaches to equilibrium with very small overshoot, and the transient period is much less than the one in the previous test, since it is about 0.6 millisecond. There is no steady state error, but a tiny under shoot, due to nonminimum zero, can be clearly observed. Since the output is increased, the inductor current raises. The behavior of both signal is similar to the simulation result in Fig. 5. The load variation is occurred by connecting a resistor in parallel to the load to reduce the load resistance by 20%. The result is shown in Fig. 10. Obviously, the capacitor drops and recovers within 0.2 millisecond and, to maintain the output voltage, the current iL(t) raises. To observe system performance under highly load variation, the load resistance is reduced by 50%. The output voltage and inductor current are shown in Fig. 11. The vC(t), the red line, drops and recovers in 0.25 millisecond. Due to the dropping of load resistance, iL(t) rearises rapidly to almost six Amps to maintain the output constant. iL (t) [A] V. CONCLUSTION v C (t) [V] Fig.9 Experiment: response for step command 10-20 V An output feedback controller for Buck-Boost DC-to-DC converter is presented. The proposed controller is robust to load fluctuation, since the closed-loop damping is free from the load resistance. Besides, the controller has very good disturbance rejection behavior. The feedforward gain u* adapts to new operating point and supports the feedback controller in command tracking. The system can track the command rapidly. With special inductor from the factory. Simulation and experimental results confirm the good performance in tracking the command and disturbance rejection. It is to be noted that there is no integrator in the controller but the steady state error is zero. REFERENCES [1] iL (t) [A] [2] [3] Fig.10 Experiment: Load resistance reduced by 20 % [4] vC (t) [V] 30 20 [5] 10 0 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 [6] Time in ms 6 iL (t) [A] 4 [7] 2 0 0 0.05 0.1 0.15 0.2 0.25 0.3 0.35 0.4 0.45 0.5 Time in ms [8] Fig.11 Experiment: Load resistance reduced by 50 % [9] Then another test is performed by stepping the command from 10 to 20 V, and the result is in Fig. 9. The capacitor Dingxin Shuai, Yunxiang Xie and Xiaogang Wang, "The research of input-output linearization and stabilization analysis of internal dynamics on the CCM Boost converter," 2008 International Conference on Electrical Machines and Systems, 2008, pp. 1860-1864. H. M. Mahery, S. Torabzad, M. Sabahi and E. Babaei, "Modeling and stability analysis of buck-boost dc-dc converter based on Z-transform," 2012 IEEE 5th India International Conference on Power Electronics (IICPE), 2012, pp. 1-6. B. Johansson, "Analysis of DC-DC converters with current-mode control and resistive load when using load current measurements for control," 2002 IEEE 33rd Annual IEEE Power Electronics Specialists Conference. Proceedings, 2002, vol.1, pp. 165-172 H. M. Mahery, S. Torabzad, M. Sabahi and E. Babaei, "Modeling and stability analysis of buck-boost dc-dc converter based on Z-transform," 2012 IEEE 5th India International Conference on Power Electronics (IICPE), 2012, pp. 1-6. R. Carloni, L. C. Visser and S. Stramigioli, "Variable Stiffness Actuators: A Port-Based Power-Flow Analysis," in IEEE Transactions on Robotics, vol. 28, no. 1, pp. 1-11, Feb. 2012, S. Roengriang, W. Pongyart and P. Vanichchanunt, "Study of Three Phase VSC Models for Controller Design by Using Port-Controlled Hamiltonian," 2020 17th International Conference on Electrical Engineering/Electronics, Computer, Telecommunications and Information Technology (ECTI-CON), 2020, pp. 656-659. H. Rodriguez, R. Ortega and G. Escobar, "A robustly stable output feedback saturated controller for the Boost DC-to-DC converter," Proceedings of the 38th IEEE Conference on Decision and Control, 1999, vol.3, pp. 2100-2105. A. van der Schaft and D. Jeltsema, “Port-Hamiltonian Systems Theory: An Introductory Overview,” Foundations and Trends in Systems and Control, vol. 1, no. 2–3, 2014. G. Escobar, A. J. van der Schaft, R. Ortega, “A Hamiltonian viewpoint in the modeling of switching power converters,” AUTOMATICA vol. 35, pp.445–452, March 1999. The 2022 International Electrical Engineering Congress (iEECON2022), March 9 - 11, 2022, Khon Kaen, THAILAND Authorized licensed use limited to: King Mongkut's University of Technology North Bangkok. Downloaded on September 08,2022 at 09:56:15 UTC from IEEE Xplore. Restrictions apply.