フィルターのクリア

Accuracy of Simulation time

3 ビュー (過去 30 日間)
Shrirang
Shrirang 2014 年 9 月 23 日
コメント済み: Shrirang 2014 年 9 月 23 日
Hi, I am facing an unexpected scenario while debugging. Sample time of my model is 0.002 (Discreet System). I am running a m file at each sample time in the background. following is my sample code. curTime is noting but current simulation time ----------------------------- if curTime == 1.400 a = 09; end ------------------------------ Now problem is after some time my simulation time is appearing as 1.40000000000000001 so if condition (if curTime == 1.400) is never getting satisfied. Can any body suggest a possible solution.

採用された回答

Sean de Wolski
Sean de Wolski 2014 年 9 月 23 日
  1 件のコメント
Shrirang
Shrirang 2014 年 9 月 23 日
Oh.. I got it !! I never thought i would face this. . Thank you ..

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

その他の回答 (0 件)

カテゴリ

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

製品

Community Treasure Hunt

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

Start Hunting!

Translated by