Im using a code to calculate when a satellite re-enters the atmosphere. I need the code to stop running after the satellites altitude goes below 100km. Is there a function i can use to do this?
古いコメントを表示
Im using a code to calculate when a satellite re-enters the atmosphere. I need the code to stop running after the satellites altitude goes below 100km. Is there a function i can use to do this?
回答 (2 件)
Nut
2017 年 3 月 21 日
Maybe the return function:
https://it.mathworks.com/help/matlab/ref/return.html
if altitude < 100
return
end
Star Strider
2017 年 3 月 21 日
0 投票
It depends on how you’re writing your code. If you’re using a differential equation solver, consider using the ‘event’ option. Otherwise, consider a while loop.
カテゴリ
ヘルプ センター および File Exchange で Reference Applications についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!