Please take a minute to review and accept our Terms of Use.
Welcome to the PLECS User Forum, where you can ask questions and receive answers from other members of the community.

Many technical questions regarding PLECS are answered on the Technical Solutions page of our website. Tutorial videos, specific application examples, and pre-recorded webinars are available on our YouTube page. Please follow us on LinkedIn for the latest Plexim news.

Can I change system's initial state via scripting?

0 votes
63 views
I have problems finding the steady-state of a converter using the steady-state analysis tool. In time domain my system reaches steady-state. Is it possible to save the state of a system using scripting and then re-run the time-domain analysis with that state? I do not see anything in SolverOpts variable.

Are there any good tips on how to setup the steady-state tool? I tried various combinations of start-time, init cycles but to no avail.
asked Apr 24 by owiecc (12 points)
Hello, I'll look into answers for your questions, but in the meantime, are you able to post a model that has the issue? Is your system periodic?
Thank you Kris. Yes, the system is periodic. There is a simple PI controller. If I run the time domain simulation I can reach the steady state fairly quick. I tried adding similar number of init cycles into the steady-state analysis tool in order to be as close to the steady-state as possible but it does not help.

1 Answer

0 votes
Hello,
Thank you for posting your model. With a DAB topology, I suppose the system itself is periodic, but I would actually expect the variable phase shift nature of the control scheme to prevent the Steady-State Analysis from providing a proper solution. I think that would be true even if you ran a transient simulation to steady-state conditions, then saved the system state, and then used that saved system state to run a future Steady-State Analysis. If, however, you don't actually need to use the Steady-State Analysis tool, but just want to start a transient simulation from a script where the initial state variables are assigned their steady state values, you can certainly do this from the Simulation > Simulation Parameters menu, in the Initialization tab of that window (it looks like you already were exploring this option as there is a previously saved state). You just need to select the "Stored system state" as the system state that the solver initializes from, which was not the case in your model. I hope this helps!

Regards,
Kris
answered May 2 by Kris Eberle (750 points)
I have two questions to your answer:

1. Within certain phase shifts limits the control should be fairly linear. Steady-state tool calculates the Jacobian to find the steady-state. If I provide enough init cycles to be close to the solution why would the tool fail? Are there specific conditions that prevent it from finding the solution? Is there a way to see the Jacobian matrix?

2. I know about the possibility to store the state and then restarting the analysis. However, is there a way to do it using built-in scripting or RPC call? If yes. then I can create my own "steady-state analysis". I just need to do some test with multiple operating points and the ability to store the state in a script would be super helpful.
...