et3-7: modelling ii(v) electrical, mechanical and...

61
ET3-7: Modelling II(V) Electrical, Mechanical and Thermal Systems

Upload: hoangtu

Post on 03-Oct-2018

233 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

ET3-7: Modelling II(V)

Electrical, Mechanical and Thermal Systems

Page 2: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

Agenda of the Day1. Resume of lesson I

2. Basic system models.

3. Models of basic electrical system elements

4. Application of Matlab/Simulink to the simulation of the behaviour of electrical dynamic systems

Page 3: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.1(14)An example dynamic system

• An electrical dynamic system

• Moves the coil and cone

• A mechanical system

• Which drives the air

• A thermodynamic system

• We want a method to predict what will happen during operation

Page 4: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.2(14)What do we need?

• Theory that works for many different physical processes

• Solves electrical, magnetic, mechanical and thermal problems

• Steady state characteristics;– capacity; efficiency; losses; sizing

• Transient response;– steady state errors; stability; settling time; etc.

• System behaviour during faults?• Theory must account for the past history

of the system and enable us to predict future behaviour under known applied conditions

Page 5: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.3(14)Example - Concept of a

cruise control system for a car

• A cruise control system in a car comprises several sub-systems.

Page 6: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.4(14)Example - Coupling between

mechanical and electrical systems

• concept of a battery powered vehicle

Page 7: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.5(14)Force Balance

• The equation of motion• Various mechanical

forces oppose movement• Acceleration of the

mass• Various frictional forces• Gravity (not shown)• Wind (not shown)

F e

dx

mBx f+

mx

= ⋅ + ⋅ +eF m x B x f

Page 8: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.6(14)Simple Linear Mechanical system

= + +F mx Bx f

Page 9: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.7(14)Simple Rotating Mechanical system

T J B fT J B f

= + +

= + +

θ θω ω

Page 10: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.8(14)More Complicated Mechanical system

• Break it down to a set of free body diagrams• Write the differential equations• And solve them (integrate them)

Page 11: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.9(14)Needs a Free Body Diagram

for Each Mass

• We arrive at a set of simultaneous differential equations

Page 12: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.10(14)Needs a Free Body Diagram

for Each Mass

• In this way, we arrive at a set of simultaneous differential equations

( ) ( )( ) ( ) ( )

− + − − − =

− − − − − =2 1 2 2 1 1 1 1 1

2 2 2 1 2 2 1

00a

B x x K x x Mx K xf t M x B x x K x x

Page 13: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.11(14)The State-Space formulation

• Convenient to solve using Matlab/Simulink• Manipulate the differential equations

– a set of first order ordinary differential equations• Isolate the differential term• The standard form

= + + + +

= + + + +

= + + + +

= + + + +

= + + + +

1 11 1 12 2 13 3 11 1 12 2

2 21 1 22 2 23 3 21 1 22 2

3 31 1 32 2 33 3 31 1 32 2

1 11 1 12 2 13 3 11 1 12 2

2 21 1 22 2 23 3 21 1 22 2

q a q a q a q b u b uq a q a q a q b u b uq a q a q a q b u b u

y c q c q c q d u d uy c q c q c q d u d u

Page 14: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.12(14)The State-Space formulation

in Matrix Form

• The standard form• In Matrix Form

⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤= +⎣ ⎦ ⎣ ⎦ ⎣ ⎦ ⎣ ⎦⎣ ⎦⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤= +⎣ ⎦ ⎣ ⎦ ⎣ ⎦ ⎣ ⎦ ⎣ ⎦

Q A Q B UY C Q D U

Page 15: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.13(14) Steps When Modelling a System

• Physics and topology• Select the model

– Simplifying assumptions– Draw the Free Body Diagram(s)

• Write the equations of motion– Differential equations

• Values of system coefficients– Mass; moment of inertia; inductance;

resistance etc. • Solve the equations of motion

– Integrate them

Page 16: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

1.14(14)Cruise Control for a Car

• So the State-Space Matrices are

⎡ ⎤ ⎡ ⎤⎢ ⎥ ⎢ ⎥ ⎡ ⎤= = = =⎣ ⎦⎢ ⎥ ⎢ ⎥−⎢ ⎥ ⎢ ⎥⎣ ⎦ ⎣ ⎦

0 1 0, , 1 0 , 010

A B C Dbm m

Page 17: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2. Basic System Models

Page 18: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.1(33) System models• A system usually comprises several sub-

systems• They may be a mix of types

– Electrical– Mechanical– Thermal

• Like our cruise control system

Page 19: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.2(33) A cruise control system for a car

• A cruise control system in a car comprises several sub-systems.

Page 20: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.3(33) Example: A Translational Electro-mechanical Actuator

• Loudspeaker

Page 21: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.4(33) Notional Model of a Loudspeaker

