What is causing my algebraic loop?
이전 댓글 표시
I have a somewhat complex model utilizing the general blockset, Specialized Power Systems, and Simscape Electrical physical systems. I am receiving an error that I have an algebraic loop, containing blocks that contain persistent states, which are not allowed in algebraic loops. I have seen answers explaining that these blocks tend to be integrators, Stateflow charts, Matlab function blocks, and physical systems circuits. Of those things, I only have the physical systems circuit. The physical systems circuit contains capacitors which could count as "persistent states", but if that is the cause, I do not know the solution. The error message is copied below. Can anyone help me spot the cause of the error?
Edit: After digging further, the identified loop goes Voltage Measurement -> Gain -> Subtract -> Gain -> Controlled Current Source. The Controlled Current Source does not directly interact with the Voltage Measurement. I don't see loop here..
'Full_Model_2/Control/Voltage Loop/Solver Configuration' or the model referenced by it contains a block that updates persistent or state variables while computing outputs and is not supported in an algebraic loop. It is in an algebraic loop with the following blocks.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/powergui/EquivalentModel1/State-Space' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Converter 3/Voltage Measurement/do not delete this gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 3/Gain1' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Product' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1, 2) of 'Full_Model_2/Control/LM5170/Current Loop 3/Subtract' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 3/Gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 3/Saturation' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Converter 2/Voltage Measurement/do not delete this gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 2/Gain1' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1, 2) of 'Full_Model_2/Control/LM5170/Current Loop 2/Subtract' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 2/Gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 2/Saturation' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Converter 1/Voltage Measurement/do not delete this gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 1/Gain1' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/Vbus^UF/do not delete this gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/Voltage Loop/Solver Configuration' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (2) of 'Full_Model_2/Control/Voltage Loop/Solver Configuration' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (2, 3) of 'Full_Model_2/Control/Voltage Loop/Solver Configuration' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1, 2) of 'Full_Model_2/Control/LM5170/Current Loop 1/Subtract' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 1/Gain' are involved in the loop.
Component:Simulink | Category:Model error
Input ports (1) of 'Full_Model_2/Control/LM5170/Current Loop 1/Saturation' are involved in the loop.
Component:Simulink | Category:Model error
댓글 수: 4
James Tursa
2022년 1월 12일
Algebraic loop can sometimes be caused by feedback without a delay. I.e., feeding the output back as an input without any delay, essentially using the current state as an input to calculate the current state. You can sometimes fix this by adding a delay in the output that feeds back into the input.
Jamie Shaffer
2022년 1월 13일
Jamie Shaffer
2022년 1월 13일
편집: Jamie Shaffer
2022년 1월 13일
Ankit
2022년 1월 14일
if you can't share model, could you please share some screenshots? it would be easy to find out the root cause. Solution is already mentioned by @James Tursa
답변 (1개)
카테고리
도움말 센터 및 File Exchange에서 Choose and Parameterize Blocks에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!