System in the state space with differentiating links in feedback

102 Views Asked by At

My question is a copy of the following topic, but slightly reformulated:

Representation in state-space of a system with ideal and real differentiating links in feedback

There are two systems in the state space with an ideal and a real differentiator.

enter image description here

enter image description here

I wrote down the equation of the first system in "Mathematica" in the following form, but then I realized that this option is not correct.

nsys = NonlinearStateSpaceModel[
  x'[t] == D[Power[x[t], 2], t] + 0.01 Sin[10 t], x[t], u[t], x[t], t]
Plot[Evaluate@OutputResponse[{nsys, 1}, 0, {t, 0, 20}], {t, 0, 20}]

The question arose: is it possible to write down the equation of the above systems in the form:

$x'=Ax+Bu$

where $u = 0.01 sin(10 t)$

1

There are 1 best solutions below

3
On BEST ANSWER

As far as I can see it should be just

$$ \begin{align} \dot{x} &= u + \frac{d}{d t} x^2 \newline \dot{x} &= u + 2x \dot{x} \newline \dot{x} - 2x \dot{x} &= u \newline \dot{x}(1 - 2 x) &= u \newline \dot{x} &= \frac{u}{1 - 2 x} = \frac{0.01\sin(10 t)}{1 - 2 x} \end{align} $$


The second system can also be put into this form, but you will need two states instead of only one.

Set $G(s) = \frac{s}{T s + 1}$ and $y_d(s) = G(s) u_d(s)$ so that $u_d$ is the input to $G(s)$ and $y_d$ the output. Then you have

$$ \begin{align} y_d(T s +1) &= s u_d \\ y_d T s + y_d &= s u_d \\ T \dot{y}_d + y_d &= \dot{u}_d \\ \dot{y}_d &= \frac{1}{T}(\dot{u}_d - y_d) \end{align} $$

Set $x_d = y_d - \frac{1}{T}u_d$ to get rid of the input derivative and to get the state space form of $G$:

$$ \begin{align} \dot{x}_d &= -\frac{1}{T} x_d - \frac{1}{T^2} u_d \\ y_d &= x_d + \frac{1}{T} u_d \end{align} $$

Set $x_1 = x$ and $x_2 = x_d$ and note that $u_d = x^2 = x_1^2$ and $\dot{x} = \dot{x}_1 = u + y_d$. Put everything together:

$$ \begin{align} \dot{x}_1 &= \frac{1}{T} x_1^2 + x_2 + u \\ \dot{x}_2 &= -\frac{1}{T^2}x_1^2 - \frac{1}{T} x_2 \end{align} $$

In your case, $T = 1$ and $u = 0.01\sin(10 t)$ and the overall output of the system is $y = x_1$. In equations:

$$ \begin{align} \dot{x}_1 &= x_1^2 + x_2 + 0.01\sin(10 t) \\ \dot{x}_2 &= -x_1^2 - x_2 \end{align} $$