Solver resets due to discrete signal at ps-simulink-converter

Hi!
Using the Solver Profiler with a fixed-step model (ode3) I get a lot of solver resets due to discrete signal at a "ps-simulink-converter".
The phyiscal system origins from the tangential speed from "Spatial Contact Force" block.
Is there a way to make this somehow coninuous to reduce solver resets and gain performance?

Réponses (1)

Steve Miller
Steve Miller le 12 Mar 2023
If you are simulating with a fixed step solver, I believe the solver profiler will report a solver reset at every step. I don't think you can eliminate them. If you simulate with a variable step solver, you should see fewer resets. If you see resets triggered at the input to your Simscape network where a discrete signal is driving a continuous system (Simscape), you could look at the First Order Hold block to eliminate the resets.
--Steve

5 commentaires

Thank you for your reply!
Unfortunately I can't switch to a variable step solver. So apperently I have to live with this limitation. Nevertheless I will have a look at the first order hold block in hope that this improves the performance.
The Simscape Multibody model will be always be treated as a continuous system by Simulink. When you use a fixed-step solver, solver resets must occur. The First-Order Hold block will only reduce the number of resets in a variable step simulation.
I believe you are trying to speed up your model. Based on what you describe, I do not see avoiding resets being the biggest help. If you can share your model, I might be able to give you some ideas to try.
--Steve
Exactly. The model needs a reduction of the computational cost.
For the general problem I already contacted the support. In the meantime I try to find the pitholes on my own.
What about the continuous/discrete thing: Does it make sense to
I can't share the model itself here due to company restrictions.
Dear Christian
Have you cleared the issue,I got the same issue as you. I built the vehicle air suspension model by multibody simscape , gas and fluid simscape for air spring and shock absorber ,the fixed time is 0.01 ms,if I set 0.1ms the model always show :
Nonlinear solver to advance time one step failed to converge due to Linear Algebra error. Failed to solve using iteration matrix.
So I can not speed up the modle simulation speed by fast fixed steps .
1 second model task costs my PC near 1 hour.
Would you please give me any suggestions.
Hi Justin,
I didn't really clear the issue. As Steve wrote it seems to be a kind of restriction of the fixed-step solvers. Since speeding up the model was/is my main concern I looked for other ways to achieve this.
Actually I'm unsure if I should mark the issue as "solved" or not. It's not really solved, but it seems it not really a solvable problem.

Connectez-vous pour commenter.

Produits

Version

R2022b

Question posée :

le 10 Mar 2023

Commenté :

le 18 Avr 2023

Community Treasure Hunt

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

Start Hunting!

Translated by