Skip to content

Latest commit

 

History

History
68 lines (46 loc) · 5.07 KB

File metadata and controls

68 lines (46 loc) · 5.07 KB

Modelica Libraries LogoModelica Libraries Logo

Modelica Standard Library

Free library from the Modelica Association to model mechanical (1D/3D), electrical (analog, digital, machines), magnetic, thermal, fluid, control systems and hierarchical state machines. Also numerical functions and functions for strings, files and streams are included.

Library description

Package Modelica is a free library that is developed together with the Modelica language from the Modelica Association. It is also called Modelica Standard Library. It provides model components and standard component interfaces from many engineering domains. Each model comes with documentation included. The generous license conditions allow usage in commercial products.

Note, the usage of a Modelica library requires a Modelica simulation environment, see the tools page, and that such an environment usually already includes the Modelica standard library. It is possible that the demo version of the commercial tools will not allow to simulate non-trivial examples from the library.

ModelicaLibraries

Building the external C libraries

CMake is recommended as build system, which usually consists of three steps for configuration, build and installation. For example,

git clone https://github.com/modelica/ModelicaStandardLibrary
cd ModelicaStandardLibrary
cmake -S ./Modelica/Resources -B .
cmake --build .
cmake --install .

The following Modelica Standard Library specific options for building with CMake are available.

  • MODELICA_BUILD_TESTING:BOOL=ON This flag enables the testsuite for CTest.
  • MODELICA_BUILD_ZLIB:BOOL=ON This flag enables the build of zlib dependency from source.
  • MODELICA_COPY_TABLE_DATA:BOOL=ON This flag avoids an undesired memory optimization of shallow-copying the passed table arrays.
  • MODELICA_DEBUG_TIME_EVENTS:BOOL=OFF This flag enables tracing of time events.
  • MODELICA_DUMMY_FUNCTION_USERTAB:BOOL=OFF This flag adds a dummy function "usertab".
  • MODELICA_INSTALL_EXTC:BOOL=OFF This flag also installs the ModelicaExternalC target.
  • MODELICA_SHARE_TABLE_DATA:BOOL=ON This flag enables the memory optimization of avoiding redundant copies of table arrays read from file.

Current release

Modelica Standard Library v4.1.0 (2025-05-23)

Older Releases

Browse the Releases page in order to get access to older releases of the Modelica Standard Library.

License

This Modelica package is free software and the use is completely at your own risk; it can be redistributed and/or modified under the terms of the 3-Clause BSD License.

Status

CI checks CLA assistant Modelica v4.1.0 regression test ModelicaTest v4.1.0 regression test

Development and contribution

The development is organised by the Modelica Association Project - Libraries (MAP-LIB). See also the contribution guide and the MAP-LIB Project Rules for more information.

You may report any issues by using the Issue Tracker.