You are on page 1of 49

Modeling of electromechanical systems

Carles Batlle
II EURON/GEOPLEX Summer School on Modeling and Control of Complex Dynamical Systems Bertinoro, Italy, July 18-22 2005

Contents of this lecture


Basic ideas of electromechanical energy conversion from a network modeling point of view Port Hamiltonian formulation of electromechanical systems Very simple examples: lumped parameter only, no complex induction machines, no piezoelectric devices, . . . . . . but it can be done Variable structure systems: power converters A more complex example

Network description of systems


Energy-storing elements Impose constitutive relations between eorts and ows [ei ][f i ] = power f n+1 en+m Is power continuous
n X i=1

1 e1 f

e2 f 2 Network

en f n

en+1 Open ports

f n+m Can be connected to other systems or to dissipative elements

ei f i =

i=n+1

n+m X

ei f i

Example: Tellegens theorem


Circuit with b branches and n nodes i1 To each node we assign a voltage uj , j = 1, . . . , n u3 u1 To each branch we assign i2 3 i a current i , = 1, . . . , b, u2 and this gives an orientation to the branch ib un uj ul

For each branch we dene the voltage drop v , = 1, . . . , b: This is KVL!

v = u j u l

Mathematically, the circuit, with the orientation induced by the currents, is a digraph (directed graph) We can dene its n b 1 +1 Ai = 0 adjacency matrix A by if branch is incident on node i if branch is anti-incident on node i otherwise

Then, KCL states that


b X

Ai i = 0,

=1

i = 1, . . . , n

In fact, KVL can also be stated in terms of A: v =


n X i=1

Ai ui

The sum contains only two terms, because each branch connects only two nodes

Tellegens theorem. Let {v(1) (t1 )}=1,...,b be a set of branch voltages satisfying KVL at time t1 , and let {i (t2 )}=1,...,b be a set of currents satisfying (2) KCL at time t2 . Then
b X

=1

v(1) (t1 )i (t2 ) hv(1) (t1 ), i(2) (t2 )i = 0 (2) KVL

Proof: Pb v(1) (t1 )i (t2 ) (2)


n X i=1

=1

= !

=1

b X

n X i=1

Ai u(1)i (t1 ) i (t2 ) (2)


n X i=1

=1

b X

Ai i (t2 ) u(1)i (t1 ) (2)

0 u(1)i (t1 ) = 0

KCL

Notice that {v(1) (t1 )} and {i (t2 )} may correspond to dierent times (2) and they may even correspond to dierent elements for the branches of the circuit. The only invariant element is the topology of the circuit i.e. the adjacency matrix.

Corollary. Under the same conditions as for Tellegens theorem, r s d d v(1) (t1 ), s i(2) (t2 ) = 0 dtr dt2 1 for any r, s N.
In fact, even duality products between voltages and currents in dierent domains (time or frequency) can be taken and the result is still zero.

In terms of abstract network theory, a circuit can be represented as follows


Element in branch 2

2 v2 i

i1 v1
Element in branch 1

Network: KVL+KCL vb ib
Element in branch b

The kth branch element imposes a constitutive relation between vk and ik .

May be linear or nonlinear, algebraic or dierential, . . .

Energy storing elements


f1 Consider a system with m power ports Z tX m
t0 i=1

e1

e2 f2 em fm

Wf (t) Wf (t0 ) =

ei ( )f i ( )d

Assume the state of the system is given by x Rn , and that x = G(x) + g(x)e Internal dynamics Assume also that outputs can be computed from the state Dynamics due to the inputs f = g T (x)(x)

Wf (t) Wf (t0 ) = = Z
t

t t0

he( ), f ( )id = Z

Z
t t0

t t0

he( ), g T (x( ))(x( ))id

t0

hg(x( ))e( ), (x( ))id =

hx( ) G(x( )), (x( ))id

Assume the internal dynamics is G(x) = J(x)(x) with J T = J Wf (t) Wf (t0 ) = x x0 Z


t t0

hx( ), (x( ))i d

(z) dz
(x0 ,x)

To avoid violating energy conservation (First Principle of Thermodynamics) we cannot let this depend on the particular connecting x0 and x

2 1 x0