• Consider the electrical and mechanical sub-systems of the moving coil loudspeaker.

• The electrical and mechanical subsystems of the loudspeaker are coupled by the Lorentz force and by the back emfacting on the circuit.

• The Lorentz force caused by current flowing in the coil reacting with the magnetic field acts on the mass, causing it to move

• The motion of the coil in the magnetic field induces Faraday’s Law voltage in the coil, opposing the current

Page 22: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.5(33) Model of the electrical sub-system of the loudspeaker

• Modelling the electrical sub-system uses a circuit diagram comprising:– the supply voltage source, – a resistor, – an inductor, – and a velocity dependent voltage

source.

• The resistor represents the resistance of the coil

• The inductor is the inductance of the coil.

• The velocity dependent voltage source represents the effect of the back emf. (Faraday’s Law)

Page 23: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.6(33) Model of the mechanical sub-system of the loudspeaker

• Modelling the mechanical sub-system employs a free body diagram in which – a spring force, – a damping force, – An inertial force, – and the Lorentz force act on the mass.

• The Lorentz force is the current dependent actuating force.

Page 24: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.7(33)Model of the electrical sub-system of the loudspeaker

• The arrow indicates the direction of positive current flow

• The the plusses and minuses indicate the direction of voltage drop.

• Kirchhoff's current law around the loop yields

i R B Le - e - e - e = 0

Page 25: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

• The voltages are denoted by:

• Leading to:

2.8(33) Model of the electrical sub-system of the loudspeaker

i

R

b

L

Voltage Source e (t)Resistor e = RiBack EMF e = qx'Inductor e = Li'

ie (t) - Ri - qx' - Li' = 0

Page 26: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.9(33) Model of the mechanical sub-system of the loudspeaker

• Four forces act on the mass representing the voice coil and cone.

• D'Alembert's Law states that the sum of all forces acting on a body including the inertial force is equal to zero:

Spring Force kx Toward the LeftDamper Force bx' Toward the Left Inertial Force mx" Toward the LeftLorentz Force qi Toward the Right

-mx" - bx' - kx + qi = 0

Page 27: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.10(33) Concept Of Transfer Function

• The transfer function is an alternative model to the State Space formulation

• It takes a single input and yields a single output

• It is useful because there are techniques to analyse system performance

• These techniques are very useful for system design

Page 28: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.11(33) Transfer function• The equation of motion of the free body

diagram and the voltage equation of the electric circuit are in the time domain.

• Together, these determine the transfer function of the electromechanical system from the voltage input to the displacement output.

Page 29: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.12(33) The Time Domain Differential Equations are:

i

-mx" - bx' - kx + qi = 0e (t) - Ri - qx' - Li' = 0

Page 30: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.13(33) The Laplace Transform relations for a variable and its first and second derivatives are as follows:

( ){ } ( )

( ){ } ( ) ( )

( ){ } ( ) ( ) ( )

x t X s

x t sX s x

x t s X s sx x

'

'' 2 '

0

0 0

=

= −

= − −

L

L

L

The initial conditions are assumed to be zero

x(0) = 0, x'(0) = 0

Page 31: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.14(33) Laplace Transform of Equations of Motion

( ) ( ) ( ) ( )( ) ( ) ( ) ( )i

ms X s bsX s kX s qI sE s RI s qsX s LsI s

2 00

− − − + =

− − − =

or

( ) ( )

( ) [ ] ( ) ( )i

ms bs k X s qI sE s Ls R I s qsX s

2 0

0

⎡ ⎤− − − + =⎣ ⎦− + − =

Page 32: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.15(33) The transfer function is the ratio of the Laplace transform of the output to

the Laplace transform of the input

( ) itf X s E s/ ( )=

We need to eliminate I(s)

( ) ( )I s ms bs k X sq

21 ⎡ ⎤= + +⎣ ⎦

Page 33: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.16(33) The transfer function is the ratio of the Laplace transform of the output to

the Laplace transform of the input

[ ] ( )

( )[ ]

i

i

E s Ls R ms bs k qs X sq

X s qE s Ls R ms bs k q s

2

2 2

1( )

( )

⎡ ⎤⎡ ⎤− + + + −⎢ ⎥⎣ ⎦

⎣ ⎦→

=⎡ ⎤+ + + −⎣ ⎦

Substituting to eliminate I(s)

Page 34: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.17(33) To write a Matlab script for the transfer function

>> R = 5; L = 5e-5; k = 2e5; b = 50; m = 4e-3; q = pi;

>> s = tf('s');

>> electromech_tf = q/((L*s+R)*(m*s^2+b*s+k)-q^2*s)

Transfer function:3.142-----------------------------------------2e-007 s^3 + 0.0225 s^2 + 250.1 s + 1e006

