MATLAB Answers

Ismael
0

How to tell ode15s to change its max time step for a specific short time range?

Ismael
さんによって質問されました 2019 年 6 月 12 日
最新アクティビティ Ismael
さんによって コメントされました 2019 年 6 月 12 日
I have a dynamic system coded in Matlab and solved using ode15s, and it works fine except it is slow because of the system size. I must give the solver a small step size (say 1e-4) for a very short time (0.05 s - 0.1 s) when there is a chnge in the system network. The rest of simulation time (20 s) can be simulated with a step size 1e-1 and it gives a satisfactory result. Is there is any possibility to tell the solver to change its step size (max. step size) during this short time?
Thanks
Ismael

  0 件のコメント

サインイン to comment.

1 件の回答

回答者: Torsten
2019 年 6 月 12 日
 採用された回答

Integrate from 0 to 0.05, restart the solver and solve from 0.05-0.1, restart the solver and solve from 0.1 - 20. Every time you restart the solver, you can change the maximum step size.

  3 件のコメント

Ismael
2019 年 6 月 12 日
Thanks Torsten. For the initial values required to be provided to the solver for each running, what are the initial values for the second and third running?
Torsten
2019 年 6 月 12 日
The initial values of run "n" are the results for the last output time of run "(n-1)".
Ismael
2019 年 6 月 12 日
Thank you Torsten.

サインイン to comment.



Translated by