Suppose W (2 ) > W (1 ) x0 1 W (1 ) x 2 x0

W (2 )

We input W (1 ) and then obtain W (2 ) while the system returns to the same state

free generator of energy!


To avoid this (x)dx must be an exact form

(x) i (x) = , xi

i = 1, . . . , n

where (x) is an state space function

Wf (x) Wf (x0 ) = (x)

or, taking appropriate references,

Wf (x) =
i (x) = (x) , xi i = 1, . . . , n

(z)dz

(x)

j i (x) = (x), xj xi

i, j = 1, . . . , n

Maxwells reciprocity relations Wf (x) i (x) = xi


we are using an all-input power convention a sign is used in EE literature to compute the mech force done by the system

Electric capacitor
zero E constant E zero E F n = m = 2, g = I2 , G = 0 e1 = i (current), e2 = V (velocity) (x, q), 1 = F (x, q), 2 = v(x, q)

q varying x

+q

q v(x, q) = C(x, q)
nonlinear dielectric

v F = =q q x x

1 C(x, q)

q C(x, q) 2 (x, q) x C

F (x, q) =

q2 = 2 x

q 0

1 d C(x, ) Z q 2 2 1 1 d C(x, q) 2 x C(x, ) 0

in the linear case, C(x, q) = C(x) q F (x, q) = 2 x


2

1 C(x)

q 2 x

q C(x)

q v(x, q) 2 x

E(x, q) = q 2

electric eld seen by the + plate

Furthermore, going from (0, 0) to (x, q) rst with q = 0 and then to q with the nal x, one gets the energy

Wf (x, q) =

q 0

1 q2 d = C(x) 2 C(x)

Magnetic stationary system


i1 + v1 l1 N1 l2 N2 i2 + v2 1 2 = l1 + m1 + m2 = l2 + m2 + m1 1 2 = N1 1 , = N2 2 .

m1

m2

For linear magnetic systems l1 = l2 = N1 i1 N1 i1 Ll1 i1 , m1 = Lm1 i1 , Rl1 Rm N2 i2 N2 i2 Ll2 i2 , m2 = Lm2 i2 , Rl2 Rm

1 2

= L11 i1 + L12 i2 = L21 i1 + L22 i2

L11 = N1 (Ll1 + Lm1 ), L22 = N2 (Ll2 + Lm2 ) L12 = N1 Lm2 = N1 N2 = N2 Lm1 = L21 Rm

n = m = 2, g = I2 , G = 0, x = (1 , 2 ), e = (v1 , v2 ), i1 = 1 (1 , 2 ), i2 = 2 (1 , 2 ) L12 = L21 implies that i = L1 with L1 symmetric Maxwells reciprocity relations adding parasitic resistances means that G is no longer zero v1 = r1 i1 + d1 , dt v2 = r2 i2 + d2 dt

Assume now that Ll1 = Ll2 = 0 N1 N2 N1 1 = i1 + i2 Rm N2 N1 N2 N2 i1 + i2 2 = Rm N1

N2 = 2 N1

Furthermore, if r1 = r2 = 0, it follows from the dynamics, that v1 N2 = v2 N1 This is half the ideal transformer relationships! Let N1 N2 /Rm become very large while N1 /N2 remains nite N1 i1 N2 The minus sign is due to the all-input power convention

The nal assumption is this The only way for to remain nite is

i2 =

Elementary electromagnet
m i + v r N l F v = ri + d dt = N = l + m l = x but now Rm depends on the air gap x: 1 Rm (x) = 0 A li + 2x ri Ni , Rl m = Ni Rm

This again a 2-port system with state variables , x, inputs v (voltage) and V (velocity), and outputs i = 1 (, x), F = 2 (, x). = N N + Rl Rm (x)
2 2

i = (Ll + Lm (x))i

b N2 N 2 0 A Lm (x) = = li Rm c+x ri + 2x From this i = 1 (, x) can be computed. Exercise: Compute the force F (, x) and the electromechanical energy Wf (, x).

DC motor
N S

ia current into the page ia current out of the page a special mechanism with slip rings and brushes is necessary

if

if The main eect is direct conversion of energy without storing it in coordinate dependent elements = l1 l2 Bia vemf = l1 l2 B = l1 l2 Br

