Lecture Notes on Computer Listings | ECEN 5817, Study notes of Electrical and Electronics Engineering

Material Type: Notes; Professor: Erickson; Class: RESONANT TECH PWE ELEC; Subject: Electrical & Computer Engineering; University: University of Colorado - Boulder; Term: Unknown 1989;

Typology: Study notes

Pre 2010

Uploaded on 02/13/2009

koofers-user-g65
koofers-user-g65 🇺🇸

4.7

(3)

10 documents

1 / 6

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
1
APPENDIX 1
Computer Listings
A1.1. Series Resonant Converter M(Q,F)
The following routine correctly computes the voltage conversion ratio M as a function of Q
and F. It is assumed that the converter operates with linear resistive load R, and Q=R0 / R. The
algorithm and equations used are described in section 4.5.
function M(Q,F)
{computation of series resonant converter M, as a function of
load Q and frequency F}
define k,ksi,g,qgt,cgt,tgt,mr,k1
g=PI()/F {gamma}
k=INT(1/F)
{check for mode}
k1=INT(0.5+sqrt(0.25+Q*PI()/(2*F)))
if k1>k
{type k CCM}
ksi=k+(1+(-1)^k)/2 {subharmonic number}
qgt=Q*g/2 {intermediate variable}
cgt=(cos(g/2))^2 {intermediate variable}
tgt=(tan(g/2))^2 {intermediate variable}
{mr contains the result M}
if F=1/ksi
mr=F {tangent function may give unpredictable
results at resonance and subharmonics}
else mr=qgt/(ksi^4*tgt+qgt^2)*((-1)^(k+1)+SQRT(1+(ksi^2-
cgt)*(ksi^4*tgt+qgt^2)/(qgt^2*cgt)))
end if
else
{type k1 DCM}
if k1/2=INT(k1/2)
{even DCM}
mr=2*k1*F/(PI()*Q)
else {odd DCM}
mr=1/k1
end if
end if
return mr
end function
A1.2. Parallel Resonant Converter M(J,F)
The following routine computes the operating point of the parallel resonant converter. It
works in both the continuous conduction mode and the discontinuous conduction mode, provided
that F0.5. The CCM solution is a straightforward application of Eqs. (5-31) and (5-35). In the
case of the discontinuous conduction mode, Eqs. (5-45) must be solved iteratively. Doing so is
pf3
pf4
pf5

Partial preview of the text

Download Lecture Notes on Computer Listings | ECEN 5817 and more Study notes Electrical and Electronics Engineering in PDF only on Docsity!

A PPENDIX 1

Computer Listings

A1.1. Series Resonant Converter M(Q,F)

The following routine correctly computes the voltage conversion ratio M as a function of Q

and F. It is assumed that the converter operates with linear resistive load R, and Q=R 0 / R. The

algorithm and equations used are described in section 4.5.

function M(Q,F) {computation of series resonant converter M, as a function of load Q and frequency F} define k,ksi,g,qgt,cgt,tgt,mr,k g=PI()/F {gamma} k=INT(1/F) {check for mode} k1=INT(0.5+sqrt(0.25+QPI()/(2F))) if k1>k {type k CCM} ksi=k+(1+(-1)^k)/2 {subharmonic number} qgt=Qg/2 {intermediate variable} cgt=(cos(g/2))^2 {intermediate variable} tgt=(tan(g/2))^2 {intermediate variable} {mr contains the result M} if F=1/ksi mr=F {tangent function may give unpredictable results at resonance and subharmonics} else mr=qgt/(ksi^4tgt+qgt^2)((-1)^(k+1)+SQRT(1+(ksi^2- cgt)(ksi^4tgt+qgt^2)/(qgt^2cgt))) end if else {type k1 DCM} if k1/2=INT(k1/2) {even DCM} mr=2k1F/(PI()*Q) else {odd DCM} mr=1/k end if end if return mr end function

A1.2. Parallel Resonant Converter M(J,F)

The following routine computes the operating point of the parallel resonant converter. It

works in both the continuous conduction mode and the discontinuous conduction mode, provided

that F≥0.5. The CCM solution is a straightforward application of Eqs. (5-31) and (5-35). In the

case of the discontinuous conduction mode, Eqs. (5-45) must be solved iteratively. Doing so is

Principles of Resonant Power Conversion

not straightforward, and can become an exercise in numerical analysis methods. The routine

below first finds the solution for ξ = α+β. This is done by combining the third and fourth lines of

Eq. (5-45) to obtain

