MATLAB Answers


How to solve algebraic loop error??

Asked by Vidya
on 23 Nov 2012
Latest activity Commented on by matham kiran kumar on 3 Aug 2019
Hii....I came across this error while making a model..
Simulink cannot solve the algebraic loop containing 'trial_3/PV panel/PV module' at time 0.0 using the TrustRegion-based algorithm due to one of the following reasons: the model is ill-defined i.e., the system equations do not have a solution; or the nonlinear equation solver failed to converge due to numerical issues. To rule out solver convergence as the cause of this error, either a) switch to LineSearch-based algorithm using set_param('trial_3','AlgebraicLoopSolver','LineSearch') b) reducing the VariableStepDiscrete solver RelTol parameter so that the solver takes smaller time steps. If the error persists in spite of the above changes, then the model is likely ill-defined and requires modification.
I am using coding to make photovoltaic panel and MPPT P&O algorithm.
Please help me to solve this error.


i have the same problem!! :(
Have you done this, can you please suggest how you solved this issue.I am also coding for same.

Sign in to comment.


5 Answers

Answer by Azzi Abdelmalek
on 23 Nov 2012
Edited by Azzi Abdelmalek
on 23 Nov 2012

Algebraic loop occurs often, when you have a feedback through a constant block or equivalent, which means your signal y(t0)=constant * y(t0) , you should have y(t0+1)=constant*y(t0) which you can get with a unit delay block


Thanks@VAzzi Abdelmalek it works
Same issue. Where should I place the unit delay? Someone, please comment. Thank you.
Same issue, thanks for helping ...

Sign in to comment.

Answer by Kalyani Dhawad on 6 Sep 2018

I have same problem in pv system


Sign in to comment.

Answer by Ahmed
on 19 Jun 2019

I've faced the same problem before, it can be solved by adding a unit delay block and type "set_param('trial_3','AlgebraicLoopSolver','LineSearch') " in the command prombit window of MATLAB.

  1 Comment

Thank you. Its working for me too.

Sign in to comment.

Answer by Gert Kruger on 27 Jun 2019


Sign in to comment.