Assuming linear magnetic materials LAf B= if l1 l2 vemf = LAf if ia = LAf if r

pm

f = Lf if (the eld ux) a = LA ia (the armature ux) = Jm r (the mech angular momentum) pm

f a

= rf if + Vf

= LAf if r ra ia + Va = LAf if ia Br r TL

TL is the external mech torque

Exercise: Write the bond graph corresponding to the dc motor presented

Exercise: Show that, neglecting the eld port, in the limit when LA and Jm go to zero (dene this formally!), and dissipations disapear, the DC motor becomes a pure gyrator.

Co-energy for electromech systems


Suppose an electromechanical system with electrical state variables xe Rn and geometrical state variables Rm We have Wf = Wf (xe , ) associated ows fi (xe , ) = Wf (xe , ), xei
n X i=1

i = 1, . . . , n

Co-energy is dened as

Wc (f, xe , ) =

fi xei Wf (xe , )

. . . but

Wf Wc = fi (xe , ) = fi fi = 0, xei xei

i = 1, . . . , n

Hence, Wc can be written as a function of only f (and )

Legendre transformation
Widely used in analytical mechanics and thermodynamics While variables x are known as energy or Hamiltonian variables, transformed variables f are the co-energy or Lagrangian variables. Mechanical forces can be computed also from the co-energy Wc (f, ) = f xe (f, ) Wf (xe (f, ), ) Wc (f, ) = f xe xe Wf xe Wf = Wf = F f So mechanical forces can be computed as F = Wc notice again a reversed sign with respect to standard EE literature

For linear electromagnetic systems, q = C(x)v, = L(x)i, Wc (v, i, x) = Wf (q, , x)|q=q(v,x),=(i,x) In particular, for linear magnetic systems, 1 T 1 1 T Wf (, x) = L (x), Wc (i, x) = i L(x)i 2 2 Exercise: Prove the above equation. Exercise: Consider an electromechanical system with a nonlinear magnetic material such that = (a + bx2 )i2 , where a and b are constants and x is a variable geometric parameter. Compute Wf , Wc and f , and check all the relevant relations.

Port Hamiltonian modeling of electromechanical systems


Cast the previous systems as (explicit) port Hamiltonian models

x = (J (x) R(x))(H(x)) + g(x)u


x Rn , J is antisymmetric, R is symmetric and positive semi-denite and u Rm is the control H(x) is the energy (= Wf (x))

y = g T (x)(H(x))T

General electromechanical model


1 T 1 1 T 1 H(, p, ) = L () + p Jm p 2 2 are the generalized electrical energy variables (they may be charges or magnetic uxes) p are the generalized mechanical momenta (linear or angular, or associated to any other generalized coordinate) are the generalized geometric coordinates + Re i = Bv p = Rm Te (, ) + Tm 1 = Jm p B indicates how the input voltages are connected to the electrical devices Tm Te is the electrical torque is the external applied mechanical torque

1 i = L1 () = H, = Jm p = p H

Notice that the port yielding Te is internal (connected to the mechanical inertia) Te = 1 H = T L1 () 2 1 T L1 LL1 = 2

+ Re i = p = =

Bv Rm Te (, ) + Tm 1 Jm p

L1 = L1 LL1

Re x= 0 0

0 Rm 1

x = ( p )T

0 B 1 x H + 0 0 0

0 v 0 Tm 1

This general model includes many of the classical electrical machines, as well as linear motors and levitating systems. Exercise: Write the general port Hamiltonian model for the electromagnet and for the variable geometry capacitor The dc motor needs a special formulation x = H(x) =
T

1 1 T 1 2 L + p , L= 2 2Jm 0 0 0 0 LAf if , R = J = 0 0 LAf if 0 g = I3 u =


T

p = Jm r

Lf 0 rf 0 0 Va

0 LA 0 ra 0

0 0 Br

Vf

TL

The input voltages Vf and Va can be obtained from the same source in several ways

Shunt connection Va = Vf and iT = ia + if

Series connection ia = if and VT = Va + Vf

Exercise: Obtain the port Hamiltonian models of the shunt-connected and of the series-connected dc machines. The later is in fact an implicit port Hamiltonian model. Check this by writing the corresponding bond graph and identifying the dierential causality assignment.

