Skip to content

Running SolarTherm via OMEdit

Ye Wang edited this page Aug 30, 2023 · 7 revisions

SolarTherm is working well with the OpenModelica tool OMEdit, a GUI-based tool for running Modelica simulations. There is not support for running financial calculations with OMEdit (those are so far implemented in Python as the st tools, see details here), but a full annual performance simulation is possible.

It is suggested that you use the instructions for Building SolarTherm on Linux or Running SolarTherm on Windows (MSYS2) to get OMEdit. On Ubuntu systems, after the installation steps, OMEdit can be found by the Ubuntu system menu. On Windows systems, OMEdit is available after the installation of OMEdit.

Firstly you need to get the latest SolarTherm package by

cd ~
git clone https://github.com/SolarTherm/SolarTherm.git solartherm
cd ~/solartherm

Then, open OMEdit and run it. When the GUI appears, select to open the SolarTherm 'package.mo' file (~/solartherm/SolarTherm/package.mo)

omedit-1

omedit-1

Then set the 'working directory' to the same location as above:

omedit-1

omedit-1

omedit-1

Now, in the SolarTherm item in the left panel, open Examples→Solar Tower→SystemAnalysis_startup:

omedit-1

The model file should open. You can click the little 'connections' icon above the source panel in order to view the model diagram:

omedit-1

At this point you should just be able to click the 'solve' button to run the simulation with the default parameters:

omedit-1

But we found that our current models require a little bit more configuration. Go to the solver configuration and choose the 'Simulation Flags' tab, then set the Non-Linear Solver to newton.

omedit-1 omedit-1 omedit-1 omedit-1

Having set that, you can run the simluation:

omedit-1

You will then be able to browse and plot calculation results.

Alternatively, you can run the Reference_1 model via terminal by the following command:

st_simulate --np=0 --solver=dassl --nls=newton Reference_1.mo