-
Notifications
You must be signed in to change notification settings - Fork 37
Home
The ExternalMedia library was initially developed by Francesco Casella and Christoph Richter in the year 2007, see this paper. The goal was (and still is) to provide a library which is plug-compatible with Modelica.Media but can use external code to compute fluid properties. Over time, support for the RefProp and CoolProp packages was added, mainly targeting Dymola 32-bit environments, with some attempts on OpenModelica. The structure of the library was also improved compared to the initial design, to overcome some problems with its use inside nonlinear implicit equations that stemmed from the original caching technique.
The library currently implements the Modelica.Media.Interfaces.PartialTwoPhase medium interface for pure fluids with one or two phases, e.g., refrigerants, organic fluids for ORC systems, supercritical CO2, cryogenic He and H2, etc. Support for single-phase mixtures was never implemented, because the Modelica.Media library already contains excellent ideal gas mixture models, that cover most application needs. However, the library could be extended to also support these medium models, if there are interesting use cases. Conversely, ExternalMedia will never be able to cover multi-phase mixtures, because that's beyond the scope of Modelica.Media. If you are interested in modelling these fluids, please contact [email protected] to discuss further options.
The development of ExternalMedia was stopped for a while, but is now being resumed on GitHub. Please refer to this website for all information, updates and latest releases. You may also contribute via pull requests (that would be best) or directly by asking me permission to push into the repository. When we'll make a release, that will also be cloned to the Modelica Association Github repository, but I would recommend you to refer to the original master branch on https://github.com/casella/ExternalMedia, to avoid delays in the updates. The old Modelica Association repository will become obsolete, and possibly deleted as soon as a new release is available on GitHub.
The workplan is the following:
-
update the C interface so that DLLs can be used instead of statically linked libraries; this will simplify the development by reducing the number of binaries that need to be compiled
-
interface to the CoolProp library via a DLL, so that one can update CoolProp independently of ExternalMedia (as long as the interfaces are not changed, which doesn't happen often). Currently the CoolProp source code is compiled together with ExternalMedia code, which is not a very flexible solution
-
make sure that the library works on Windows and Linux, 32 and 64 bits, at least using Dymola and OpenModelica
If you want to help contributing to the software development, please write to [email protected] ASAP - my C/C++ programming skills are a bit rusty and there is great need of young manpower. It would also be nice if you could volunteer for testing and/or porting of the library onto your specific environment of interest (i.e., combination of operating system and Modelica tool).