Block 'untitled/单边磁拉力模块/Math Function1' outputs 'Inf' for element 1 of output port 1 at major time step 0.0009
20 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello! I have built a motor simulation circuit, and I encounter an error when running it, as shown in the image. I have been unable to find a solution. Could you please help me identify the problem and suggest how to resolve it? Thank you!
2 Kommentare
Sahas
am 16 Dez. 2024 um 4:37
Can you share your Simulink model? It would help me assist you better.
Antworten (1)
Sahas
vor etwa 2 Stunden
I was able to reproduce the error and as per my understanding, it is coming due to some numerical unstability or overflow. The solver cannot perform the computation because the value is either extremely large or extremely small. You can debug the model by setting a different step size and "Step Forward" the simulation to see the Port Values.
You can also try out the possible workarounds given below:
- Try out different Solver settings by opening the pressing "Ctrl+E" and opening the "Model Settings" pane. Select a more "stiff solver" such as ode15s, ode23s; reduce the relative error tolerance; reduce the maximum and minimum step size. Altenatively, you can also set all the parameters to "auto".
- Break your model into different parts and debug each part individually to see where the numerics go out of bounds.
- Resolve the Warnings first as the "Derivative" block could generate inf values.
Hope this helps you out!
0 Kommentare
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!