lbl-srg / GenOpt

GenOpt - Generic Optimization program
http://simulationresearch.lbl.gov/GO
20 stars 14 forks source link

GenOpt - OpenModelica #9

Closed AHaumer closed 3 months ago

AHaumer commented 5 years ago

Hi, I'm using GenOpt to optimze Modelica model parameters comparing simulation results with measured trajectories, this works fine. On the Modelica side, I use Dymola - many thanks for the examples, I got my application running in pretty short time! Now I'm wondering how do I have to adapt GenOpt.ini to the usage of OpenModelica? Best regards, Toni

mwetter commented 5 years ago

@AHaumer Easiest is to modify https://github.com/lbl-srg/GenOpt/blob/master/cfg/batchSimulation.cfg (for Windows) or https://github.com/lbl-srg/GenOpt/blob/master/cfg/bashSimulation.cfg (for Linux). This configuration file will start a batch or bash file, that you can edit to start OpenModelica.

You should also modify the "ErrorMessage" entry to properly stop if the simulation has an error, see Section 11.1.2 in the GenOpt manual.

AHaumer commented 5 years ago

Thanks Michael, I'll try it!

AHaumer commented 3 months ago

Sorry for giving no feedback for such a long time ... Yes 2018/19 the issue was solved, I could start optimizations with Dymola and OpenModelica. Now (2024) Dymola is still working, OpenModelica has undergone some changes and stopped to work. I have a few questions to get it running again - but I think it's better to open a new issue.