<< Chapter < Page Chapter >> Page >
Matrix representation of systems

State equations

Knowing that a system's state describes its dynamics, or memory, it is also useful to examine how the state of a system evolves over time. A system's state will vary based on the current values of the state as well as the inputs to the system:

t 1 y t y t 0

Looking at an example will help to see why calculating the time-varying behavior of the state is important.

A system is described by the following differential equation:

t 2 y t 3 t 2 y t 2 y t 0

The state of this system is

x t x 1 t x 2 t y t t 1 y t

The state x t (a vector) is composed of two state variables x 1 t and x 2 t . We would like to be able to talk about the time-varying state in terms of these state variables. That is, we'd like an expression where t 1 x t can be written in terms of x 1 t and x 2 t . From state equation above, we see that t 1 x 1 t simply equals t 1 y t . In the same equation we also notice that t 1 y t equals t 1 x 2 t . Therefore, the derivative of the first state variable exactly equals the second state variable.

t 1 x 1 t t 1 y t x 2 t

We can follow the same process for x 2 t . Again from state equation , we see that the first derivative of x 2 t equals the second derivative of y t . At this stage, we can bring in information from the system's differential equation. That equation (the first one in this example) also contains the second derivative of y t . If we solve for it we get

t 2 y t -3 t 1 y t 2 y t u t

We already know that t 1 y t equals x 2 t and that y t equals x 1 t . Putting all of this together, we can get an expression for t 1 x 2 t in terms of the state variables and the input variable.

t 1 x 2 t t 2 y t -3 t 1 y t 2 y t u t -3 x 2 t 2 x 1 t u t

The important thing to notice here is that by looking at the time-varying behavior of the state, we have been able to reduce the complexity of the problem. Instead of one second-order differential equation we now have two first-order differential equations.

Think about a case where we might have 5, 10, or even 20 state variables. In such an instance, it would be difficult to work with so many equations. For this reason (and in order to have a more compact notation), we represent these state variable equations in terms of matrices. The set of equations above can be written as:

t 1 x 1 t x 2 t 0 1 -2 -3 x 1 t x 2 t 0 1 u t

By letting x t x 1 t x 2 t , A 0 1 -2 -3 , B 0 1 , we can rewrite this equation as:

t 1 x t A x t B u t

This is called a state equation .

Got questions? Get instant answers now!

State equations are always first-order differential equations. All of the dynamics and memory of the system are characterized in the state equations.In general, in a system with n state variables and m inputs, A is n x n , x t is n x 1 , B is n x m , and u t is m x 1 .

State equation matrices

State Equation Matrices

Output equations

Now that we've seen how to examine a system with respect to its state equations, we can move on to equations defining the relationships between the outputs of the system and the state and input variables. The outputs of a system can be written as sums of linear combinations of state variables and input variables. If in the example above the output y t depended only on the first state variable, we could write y t in matrix form:

y t x 1 t 1 0 x 1 t x 2 t

More generally, we can express the output (or outputs) as:

y t A x t D u t

In a system with m inputs, n state variables, and p outputs, y t is p x 1 , C is p x n , x t is n x 1 , D is p x m , and u t is n x 1 . Output equations are only algebraic equations; there are no differential equations and therefore, there is no memory component.

If we assume that m p 1 and D 0 , we can elininate x t in a combination of the state equations and output equations to get the input/output relation q t y t p t u t . Here the degree of q equals the degree of p .

Let's develop state and output equations for the following circuit diagram:

Example circuit 1

Example Circuit 1

There are two energy-storage elements in this diagram: the inductor and the capacitor. As we know that energy-storage elements give systems memory, it makes sense that the state variables should be the current i L flowing through the inductor and the voltage v C across the capacitor. By using Kirchoff's laws around the left and center loops, respectively, we can find the following two equations:

u i L 1 2 t i L v C
i L v C 2 1 3 t v C

These equations can easily be rearranged to have the derivatives on the left-hand side equaling linearcombinations of state variables and inputs on the right. These are the state equations. The figure also quicklytells us that the output y is equal to the voltage across the capacitor, v C .

We can now rewrite the state and output equations in matrix form:

t i L t v C -2 -2 3 -3 2 i L v C 2 0
y 0 1 i L v C 0 u
Got questions? Get instant answers now!

Compact system notation

We now introduce one more simple way to simplify the representation of systems. Basically, to better use thetools of linear algebra, we will put all four of the matrices from the state and output equations (i.e., A , B , C , and D ) into one large partitioned matrix:

Compact system matrix notation

Compacty System Matrix Notation

In this example we'll find the state and output equations for the following circuit, as well as represent the system using the compact notation described above.

Example circuit 2

Example Circuit 2

Here, u and y are the input and output currents, respectively. x 1 and x 2 are the state variables. Using Kirchoff's laws and the i - v relation of a capacitor, we can find the following three equations:

u y x 1
x 1 A t x 2
R y t x 1 x 2

Through simple rearranging and substitution of the terms, we find the state and output equations:

State equations:

t x 1 -1 L x 2 R L u x 1
t x 2 1 A x 1

Output equation:

y x 1 u

This equations can be more compactly written as:

A B A D R L -1 L 1 A 0 R L 0 1 0 0
Got questions? Get instant answers now!

The simple oscillator is defined by the following differential equation:

t 2 y y u

The states are x 1 y (which is also the output equation) and x 2 t 1 y . These can be rewritten in state equation form as:

t x 1 x 2
t x 2 x 1 u

The compact matrix notation is:

A B A D 0 1 -1 0 0 1 1 0 0
Got questions? Get instant answers now!

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, State space systems. OpenStax CNX. Jan 22, 2004 Download for free at http://cnx.org/content/col10143/1.3
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'State space systems' conversation and receive update notifications?

Ask