Transcript Document

ECE 8443 – Pattern Recognition

LECTURE 38:

THE STATE EQUATIONS

Objectives:

Motivation Differential Equations Applications to Circuits

Resources:

Wiki: State Variables YMZ: State Variable Technique Wiki: Controllability URL: Audio:

Motivation

Thus far we have dealt primarily with the input/output characteristics of linear systems. State variable, or state space, representations describe the internal state of the system.

State variables represent a way to describe ALL linear systems in terms of a common set of equations involving matrix algebra.

Many familiar properties, such as stability, can be derived from this common representation. It forms the basis for the theoretical analysis of linear systems.

State variables are used extensively in a wide range of engineering problems, particularly mechanical engineering, and are the foundation of control theory.

The state variables often represent internal elements of the system such as voltages across capacitors and currents across inductors.

They account for observable elements of the circuit, such as voltages, and also account for the initial conditions of the circuit, such as energy stored in capacitors. This is critical to computing the overall response of the system.

Matrix transformations can be used to convert from one state variable representation to the other, so the initial choice of variables is not critical.

Software tools such as MATLAB can be used to perform the matrix manipulations required.

ECE 3163: Lecture 38, Slide 1

State Equations

Let us define the state of the system by an N-element column vector, x (

t

)

: x

(

t

)      

x

1

x

2

x N

 ( (

t t

(

t

) ) )       

x

1 (

t

)

x

2 (

t

) 

x N

(

t

)

t

Note that in this development, v (

t

) will be the input, y (

t

)

will be the output, and

x

(

t

)

is used for the state variables.

Any system can be modeled by the following state equations:

(

t

) 

Ax

(

t

) 

Bv

(

t

)

y

(

t

) 

C

x

(

t

) 

Dv

(

t

)

x

:

Nx

1

y

:

qx

1

A

:

NxN

C

:

qxN

B

:

Nxp

D

:

qxp p

: number of inputs

q

: number of outputs •

This system model can handle single input/single output systems, or multiple inputs and outputs.

The equations above can be implemented using the signal flow graph shown to the right.

Works for ALL linear systems!

ECE 3163: Lecture 38, Slide 2

Differential Equations

Consider the CT differential equations:

y

 (

t

) 

a

1 (

t

) 

a

0

y

(

t

) 

b

0

v

(

t

) •

A second-order differential equation requires two state variables:

x

1 (

t

) 

y

(

t

)

x

2 (

t

)  (

t

) • •

We can reformulate the differential equation as a set of three equations:

x

 1 (

t x

 2 (

t

) )  

x

2 (

t

) 

a

0

x

1 (

t

) 

a

1

x

2 (

t

) 

b

0

v

(

t

)

y

(

t

) 

x

1 (

t

)

We can write these in matrix form as:

• •   

x

 2 1 ( (

t t

) )       0

a

0  1

a

1    

x x

2 1 ( (

t t

) )      0

b

0  

v

(

t

)

y

(

t

)   1 0   

x

1

x

2 ( (

t t

) )   This can be extended to an N

th

-order differential equation of this type:

y

(

t

) 

i N

   0 1

a i y

(

t

) 

b

0

v

(

t

)

The state variables are defined as:

x i

(

t

) 

y

(

i

 1 )   ,

i

 1 , 2 , ...,

N

ECE 3163: Lecture 38, Slide 3

Differential Equations (Cont.)

The resulting state equations are:

x

x

 1 (

t

)  2 (

t

) 

x

2 (

t

)

x

3 (

t

) 

N

 1 (

t

) 

x N

(

t

)

x

N

(

t

)  

N i

   0 1

a i x i

 1 (

t

) 

b

0

v

(

t

)

y

(

t

) 

x

1 (

t

)

A C

          1  0 0 0 

a

0 0 1 0  0 1  0 0 

a

1  0  0

a

 2       0  1

a N

 1       

B D

    0 0    

b

 0 0         0 •

Next, consider a differential equation with a more complex forcing function:

y

 (

t

) 

a

1 (

t

) 

a

0

y

(

t

) 

b

1

v

 (

t

) 

b

0

v

(

t

) •

The state model is:

 

x

x

 1 2 ( (

t t

) )       0

a

0  1

a

1    

x x

2 1 ( (

t t

) )      0 1  

