state-space models 2 2nd order odes - university of...

16
State-space models 2 2 nd order ODEs J A Rossiter 1 Slides by Anthony Rossiter

Upload: others

Post on 15-Mar-2021

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

State-space models 2 2nd order ODEs

J A Rossiter

1

Slides by Anthony Rossiter

Page 2: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

Introduction

• This resource focuses on derivations of state space model equivalents for systems described by ODEs.

• Here we consider 2nd order ODEs (see separate resources for detailed derivation).

• The state-space model is defined in terms of the derivatives of the states. If you know the derivatives of all the states, then you can capture the system behaviour.

• States relate to dynamic variables such as displacement, height, tension, temperature, etc.

Slides by Anthony Rossiter

2

Page 3: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

States of a 2nd order ODE

1. The first step in forming a state space model is to define the states.

2. There should be enough independent states to capture the entire system dynamics – for low order systems this selection is usually obvious.

3. However, when presented with a high order differential equation, the user may have no access (or information) relating to the definition of the original underlying states, and thus an arbitrary definition can be used.

Slides by Anthony Rossiter

3

Page 4: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

Modelling a mass-spring-damper

Force balance can be used to determine the overall model of behaviour.

Slides by Anthony Rossiter

4

321

3

2

ˆ1

ffffdt

dvMf

kxf

vBf

kxvBdt

dvMf ˆ States are v and x

Page 5: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

States for mass-spring-damper

It is clear that the model contains states

velocity v and displacement x

so these are a logical choice.

For a state space model, find the derivatives of each state and stack into a single vector.

Slides by Anthony Rossiter

5

kxvBdt

dvMf ˆ

Page 6: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

State-space model

Write the derivatives of v and x and stack in a vector.

Slides by Anthony Rossiter

6

vdt

dxM

vBkxf

dt

dv

vdt

dx

vBkxfdt

dvM

ˆ

ˆ

fMx

vM

k

M

B

dt

dxdt

dv

Bz

A

0

1

01

ˆ

BfAzz

In compact form

Page 7: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

Resistor-inductor-capacitor in series

Consider the following circuit and use Kirchhoff’s voltage law to derive an appropriate model.

Slides by Anthony Rossiter

7

qCdt

dqR

dt

diLv

1

321

13

2

111

vvvv

qC

v

dt

diLv

dt

dqRiRv

States are i and q

Page 8: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

State-space model

Write the derivatives of i and q and stack in a vector.

Slides by Anthony Rossiter

8

qdt

diL

iRC

qv

dt

di

idt

dq

iRC

qv

dt

diL

vLq

iLCL

R

dt

dqdt

di

Bz

A

0

1

01

1

BvAzz

In compact form

Page 9: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

DC servo

The model can be summarised with some simple equations.

Here it may be less obvious which states to choice due to the possibilities of two angles/velocities, current, back emf and torque.

Slides by Anthony Rossiter

9

dt

dwJwBki

ikwdt

diL

LL

L

ˆ

Rv

Page 10: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

DC servo choice of state

The states of interest must be defined with an equation including their derivative.

Other states could be viewed as outputs (possible measurements) and in this case will be linearly dependent on the selected states.

Two obvious choices are wL and i:

Slides by Anthony Rossiter

10

dt

dwJwBkiikw

dt

diL L

LL ˆR;v

Page 11: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

State-space model of DC servo

Express the derivatives of the selected states in a column vector.

Slides by Anthony Rossiter

11

v

Li

w

L

R

L

kJ

k

J

B

dt

didt

dw

Bz

L

A

L

10

ˆ

LL

L

LLL

wJ

Bi

J

k

dt

dw

Liw

L

k

L

v

dt

di

dt

dwJwBkiikw

dt

diL

ˆ;

R

ˆR;v

BvAzz

Page 12: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

DC servo with displacement

Should the user be interested in the angular position as well as the angular velocity, then an additional state is needed.

Slides by Anthony Rossiter

12

dt

dw

dt

dwJwBkiikw

dt

diL L

LL

LL

;ˆR;v

vL

i

w

L

R

L

kJ

k

J

B

dt

ddt

didt

dw

L

L

L

L

0

10

001

0

Page 13: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

Pendulum

• A pendulum of length l with end mass m is able to swing freely (assume some friction – constant k).

• A model can be derived using force balance in the tangential direction (small angles).

• Choose states:

Slides by Anthony Rossiter

13

mass - m

length - l

klmgml

w ,

Page 14: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

Pendulum state space model

State derivatives:

Slides by Anthony Rossiter

14

mass - m

length - l

klwmgdt

dwml w

dt

d

f

wml

mg

ml

kl

dt

ddt

dw

BzA

0

0

01

BfAzz

Page 15: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

Summary

Illustrated state-space model derivation for several common 2nd order systems.

It is noted that the selection of states is important, but this choice is often obvious from the underlying component and balance equations as only certain states will have their derivatives defined explicitly.

The compact form has vectors of states/inputs and matrices of coefficients.

Slides by Anthony Rossiter

15

BuAxx

Page 16: State-space models 2 2nd order ODEs - University of Sheffieldcontroleducation.group.shef.ac.uk/statespace/state space... · 2016. 2. 1. · States of a 2nd order ODE 1. The first

© 2016 University of Sheffield This work is licensed under the Creative Commons Attribution 2.0 UK: England & Wales Licence. To view a copy of this licence, visit http://creativecommons.org/licenses/by/2.0/uk/ or send a letter to: Creative Commons, 171 Second Street, Suite 300, San Francisco, California 94105, USA. It should be noted that some of the materials contained within this resource are subject to third party rights and any copyright notices must remain with these materials in the event of reuse or repurposing. If there are third party images within the resource please do not remove or alter any of the copyright notices or website details shown below the image. (Please list details of the third party rights contained within this work. If you include your institutions logo on the cover please include reference to the fact that it is a trade mark and all copyright in that image is reserved.)

Anthony Rossiter Department of Automatic Control and

Systems Engineering University of Sheffield www.shef.ac.uk/acse