"Initial conditions solve failed to converge" Error
16 views (last 30 days)
Show older comments
Hi guys, I tried to used simscape to solve a simple electrical circuit, but i got a trouble that i couldnt deal with. Can someone help me with this.
Here are the circuit and error:

An error occurred while running the simulation and the simulation was terminated
Caused by:
- ['untitled/Solver Configuration']: Initial conditions solve failed to converge.
- The model may not give enough information to make it possible to solve for values of some of its variables. Specific advice is given below. all components and nodal across variables involvedTie variable 'x5.p.v' (Voltage) to a definite value, for example by connecting an appropriate domain reference block. Equations of one or more components may be dependent or inconsistent. This can cause problems in transient initialization. Here is the set of components involved: all components involved'untitled/240V'Equation locations are: 'E:\MATLAB Folder\toolbox\physmod\simscape\library\m\+foundation\+electrical\source.ssc' (line 23) 'E:\MATLAB Folder\toolbox\physmod\simscape\library\m\+foundation\+electrical\+sources\dc_voltage.ssc' (line 15)
Thanks for your help!
0 Comments
Answers (1)
Shivam Lahoti
on 9 Jan 2025
Hi Tuan,
The error message indicates that Simscape is unable to solve your system, which can happen for several reasons. Often, it's due to abrupt transitions within your model. Here are some steps to help you resolve the issue:
1) Examine Sudden Changes: Look for abrupt changes or unexpected events, like a sudden pressure drop, that coincide with the error. This MATLAB Answers post might offer further insights.
2) Adjust Solver Settings: Consider changing your solver and increasing tolerances. For instance, if using 'Variable Step Auto', try switching to 'ode23t', and adjust tolerances from 1e-5 to 1e-3.For more information on solver selection visit the following documentation page.
3) Utilize the Solver Profiler: Use the Solver Profiler to analyze solver behavior just before the error. In the step size tab, you may notice a graph with a step size spike near the error time. Zooming in can reveal more details, like zero crossings. The following link contains more information on the Solver Profiler:
I hope this would help resolve the query.
Regards,
Shivam.
0 Comments
See Also
Categories
Find more on Simulation Setup in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!