Power converters
Control of electromechanical systems Portable battery-powered equipment UPS Power conversion systems (e.g. conditioning from fuel-cell, wind-based,. . . ) dc-to-dc: to elevate or reduce dc voltages in a load-independent way Power converters

ac-to-dc: rectiers dc-to-ac: inverters

dc-to-dc store the energy in intermediate ac elements an deliver it as needed

trick: use of switches, operated in a periodic manner system alternates between several dynamics

Variable Structure Systems (VSS)


VSS are non-smooth dynamical systems averaging Assume the VSS cycles over several dynamics in a periodic way Compute the average of relevant variables over a cycle State Space Averaging (SSA) diculties in simulation and control design

1 hxi(t) = T

x( ) d

tT

VSS in PHDS form

x = [J (S, x) R(S, x)] (H(x))T + g(S, x)u


S is a (multi)-index, with values on a nite, discrete set, enumerating the dierent structure topologies For simplicity, S {0, 1}

S = 0 x = (J0 (x) R0 (x))(H(x))T + g0 (x)u S = 1 x = (J1 (x) R1 (x))(H(x))T + g1 (x)u if x does not vary too much during a given topology S = 0 x (J0 (hxi) R0 (hxi))(H(hxi))T + g0 (hxi)u S = 1 x (J1 (hxi) R1 (hxi))(H(hxi))T + g1 (hxi)u

the length of time in a given cycle with the system in a given topology is determined by a function of the state variables in our approximation, a function of the averages, t0 (hxi), t1 (hxi), with t0 + t1 = T x(t) = x(t T ) + t0 (hxi) (J0 (hxi) R0 (hxi))(H(hxi)) + g0 (hxi)u T t1 (hxi) (J1 (hxi) R1 (hxi))(H(hxi)) + g1 (hxi)u
T

d hxi = dt +

T d0 (hxi) (J0 (hxi) R0 (hxi))(H(hxi)) + g0 (hxi)u T d1 (hxi) (J1 (hxi) R1 (hxi))(H(hxi)) + g1 (hxi)u d0 + d1 = 1 duty cycle

t0,1 (hxi) d0,1 (hxi) = T

Boost (step-up) dc-to-dc converter


iL iE L vL + E i2 s1 s2 v2 C v1 iC vC R iR vR s1 closed (s1 = 1) s2 open (s2 = 0) and viceversa only a single boolean variable S = s2

i1

Two energy-storing elements: H = HC + HL Two 1-d PHDS dqC = iC , dt dL = vL , dt H qC H L Connected by Kirchos laws iL = i1 + i2 i1 = iC + iR v2 + vL = E vC + v1 = v2 vC = vR iE + iL = 0

vC = iL =

Using the PHD equations, the rst four KL are written as H L i1 v2 + dL dt = i1 + i2 = dqC + iR dt

= E = v2 Internal ports

H + v1 qC

The second and third yield a 2-d PCH i1 v2 iR E

d dt

qC L

= 0(H)T +

1 0 1 0 0 1 0 1

True ports

The switches impose the following conditions S = 0 s1 = 1, s2 = 0 v1 = 0, i2 = 0 S = 1 s1 = 0, s2 = 1 i1 = 0, v2 = 0 For S = 1 we have the values of v2 and i1
H L = = = = i1 + i2 dqC + iR dt E v2

For S = 0
v2 +

i1 dL dt

i1 =

H H , v2 = L qC

H + v1 qC

i1 In compact form v2

H L H = (1 S) qC = (1 S)

Substituting i1 and v2 back in the 2-d PHS (1 S) H/L d qC 1 0 1 0 (1 S) H/qC = L iR 0 1 0 1 dt E 0 1S H/qC 1 0 iR + = H/L E (1 S) 0 0 1 J g

Is a consequence of Kirchos laws Skew symmetric Not a coincidence! being an instantiation of Dirac structures and F E T + EF T = 0 T H/qC vC vR 1 0 = = y= H/L iL iE 0 1 last two KL

Now we can terminate the resistive port and introduce some dissipation iR =
d dt qC L 0 (1 S)