>> bode(electromech_tf); grid>> impulse(electromech_tf);grid>> step(electromech_tf);grid

DEMO00.m

Page 35: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.18(33) Transfer function is a model limited to the relationship between a

single input and a single output

• We may require to know the transient behaviour of the current variable as well

• The State Space formulation can help us here

• We can make a model with several inputs and several outputs

Page 36: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.19(33) The state-space formulation

x' = A x + B uy = C x + D u

• y is the output and x is the state variable• Both x and y may be a vector• In the case of vector variables, ABCD become vectors or matrices

Page 37: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.20(33) Steps required to determine the state-space model

• Identify the energy storage elements

• Select the state variables

• Identify any trivial state equations

• Determine other necessary state equations using element laws and interconnections

• Write the model in vector-matrix form

Page 38: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.21(33) Energy storage elements

• Electrical• The only electrical

element in this system that can store energy is the inductor.

Page 39: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.22(33) Energy storage elements

• Mechanical

• Two mechanical elements in this system can store energy

• One is the spring

Page 40: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.23(33) Energy storage elements

• Mechanical• Two mechanical

elements in this system can store energy

• The other is the mass

Page 41: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.24(33) Stored Energy and State Variables

v½ mv2Mass

x½ kx2Spring

i½ Li2Inductor

State VariableEnergy StorageRelationship

Energy StorageElement

Page 42: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.25(33) Selecting States

• From the table, the three candidate state variables in our system are – i, the current passing through the coil; – x, the position of the speaker diaphragm; – and v, the velocity of the speaker diaphragm.

• At this point these are only candidate state variables

• It may be necessary to define new state variables, if the derivative of the input appears in one or more of the equations.

Page 43: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.26(33) Identifying Trivial State Equations

• Trivial state equations are those state equations defined by mathematics rather than physics.

• In this example there is only one trivial state equation, namely:

x v' =

Page 44: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.28(33) Determining Other State Equations Using Element Laws And

Interconnections• Equations of motion• ei(t) is the input voltage

• Substitute state variables

• Manipulate to solve for derivative as a function of the states and the input

• Output equation

i

-mx" - bx' - kx + qi = 0e (t) - Ri - qx' - Li' = 0

i

-mv'- bv - kx + qi = 0e (t) - Ri - qv - Li' = 0

[ ]

( )[ ]i

1v'= bv kx qim1i'= e t Ri qvL

− − +

− −

y x=

Page 45: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.29(33) Manipulate the Equations of Motion

• Manipluate the equations to give the first derivatives as a function of the states and the inputs

• This is a form suitable for numerical integration• Include the trivial state equations if you need them

i

x'= vqk bv' = - x - v + i

m m mq R e (t)i' = - v - i + L L L

Page 46: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.30(33)Towards Matrix Forma) Define the State Vector

i

x'= vqk bv' = - x - v + i

m m mq R e (t)i' = - v - i + L L L

x' = A x + B uy = C x + D u

⎡ ⎤⎡ ⎤⎢ ⎥⎢ ⎥= ∧ = ⎢ ⎥⎢ ⎥⎢ ⎥⎢ ⎥⎣ ⎦ ⎣ ⎦

'' '

'

x xx v x v

i i

Page 47: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.31(33) Towards Matrix Forma) Define the Input Vector

i

x'= vqk bv' = - x - v + i

m m mq R e (t)i' = - v - i + L L L

x' = A x + B uy = C x + D u

⎡ ⎤⎢ ⎥= ⎢ ⎥⎢ ⎥⎣ ⎦

00i

ue

Page 48: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.32(33) Towards Matrix Forma) Define the Coefficient Matrices

i

x'= vqk bv' = - x - v + i

m m mq R e (t)i' = - v - i + L L L

x' = A x + B uy = C x + D u

⎡ ⎤⎢ ⎥⎢ ⎥− −⎢ ⎥= ∧ = ⎡ ⎤⎣ ⎦⎢ ⎥⎢ ⎥− −⎢ ⎥⎢ ⎥⎣ ⎦

= ∧ =⎡ ⎤ ⎡ ⎤⎣ ⎦ ⎣ ⎦

0 1 0

0 0 1

0

1 0 0 0 0 0

qk bA Bm m m

q RL L

C D

Page 49: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

2.33(33) The Finished Matrix Form

i

x'= vqk bv' = - x - v + i

m m mq R e (t)i' = - v - i + L L L

x' = A x + B uy = C x + D u

( )

( )

⎡ ⎤⎢ ⎥

⎡ ⎤ ⎡ ⎤⎢ ⎥− − ⎢ ⎥ ⎢ ⎥⎢ ⎥= + ⎡ ⎤⎣ ⎦⎢ ⎥ ⎢ ⎥⎢ ⎥

