I got this error while running a simulink model

3 views (last 30 days)
Hello!! Can you please help me fix it. I have tried to modify the error tolerances but it does not work

Answers (1)

Peter O
Peter O on 23 Sep 2020
You generally get this error when your simulation has an error that causes one of the states to grow exponentially until one of the derivative terms grows so large that it goes out of bounds (like 10^300). Alternatively, it might have turned into a NaN value. The integrator can't handle either condition, so it throws an error.
Typically there's a block which is miswired leading to an unwanted positive feedback loop or an accidental divide by zero condition. In rarer instances there can be an issue created from a fixed step solver trying to handle system dynamics faster than its minimum time resolution. To fix that one you can try reducing the timestep. I'd recommend you look through your state equations and the terms feeding into the integrator for something out of place. If you can't find it, consider attaching a View/Log to a few key signal wires by right-clicking on them and stepping through the simulation. Past those general tips, we'll need a little more information about your simulation to help.
  2 Comments
Freedom TSOKPO
Freedom TSOKPO on 23 Sep 2020
It's a model of quadcopter. I was provided the state equations to simulate.
Peter O
Peter O on 24 Sep 2020
Okay. It's the flight dynamics, I'm guessing? If you haven't solved it, can you post a screenshot of your model and the equations? My hunch is that something might need to be connected differently. What solver are you using?

Sign in to comment.

Categories

Find more on Event Functions in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!