Artificial Algebraic Loops

An artificial algebraic loop occurs when an atomic subsystem or Model block causes Simulink to detect an algebraic loop, even though the contents of the subsystem do not contain a direct feedthrough from the input to the output. When you create an atomic subsystem, all Inport blocks are direct feedthrough, resulting in an algebraic loop.

Start with the included model, which represents a simple proportional control of the plant described by

$$ G(s) = \frac{1}{s^2+2s+1}$$

which can be rewritten in state-space form as

$$
\dot{x} = \left[
 \begin{array}{cc}
 -2 & -1 \\
1 & 0
 \end{array}
 \right]
+ \left(
\begin{array}{c}
0\\1
\end{array}
\right)
$$

$$
y = \left[\begin{array}{cc}0&1\end{array}\right]
$$

The system has neither algebraic variables nor direct feedthrough and does not contain an algebraic loop.

Modify the model as described in the following steps:

  1. Enclose the Controller and Plant blocks in a subsystem.

  2. In the subsystem dialog box, select Treat as atomic unit to make the subsystem atomic.

  3. In the Diagnostics pane of the Model Configuration Parameters, set the Algebraic Loop parameter to error.

When simulating this model, an algebraic loop occurs because the subsystem is direct feedthrough, even though the path within the atomic subsystem is not direct feedthrough. Simulation stops with an algebraic loop error.