Normal tree to state-space
At long last, we consider an algorithm to generate a state-space model from a linear graph model. In the following, we will consider a connected graph with \(E\) edges, of which \(S\) are sources (split between through-variable sources \(S_T\) and across \(S_A\)). There are \(2 E - S\) unknown across- and through-variables, so that’s how many equations we need. We have \(E-S\) elemental equations and for the rest we will write continuity and compatibility equations. \(N\) is the number of nodes.
- Derive \(2 E-S\) independent differential and algebraic equations from elemental, continuity, and compatibility equations. - Draw a normal tree. 
- Identify primary and secondary variables. 
- Select the state variables to be 
 across-variables on A-type branches and
 through-variables on T-type links.
- Define the state vector \(\bm{x}\), input vector \(\bm{u}\), and output vector \(\bm{y}\). 
- Write an elemental equation for each passive element.1 
- Write a continuity equation for each passive branch by drawing a contour intersecting that and no other branch. Solve each for the secondary through-variable associated with that branch.2 
- Write a compatibility equation for each passive link by temporarily “including” it in the tree and finding the compatibility equation for the resulting loop. Solve each for the secondary across-variable associated with that link.3 
 
- Eliminate variables that are not state or input variables and their derivatives. The following procedure is recommended. - Eliminate all secondary variables by substitution into the elemental equations of the continuity and compatibility equations. 
- Reduce the resulting set of equations to \(n\) (system order) in state and input variables, only. If not elimination, use linear algebra. 
- Express the output variables in terms of state and input variables, using any of the elemental, continuity, or compatibility equations. 
 
For the electronic system shown, find a state-space model with outputs iL, Is, and vR2.
0. Linear graph model.
Coordinate arrows are given.
1a. The normal tree is shown on the linear graph.
1b.
| Primary variables: | VS, vC, iL, iR1, vR2. | 
| Secondary variables: | IS, iC, vL, vR1, iR2. | 
1c. State variables: vC, iL (system order n = 2).
1d. State, input, and output vectors: $$\begin{aligned} \bm{x} = \begin{bmatrix} v_C \\ i_L \end{bmatrix} \qquad \bm{u} = \begin{bmatrix} V_s \end{bmatrix} \qquad \bm{y} = \begin{bmatrix} i_L \\ I_S \\ v_{R_2} \end{bmatrix}. \end{aligned}$$
1e. Elemental equations.
| C | $\frac{d v_C} {d t} = \frac{1} {C} i_{C}$ | 
| L | $\frac{d i_L} {d t} = \frac{1} {L} v_{L}$ | 
| R1 | iR1 = vR1/R1 | 
| R2 | vR2 = iR2R2 | 
1f. Continuity equations.
| Branch | Equation | 
| C (con1) | iC = iR1 − iL | 
| R2 (con2) | iR2 = iL | 
1g. Compatibility equations.
| Link | Equation | 
| L | vL = − vR2 + vC | 
| R1 | vR1 = VS − vC | 
2a. Eliminate secondary variables from the elemental equations.
| C | $\frac{d v_C} {d t} = \frac{1} {C} \left(i_{R_1} - i_L\right)$ | 
| L | $\frac{d i_L} {d t} = \frac{1} {L} \left(-v_{R_2} + v_C\right)$ | 
| R1 | iR1 = (VS−vC)/R1 | 
| R2 | vR2 = iLR2 | 
2b. Eliminate non-state and non-input variables from the elemental
equations. In this case, iR1
and vR2
are the only variables remaining to eliminate, and they are already
expressed as state- and input-variables! (This doesn’t always happen,
but it does pretty frequently for relatively simple systems.)
| C | $\frac{d v_C} {d t} = \frac{1} {R_1 C} V_S - \frac{1} {R_1 C} v_C - \frac{1} {C} i_L$ | 
| L | $\frac{d i_L} {d t} = -\frac{R_2} {L} i_L + \frac{1} {L} v_C$ | 
2c. Write the state equation in standard form $$\begin{aligned} \frac{d\bm{x}} {d t} &= \begin{bmatrix} \frac{-1} {R_1 C} & \frac{-1} {C} \\ 1/L & -R_2/L \end{bmatrix} \begin{bmatrix} v_C \\ i_L \end{bmatrix} + \begin{bmatrix} \frac{1} {R_1 C} \\ 0 \end{bmatrix} \begin{bmatrix} V_S \end{bmatrix}. \end{aligned}$$
2d. Outputs in terms of states and inputs. $$\begin{aligned} i_L = i_L && I_S = i_{R_1} = (V_S - v_C)/R_1 && v_{R_2} = R_2 i_L. \end{aligned}$$ Note the sign for IS. This is because, for an across-variable source, we assume the through-variable flows in the opposite direction!
2e. Output in standard form. $$\begin{aligned} \bm{y} &= \begin{bmatrix} 0 & 1 \\ -1/R_1 & 0 \\ 0 & R_2 \end{bmatrix} \begin{bmatrix} v_C \\ i_L \end{bmatrix} + \begin{bmatrix} 0 \\ 1/R_1 \\ 0 \end{bmatrix} \begin{bmatrix} V_S \end{bmatrix}. \end{aligned}$$
Online Resources for Section 3.4
No online resources.