Reference Model and Algebraic loops
10 ビュー (過去 30 日間)
古いコメントを表示
Hello,
I've a main model including several reference models. If I try to run the simulation I get the error 'Algebraic loops are not supported in referenced models'. How can I solve this error? I need the reference models to test every model seperately without running the main model every time.
Where is the difference between Atomic subsystem, variant subsystem, subsystem reference and referenced model?
Thanks for your help!
0 件のコメント
回答 (1 件)
Deepak Meena
2020 年 9 月 25 日
Hi leonidas,
Basically, algebraic loops occur when an input port with direct feedthrough is driven by the output of the same block, either directly, or by a feedback path through other blocks which have direct feedthrough.
For ex :
Here y(t) = u(t) - y(t).
As you can see, the block can't just solve its output as it needs to compute it. Simulink detects instances such as these (i.e. algebraic loops) and solves them using an iterative loop. Simulink will compute the correct result in the above example, which is:
y(t) = u(t) / 2
But if the equation is like this y(t) = u(t) + y(t) , Simulink won't be able to solve this eequation and will throw error. One alternative is to use delay block which will store previous value.
-> Atomic Subsystem :Treat the subsystem as a unit when determining the execution order of block methods. For example, when it needs to compute the output of the subsystem, Simulink invokes the output methods of all the blocks in the subsystem before invoking the output methods of other blocks at the same level as the Subsystem block.
For variant Subsystem : https://www.mathworks.com/help/simulink/slref/variantsubsystemvariantmodel.html
For Referenced Subsystem : https://www.mathworks.com/help/simulink/ug/referenced-subsystem-1.html
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Subsystems についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!