FFT resolution and RelaTol and AbsTol
3 次查看(过去 30 天)
显示 更早的评论
so my question is simple, I modeled an induction motor with an inter-turn short circuit i used a code not in Simulink, so i used ODE 45 with a linear vector tspan ('t_init:step:t_final'), so i noticed that when i increase RelTol (to 1e-3) and AbsTol (to 1e-8) i see new frequencies in my FFT that i dont see when i use tight tolerences like ('1e-6' ans 1e-10'), my question is why i see new frequencies (numerical noise ?), and what is the best solution to have more accurate results?
0 个评论
采纳的回答
Sulaymon Eshkabilov
2024-1-20
There are several critical points to consider here:
Numerical Noise. Higher tolerances of the ODE solvers may take larger steps, and in regions with rapidly changing dynamics; however, tighter tolerances may not capture the whole system behavior accurately. This can result in numerical noise and the appearance of spurious frequencies in the FFT.
To address the accuracy issues of numerical simulations:
(1) Refine a time step: Instead of drastically increasing tolerances, you might consider refining the time stepping in regions of interest. Consider a variable step solver that will take variable step algorithms which can automatically adjust the step size based on the local behavior of the system.
(2) Test Higher-Order Solvers, e.g. ODE113 and also, stiff solvers (e.g., ODE15s) which may be more suitable for stiff systems.
(3) Double-check Initial Conditions: In some unstable or very dynamic systems, small changes in initial conditions can lead to significant behavior changes.
All the best.
2 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Ordinary Differential Equations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!