Skip to content

Modelica library for the Dynamic simulation of Thermal management Systems

License

Notifications You must be signed in to change notification settings

Propulsion-Power-TU-Delft/DynTherM

Repository files navigation

DynTherM


Description

A Modelica library for the Dynamic modeling and simulation of Thermal Management systems.

Applications:

  1. Aircraft fuselage

  2. Helicopter fuselage (to be adapted and ported to the new version of DynTherM)

  3. Hydrogen tank (under development)

  4. Battery pack (under development)


Author

  • A. Giuffré, Post Doctoral Researcher, Propulsion & Power, TU Delft

Link MailTo

Acknowledgements

  • C. De Servi, Senior Researcher, Propulsion & Power, TU Delft - Main Technical Advisor
  • I. Gul, PhD Researcher, Propulsion & Power, TU Delft - Battery Pack
  • M. Swart, MSc Student, TU Delft - Hydrogen Tank
  • K. Guimaraes, MSc Student, TU Delft - Helicopter Fuselage

Pre-requisites

Dymola 2022 (not tested with OpenModelica)
Python 3.9 (optional, only for Python - Dymola interface)
NumPy (optional, only for Python - Dymola interface)
sudo pip install numpy
MatPlotLib (optional, only for Python - Dymola interface)
sudo pip install matplotlib
pandas (optional, only for Python - Dymola interface)
sudo pip install pandas
tqdm (optional, only for Python - Dymola interface)
sudo pip install tqdm
SMARTS 2.9.5 (optional, only for Python - Dymola interface)

Citations

A. Giuffré, P. Colonna, and C. De Servi. "Dynamic Thermal Model of Passenger Aircraft for the Estimation of the Cabin Cooling and Heating Requirements", Applied Thermal Engineering, 244 (2024), doi:10.1016/j.applthermaleng.2024.122641


Setting Python - Dymola interface

The following instructions are tested for Python 3.7+ and Dymola 2022, assuming the Dymola installation folder to be the standard one.

  1. Add to Path (environment variable): C:\Program Files\Dymola 2022\bin64\Dymola.exe

  2. Create PYTHONPATH (environment variable), if not existing yet, and add: C:\Program Files\Dymola 2022\Modelica\Library\python_interface\dymola.egg

  3. Set package_dir in main.py as "path-to-package.mo (inside DynTherM)" according to your system directory; set model_dir accordingly

  4. Download SMARTS from NREL website and install it in the DynTherM root folder

    Upon completion of the previous steps, you should be able to run main.py from command line or python IDLE (remember to open the Dymola app before running main.py). The next step is only required to run main.py from PyCharm.

  5. Open PyCharm and go to File/Settings/Project Interpreter. At the top right, select show all, show paths for the selected interpreter and add: C:\Program Files\Dymola 2022\Modelica\Library\python_interface/dymola.egg


Improve convergence in Dymola

Go to Simulation, Setup, Translation and activate the option "Evaluate parameters to reduce models". This will allow the simulation of some models that otherwise do not converge. The reason for that still remains a mystery...


How to get started

  1. Load package.mo in Dymola

  2. Open and run one of the models in package Examples.mo

  3. Analyze the results

About

Modelica library for the Dynamic simulation of Thermal management Systems

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published