G f (ξ) = cos ξ + 0.5 (2J – γ) 2 + 0.5 ξ^2 + (2J – γ) ξ + (2J – γ) sin ξ + ξ sin ξ − 1

This equation is solved iteratively. Once ξ is known, the other angles (α,β, and δ) can be

evaluated directly, and then M can be found.

The routine first searches for the neighborhood of the root by simply evaluating G f at

regular intervals (note that ξ can take on values between 0 and γ), beginning at ξ = γ. Once G f

changes polarity, the routine uses Newton’s method to converge quickly to the root.

function M(J,F) {computation of parallel resonant converter M, as a function of load current J and frequency F} {equations are valid only for F>0.5} define phi, g, qgt, jcrit, mr, phicrit, ksi1, ksi2, ksi3, G1, G2, G3, convg, epsln, a, b, d, dc, ic, kc, Gc, dG1, jsc g=PI()/F {gamma} {check for mode}

if F<0.

return "invalid F" end if jcrit = Jcr(g) if j < jcrit {CCM} phi=Fphi(J,g) mr = (2/g)(phi-sin(phi)/cos(g/2)) else {DCVM} jsc=0.5g {test whether J exceeds the short-circuit current; exit if it does} if J>jsc mr="error: I>short ckt current" return mr exit function end if {find neighborhood of root where convergence is likely} dc=0. Gc= while Gc> kc=g Gc=Gf(kc,J,g) dc=dc0. ic=dcg while ((Gc>0) and (kc>0)) kc=kc-ic Gc=Gf(kc,J,g) end while end while ksi2=kc ksi1=kc+ic {iteration: Newton's method} convg=0.000001 {criterion to test convergence}

Principles of Resonant Power Conversion

mode and whether the converter operates with zero current or zero voltage switching at the given

operating point. These functions require that M, J, and γ all be specified; it is intended that M(J,F)

be used first to solve iteratively for the operating point, and then the results used in the routines

below. All functions operate correctly for both CCM and DCM. They use the relevant equations

of Chapter 5.

Boundary values M C0 and J L 0

function Mco(M,J,g) {evaluation of tank capacitor initial voltage Mco, given the steady state solution M,J, and gamma} define d,b,r,jcrit,phi jcrit=Jcr(g) if J>jcrit {DCM soln} d=J-(g/2)(M-1) b=g-d r=1-cos(b) else {CCM soln} phi=Fphi(J,g) r=-Jsin(phi)/cos(g*0.5) end if return r end function

function JLo(M,J,g) {evaluation of tank inductor initial current JLo, given the steady state solution M,J, and gamma} define d,b,r,jcrit,phi jcrit=Jcr(g) if J>jcrit {DCM soln} d=J-(g/2)(M-1) b=g-d r=J+sin(b) else {CCM soln} phi=Fphi(J,g) r=-(J^2-1)tan(g*0.5) end if return r end function

Peak stresses J LP and M C P

function JLpk(M,J,g) {evaluation of peak tank inductor current JLpk, given the steady state solution M,J, and gamma} define d,b,r,jcrit,phi,j1,jl jcrit=Jcr(g) if J>jcrit {DCM soln} d=J-(g/2)*(M-1)

Appendix 1. Computer Listings

b=g-d if (g-d)<pi()/ r=JLo(M,J,g) else r=J+ end if else {CCM soln} phi=Fphi(J,g) jl0=JLo(M,J,g) if ((Mco(M,J,g)<1) and (jl0>0)) r=jl else j1=-sin(phi)/cos(0.5*g) r=J+sqrt((j1-J)^2+1) end if end if return r end function

function MCpk(M,J,g) {evaluation of peak tank capacitor voltage MCpk, given the steady state solution M,J, and gamma} define d,b,r,jcrit,phi,mc0,jl0,j jcrit=Jcr(g) jl0=JLo(M,J,g) if J>jcrit {DCM soln} d=J-(g/2)(M-1) b=g-d if jl0>J mc0=Mco(M,J,g) r=sqrt((mc0+1)^2+(J-jl0)^2)- else r= end if else {CCM soln} phi=Fphi(J,g) if jl0>J mc0=Mco(M,J,g) r=sqrt((mc0+1)^2+(J-jl0)^2)- else j1=-sin(phi)/cos(0.5g) r=1+sqrt((j1-J)^2+1) end if end if return r end function

Operating mode

function ZCVS(M,J,g) {determination of whether the converter operates with zero current or zero voltage switching at the designated operating point} define r,jl jl0=JLo(M,J,g) if jl0< r="ZCS"