# States transformation of the bilinear transform

I have used the bilinear (or tustin) transform for a while, have been though the derivation of it and also through the concept of frequency warping.

Something that I still not understand that is stated in some places, for example in the Matlab documentation of the continuous to discrete conversion methods, is that the "states are not preserved" (with respect to the original continuous time states). It shows the relation:

$$w[kT] = x[kT] - \frac{T}{2} \left( Ax[kT] + Bu[kT] \right)$$

Where this expression comes from and why are the states not preserved?

## 1 Answer

The Tustin approximation is concerned with transfer functions, i.e. relations between inputs and outputs. In state space representation

$$\dot{\mathbb{x}}(t) = A \mathbb{x}(t) + B \mathbb{u}(t)$$ $$\mathbb{y} = C \mathbb{x}(t) + D \mathbb{u}(t)$$ for continuous time

or $$\mathbb{w}[(k+1)T] = A \mathbb{w}[kT] + B \mathbb{u}[kT]$$ $$\mathbb{y}[kT] = C \mathbb{w}[kT] + D \mathbb{u}[kT]$$ for discrete time

The $$\mathbb{y}$$ variables will be consistent, $$\mathbb{x}$$ will not be the same as $$\mathbb{w}$$.

## Relation between state space representations

If you want all the poles in the continuous time to be mapped to the poles in the discrete time representation in the positions given by $$(1 + sT/2)/(1-sT/2)$$ you could set

$$A_d = (I - A_c T/2)^{-1}(I + A_c T/2)$$

Then ever eigenvector of $$A_c$$ associated with an eigenvalue $$\lambda$$ is an eingenvector of $$A_d$$ associated with an eigenvalue $$(1 + \lambda T/2)/(1-\lambda T/2)$$.

One way to match the state space of the discretized system is to choose $$B_d = \left(\frac{T}{1-sT/s}\right)(1 - A_c T / 2)^{-1}B_c$$

So that

$$\begin{eqnarray} x(z)/u(z) &=& (z I - A_d)^{-1}B_d \\ \\ &=& \left(z I - (I - A_c T/2)^{-1}(I + A_c T/2) \right)^{-1}(1 - A_c T / 2)^{-1} \left(\frac{T}{1-sT/s}\right) B_c \\ \\ &=&\left(z (I - A_c T / 2) - (I + A_c T/2) \right)^{-1} \left(\frac{T}{1-sT/s}\right) B_c \\ \\ &=&\left(\left(\frac{1+sT/2}{1-sT/2}\right) (I - A_c T / 2) - (I + A_c T/2) \right)^{-1} \left(\frac{T}{1-sT/s}\right) B_c \\ \\ &=&\left(\frac{(1+sT/2)(I - A_c T / 2) - (1-sT/2)(I + A_c T/2)}{1-sT/2} \right)^{-1} \left(\frac{T}{1-sT/s}\right) B_c \\ \\ &=&\left(\frac{(s I - A_c) T }{1-sT/2} \right)^{-1} \left(\frac{T}{1-sT/s}\right) B_c \\ \\ &=&\left(s I - A_c \right)^{-1} B_c \\ \\ \end{eqnarray}$$

Notice that this choice of $$B_d$$ depends on $$s$$, but if time is small it reduces to $$(1 - A_c T/2)^{-1} B_c$$, and this would be the best we could to make the discrete state to correspond to the continuous state.

### The matlab approximation

Apparently MATLAB is using a value that is half way between the two samples.

$$x(t + T_s/2) \approx x(t) + T_s \dot{x}(t) = x(t) + T_s (A x(t) + Bu(t))$$

I cannot say too much about their implementation.

• Yes I understand that for a dynamic system, a transfer function representation is unique while a state-space representation is not, due to the existence of similarity transforms. I.e. they all have the same input-output relation, while the internal states might change. But my question is where the expression given in the question comes from? Aug 12 at 8:32
• Hi, I was notified about this question, did you see that I updated the answer with the answer to your comment? they are approximating $x(t + T_s/2)$.
– Bob
Sep 13 at 9:01