v

(

t

)

y

(

t

)  

b

0

b

1   

x

1

x

2 ( (

t t

) )   •

We can verify this by expanding the matrix equation:

x

 1 (

t

) 

x

2 (

t

)

x

 2 (

t

)  

a

0

x

1 (

t

) 

a

1

x

2 (

t

) 

v

(

t

)

y

(

t

) 

b

0

x

1 (

t

) 

b

1

x

2 (

t

)

ECE 3163: Lecture 38, Slide 4

Differential Equations (Cont.)

To construct the original equation, differentiate the last equation:

y

 (

t

)   

b

0

b

0

x

 1

x

2 

a

1

y

(

t

(

t

(

t

) ) )   

b

1

b

1 

x

  2  (

t a

1

b

0

a

0 ) 

x

1 (

t

)

a

0

b

1  

x

1

a

1 (

t x

2 )  (

t

)

b

0 

x

2

v

(

t

(

t

) )  

b

1

v

(

t

) •

Differentiate the last equation again and substitute:

y

 (

t

)  

a

1   

b

0

a

1   (

t

) (

t

)

a

0  

x

1 (

t

 

a

1

b

0

a

1

b

0 ) 

a

1  

a

0

b

1

a

0

b

1

x

2 (

t

)    1

x

2 (

t

(

t

) ) 

v

(

t

)   

b

0  2

b

1

v

 (

t

(

t

) ) 

b

1

v

 (

t

) •

y

y

 (

t

) 

a

1 (

t

) 

a

0

y

(

t

)     

a

1 

a

1 

a

1

b

0

v

(

t

) ( (

t t

) )  

b a

0 0

a

0 

b

0

x

1

x

(

t

) 

a

0

y

(

t

) 

b

1

v

 (

t

) 1 (

t

(

t

) )  

a

0

b

1

b

1

x

2

x

2 (

t

(

t

)  )  

b

0

b

0

v v

(

t

(

t

) )  

b

1

v

 (

t b

1

v

 (

t

) ) 

b

0

v

(

t

) 

b

1

v

 (

t

)

Hence, given a general LTI system:

(

t

) 

i N

  1  0

a i y

(

t

)

ECE 3163: Lecture 38, Slide 5

i N

  1  0

b i v

(

t

)

A

C

       0 0  0   

a

0

b

0 

b

1 1 0  0

a

1

b

2  0 1  0

a

2      

b N

 

D

0  1

a N

 1         0

B

        0 0  0 1       

Application to Circuits (Using Slide #3)

dy

(

t

) 

dt

1

RC y

(

t

)  1

RC v

(

t

)

A

a

0  1

RC

 

B

   0    1

RC

 

C

D

 0    1 (

t

)      1

RC y

(

t

)   1     

x

1 (

t

)       1

RC

  

v

(

t

)   

x

1 (

t

)  

d

2

y

(

t

) 

dt

2

R L dy

(

t

) 

dt

1

LC y

(

t

)  1

LC v

(

t

)

A

    0

a

0  1

a

1       1 / 0

LC

B

C

  0

b

0   1     0   1 / 0

LC

D

   0 1 

R

/

L

   

x

 1  2 (

t

(

t

) )       1 / 0

LC y

(

t

)   1 1 

R

/

L

   

x x

2 1 ( (

t t

) )      1 / 0

LC

 

v

(

t

) 0   

x

1

x

2 ( (

t t

) )  

ECE 3163: Lecture 38, Slide 6

Summary

Introduced the concept of a state variable.

Described a linear system in terms of the general state equation.

Demonstrated a process for deriving the state equations from a differential equation with a simple forcing function.

Generalized this to an Nth-order differential equation with a more complex forcing function.

Demonstrated these techniques on a 1 st -order (RC) and 2 nd -order (RLC) circuit.

Observation: We have now encapsulated all passive circuit analysis (RLCs) into a single matrix equation. In fact, we now have a unified representation for all linear time-invariant systems.

Next: How can we solve these equations? (Hint: Laplace Transform)

Further, even nonlinear (and non-time-invariant) systems can be modeled using these techniques. However, the resulting differential equations are more complex. Fortunately, we have powerful numerical modeling techniques to handle such problems.

ECE 3163: Lecture 38, Slide 7