⎢ ⎥ ⎢ ⎥⎢ ⎥ ⎣ ⎦ ⎣ ⎦− −⎢ ⎥⎢ ⎥⎣ ⎦

⎡ ⎤ ⎡ ⎤⎢ ⎥ ⎢ ⎥= +⎡ ⎤ ⎡ ⎤⎣ ⎦ ⎣ ⎦⎢ ⎥ ⎢ ⎥⎢ ⎥ ⎢ ⎥⎣ ⎦ ⎣ ⎦

0 1 0 0' 0 0 1 0

0

01 0 0 0 0 0 0

i

i

xqk bx v

m m m i e tq RL L

xy v

i e t

Page 50: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

3. Models of basic electrical system elementsFrequency response,

impulse/step response, working with Matlab.

Page 51: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

3.1(3)Frequency response• Consider an RL circuit

supplied with an alternating voltage

• V is the input quantity• I is the output quantity• If f is variable, I

becomes I(f)• The circuit response to

a pure sinusoidal signal is governed by the transfer function

v f

IR

LeAC

Page 52: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

3.2(3) Example of Frequency response

• RLC filter• Kirchhoff’s laws• 2nd order equation• Apply Laplace

transform• transform the

differential equation to an algebraic equation

• This is an initial value problem

E i

iR L

E oC

E iR L didt C

i dt

EC

i dt

i

o

= + +

=

zz

1

1

Page 53: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

3.3 (3) Transfer function for an RLC filter

E iR L didt C

i dt EC

i dt

E s I s R sLsC

E s I ssC

E sE s

I ssC

I s R sLsC

E sE s s LC sCR

i o

i o

o

i

o

i

= + + ∩ =

= + +FHG

IKJ ∩ = F

HGIKJ

FHGIKJ =

FHGIKJ

+ +FHG

IKJ

FHGIKJ = + +

z z1 1

1 1

1

1

112

a f a f a f a f

a fa f

a f

a f

( )

( )

Page 54: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

4.Application of Matlab/ Simulink to the simulation of the behaviour of electrical

dynamic systems

Page 55: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

4.1(5) The equation of motion• Bridged Tee circuit• Node 4 is the

voltage reference

( )

1

2 31 2 21

1 2

3 13 22

2

1

2

0

3

0

i

nodev vnode

v vv v dvCR R dt

noded v vv v C

R dt

=

−−− + + =

−−+ =

Page 56: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

4.2(5) Use of MATLAB function ss• Use of the Matlab function ss

– Creates a Matlab system object from the A,B,C,D matrices

– The response of the system may then be analysed in several ways

– We need to select the State Variables and create the ABCD Matrices

– State variables are usually related to the energy stored in system elements

– Here the energy storing elements are the two capacitances

Page 57: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

4.3(5) Selection of State Variables

• The stored energy is given by:

• This leads us to select the voltage across each capacitor as state variables

2½CW Cv=

Page 58: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

4.4(5) We need first order differential equations in these

• How do they look?

11 2

1 1 2 1 2 1 1 2

2 1 2

2 2 2 2 2 2

1 1 1 1 1 1 1 1CC C i

C C C i

dv v v vdt C R R C R C R R

dv v v vdt C R C R C R

⎛ ⎞ ⎛ ⎞ ⎛ ⎞= − + − + +⎜ ⎟ ⎜ ⎟ ⎜ ⎟⎜ ⎟ ⎜ ⎟ ⎜ ⎟

⎝ ⎠ ⎝ ⎠ ⎝ ⎠

= − − +

Page 59: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

4.5(5) In Matrix form

1 1 2 1 2

2 2 2 2

1 1 2

2 2

1 1 1 1 1

1 1

1 1 1

1

C R R C RA

C R C R

C R RB

C R

⎡ ⎤⎛ ⎞ ⎛ ⎞− + −⎢ ⎥⎜ ⎟ ⎜ ⎟⎜ ⎟ ⎜ ⎟⎢ ⎥⎝ ⎠ ⎝ ⎠= ⎢ ⎥⎢ ⎥− −⎢ ⎥⎣ ⎦

⎡ ⎤⎛ ⎞+⎢ ⎥⎜ ⎟⎜ ⎟⎢ ⎥⎝ ⎠= ⎢ ⎥

⎢ ⎥⎢ ⎥⎣ ⎦

Page 60: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

Exercises

• Using. Matlab construct a bode plot for this Bridged Tee Circuit.

Page 61: ET3-7: Modelling II(V) Electrical, Mechanical and …homes.et.aau.dk/aer/ET3-7Modellering/Resources/ET3-7Modelling_2M… · ET3-7: Modelling II(V) ... Bx x K x x Mx Kx ft Mx Bx x

Exercises

• Lit.[1]– Problem 6.1– Problem 6.3

• In each case writ a Matlab script to find the output as a function of the applied frequency and plot a Bode plot of the output.