how do i change StepTolerance?

4 ビュー (過去 30 日間)
KIPROTICH KOSGEY
KIPROTICH KOSGEY 2019 年 10 月 24 日
コメント済み: KIPROTICH KOSGEY 2019 年 10 月 29 日
Hi,
Please i would like to write a code in matlab that changes the StepTolerance to 1E-20 but i do not know how to go about.
Please can someone assist, please..
This is my script:
y0=[0.02352;0.00048;0.0288;0.00432;0.216;0.1104;0.1104;2;2;2;55;50;0.5];
h=0.0006944444;
tSpan=[0 535];
options = optimoptions('StepTolerance', 1e-20);
[tSol, ySol]=ode23tb(@(t, y) MBBRFun4(t,y), tSpan, y0, options);
as it stands, i get the following error:
Warning: Failure at t=6.848966e-01. Unable to meet integration
tolerances without reducing the step size below the smallest value
allowed (2.433242e-15) at time t.
Thanks in advance

採用された回答

Dinesh Yadav
Dinesh Yadav 2019 年 10 月 29 日
Hi,
As I have attached an example code for changing step tolerance. Hope it helps your cause.
  1 件のコメント
KIPROTICH KOSGEY
KIPROTICH KOSGEY 2019 年 10 月 29 日
Thank you so much!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeProgramming についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by