I am getting an error while running my simulink model.
3 ビュー (過去 30 日間)
古いコメントを表示
I have attached my simulink file below. Please help me resolve this. After running the simulation, I get the error :
- Transient initialization at time 4.871245920436393e-07, solving for consistent states and modes, failed to converge.
- Nonlinear solver: failed to converge, residual norm too large.
1 件のコメント
Rahul
2024 年 10 月 25 日
Hi @Anant, I was able to simulate the given model using a fixed-step solver (Model Configuration Parameters ctrl+e>Solver>Type) instead, you can modify the fixed-step size (Solver Details) according to the accuracy you desire.
回答 (1 件)
Rahul
2024 年 10 月 28 日
I understand that you are trying to simulate a Simscape model in MATLAB R2024a, where you are getting an error stating:
“Nonlinear solver: failed to converge, residual norm too large.”
This often happens when your model is too ideal and there is a sudden transition. In a hydraulic model, this could for example be that you have a flow without restriction and a sudden pressure drop.
In that case, the Simscape solver needs to go through the "transient Initialization" phase:
and the initial guess he has is too far from the results, consequently it fails to converge.
I was able to reproduce this issue in MATLAB R2024a, however the propagation delay parameter for 555 Timer block, when set sufficiently higher, like 1e-5 in your case, could avoid getting the specified error with a variable step solver, or instead using a fixed step solver with the desired step size for getting suitable accuracy.
To learn more about troubleshooting simulation errors & transient initialization, please refer to the below documentation:
- https://www.mathworks.com/help/simscape/ug/troubleshooting-simulation-errors.html
- https://www.mathworks.com/help/simscape/ug/how-simscape-simulation-works.html?searchHighlight=bql2kkl-2.html&s_tid=srchtitle_bql2kkl-2.html_1#bqoxlpd-1
Hope this helps!
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Electrical Systems についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!