MATLAB: Is this the way to solve algebraic loops

algebraic loopssimulink

So far, I understand that to solve common algebraic loop problems, it´s enough to decouple the input/output direct feedthrough of every direct feedthrough block by adding a state variable between the input and the output. And, as far as I understand, this can be easily done with an IC block. Inserting this block is also equivalent to equip the direct feedthrough block with a state x that evolves like x(k+1)=x(k) (or \dot x=0), and to consider a switch of the output so that we have y=x at t=t0 and y=f(u) for t>t0, where x,u and y represent the state, the input and the output respectively). This is equivalent to force the output at the value of the IC block at t=t0, and the algebraic loop would be solved, isn’t it? But at this point, I would argue that it is possible to use any block for which you can set a initial condition/output (e.g. rate transition blocks for example), isn’t it? So, to solve an algebraic loop is enough to break it in just one point, right? Or there is more?

Best Answer

I agree that using a delay block or a memory block is a solution. Actually you can use a delay block with inherited sample time even for continuous-time systems. The result is the same. However, by doing that, you are modifying the system behavior, and my challenge is to find a way to solve algebraic loops without changing the system dynamics... is it possible or it is necessary to insert this small time delay? :-)