vC 1 H vR = = R R R qC
1/R 0 0 0 H/qC H/L 0 + E 1

1S 0

symmetric, positive semidenite matrix

Only a single natural output y= 0 1 T H/qC H/L = iL = iE

So the boost converter, a VSS, has a PHDS representation. The three basic second order dc-to-dc converters have this representation 1/R ( S) S 0 0 1 S

x=

(H(x))T + 1 1 0 0 1 1 1 0 1

Converter buck boost buck-boost

x = (qC L )T Assuming linear elements, H(qc , L ) =


1 2 2C qC

1 2 2L L

x=

1/R ( S)

S 0

(H(x))T +

0 1 S

Let us compute the averaged equation d 1/R 0 hxi = d0 (hxi) (H(hxi))T + E 0 1 dt 1/R 0 (H(hxi))T + E + d1 (hxi) ( ) 0 1 d0 + d1 = 1 1/R d1 (hxi) 0 (H(hxi))T + E = 0 ( d1 (hxi)) 1 d1 (hxi) hSi = 0 d0 + 1 d1 d hxi = dt VSS averaged PHDS model (H(hxi))T + 0 1 hSi E

1/R hSi ( hSi) 0

Better averaged descriptions of VSS can be obtained by considering higher order Fourier-like coecients, instead of just hxi. k-phasors 1 hxik (t) = T Z
t

x( )ejk d
tT

The phasor averages of VSS PHDS are also PHDS

See printed notes for details

A storing and conditioning energy system


Many metropolitan electrical-based vehicles use dc-motors which draw their power from segmented dc power lines Vehicles are able to brake in a regenerative way, returning power to the line Power can be reused only if another vehicle is accelerating in the same segment of the power line if not, this power is dissipated in special resistors and lost

Problem: install in each power segment a device to store the excess energy and return it when needed at the required voltage

Due to several reasons (technical and economical) the storage elements must be either supercapacitors or mechanical ywheels A power conversion system must be put in the middle to deliver the energy in the required form r1 L1 r2 L2 diode R IGBT rN LN

il r C Si Ti Csc

The causal bond graph of the system is (power conventions are not displayed) R: R Sf : i l 1 S1 T1 R: r1 1 I: L1 I: Li 0 C: Csc 0 1 0 Si Ti R: ri 1 I: LN C: C 1 R: r SN TN R: rN 1

1 0

1 0

internal causality of each pair of switches is not xed by external causality

Two combinations of internal causality are possible ea Si 1 ea Si 1

ia

ia

Ti closed ideal switch: zero voltage source eb

0 ib

Ti eb

0 ib open ideal switch: zero current source

If Si = 1 when Si is closed and Si = 0 when Si is open, then eb ia = Si ea = S i ib

Each pair of switches can be modeled as a modulated transformer ea ia and then R: ri Si MTFi i =1 R: R 1 C: C R: r I: Li 1
eb ia = =

Si MTFi
S i ea S i ib

eb ib

i =N Sf : i l 1 0

i =N 0 i =1 C: Csc

Exercise: Write the state equations for the above bond graph. If you solve the above exercise, you will see that the resulting equations can be written in PHDS form with state variables q (charge of C), Q (charge of Csc ) and i (ux of Li , i = 1, . . . , N )
N 1 1 2 X 1 2 x = (J R)x H + gil q + H(Q, q, i ) = Q2 + i 2Csc 2C 2Li i=1 0 0 1 1 02N 022 0 0 S1 SN R = 0N 2 ij rj + rSi Sj 1 S1 0 0 J = . . . . . . . . 0 . . . . 1 0 0 1 SN rS1 g = rS2 . This can be obtained also from . . the interconnection of the individual rSN PHD subsystems, as we did for the boost.

The model can be expanded to include the power line + the electrical vehicles, or the supercapacitor can be substituted by a normal one attached to a dc-motor and a ywheel

Important modeling remarks The transformer model obtained is dependent on the external causality imposed upon each pair of switches. It has to be recomputed if something dierent is connected that changes that. The model has produced four-quadrant switches: there is no constraint on the signs of currents and voltages through them. In practice, the type of switch displayed is two-quadrant: it can sustain any current but only non-zero voltages in one way.

You might also like