[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[TRNSYS-users] Calling TRNSYS from MATLAB with prescribed initial conditions



Hi,

I want to design an MPC controller for an energy system which is modeled in TRNSYS 18. I used Type 155 component to call a MATLAB script which includes an MPC algorithm.
In the MPC algorithm, I want to use the TRNSYS model as the prediction model in the optimization loop, so I want to call the TRNSYS model from MATLAB and run it for the next 24 hours with the prescribed initial conditions .
How can I do it? I could not prescribe initial conditions of TRNSYS components from MATLAB.

Buy the way, is there any better way to apply an MPC controller on a system simulated in TRNSYS?

Thank you very much in advance,

Best regards,
Amin