Simulink/Matlab diference
5 ビュー (過去 30 日間)
古いコメントを表示
Hy Is there a way that I can use roots in simulink and get the same result as in matlab? Does simulink use a different compiler than matlab?(I use roots in a matlab embaded function in simulink and get different results than in matlab). Thank you.
2 件のコメント
Titus Edelhofer
2011 年 10 月 6 日
Hi Cosmin,
are the differences large (i.e., not "just" roundoff?). What results do you get?
Titus
採用された回答
Walter Roberson
2011 年 10 月 6 日
Simulink uses a different algorithm, and is documented as possibly returning the roots in a different order. So sort() the complex numbers and you should be fine to within roundoff limits (unless the polynomial was badly scaled.)
0 件のコメント
その他の回答 (0 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!