# Defining Matrix Equations

a) Write a state equation for this system:

d^2y / dt^2 + 3 dy / dt + 2y = u

b) Add a new state in which x_3 = y - y_d where yd is the unit step and represents the desired output of the system. Write the new state equations treating yd as another input.

c) Now, pick a vector k=[k,,k2,k3] such that if u=-kx, the new state will have roots of the characteristic equation at -2, -3, and -4

d) Simulate the system and observe the output y and compare the response for yd=step input to the step response of the system without control.

Helpful notes:

a) Use state variables x1=y and x2=x1. You can then write down the state equation as: x=Ax+Bx

A is a 2x2: matrix, x & x are 2x1, and B is 2x1 with (u) as the scalar input.

b) The part expresses the integrated difference of output y and desired output yd. this is expressed as x3=y—yd. Since x1=y, the equation will look like: x3=x1-yd. If this is included in the state equation form problem a), we get a 3x3 matrix (A) and 3x2 matrix (B) relating derivatives to the

state variables to input, u and yd. The matrix will look like:

(see attachment)

c) The goal is to create a controlier with a desired response by replacing the input u by —kx where k is a row vector of constants and x a column vector of states:

(see attachment)

We must first substitute —kx for (u) in the equation i = 31+ B11 and we are asked to find the values of k1_m that make the characteristic equation for this system match a desired

characteristic equation with roots -2,-3, and -4.

Given the roots the desired characteristic equation, we can write the characteristic equation as:

(s+2)(s+3)(s+4) and expand this formal to get s^3 + es^2 + fs + g where we need to find the values of e,

f & g.

https://brainmass.com/math/matrices/defining-matrix-equations-537853

#### Solution Summary

The expert writes a state question for a system. The matrix equations are defined.