I need help creating a loop.
古いコメントを表示
Our teacher asked us to create a loop that calculates sin(x) to nth number of terms.
our professor obviously doesnt know how to use matlab because he has not helped us at all.
can someone help with this? i want to learn and comprehend what is going on?
-sin(x) = x-(x^3/3!)+(x^5/5!)-(x^7/7!
-The calculation should stop when the magnitude of the last terms is less than .0000006, it should work for positive and negative values
-The function should return the estimate and number of terms required to get this accuracy
After___terms sin(__) is approximated to be_____.
3 件のコメント
C.J. Harris
2013 年 3 月 22 日
"our teacher asked us..."
So what have you done so far?
Azzi Abdelmalek
2013 年 3 月 22 日
What have you done so far?
Mark
2013 年 3 月 22 日
採用された回答
その他の回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Code Performance についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!