The JModelica.org platform consists of a number of different parts:
The compiler front-ends (one for Modelica and one for Modelica/Optimica) transforms Modelica and Optimica code into a flat model representation. The compilers also check the correctness of model descriptions and reports errors.
The compiler back-ends generates C code and XML code for Modelica and Optimica. The C code contains the model equations, cost functions and constraints whereas the XML code contains model meta data such as variable names and parameter values. Export of Functional Mock-up Units (FMUs) is supported. There is also the option to export flattened Modelica models, including equations, in XML format.
The JModelica.org runtime library is written in C and contains supporting functions needed to compile the generated model C code. Also, the runtime library contains an integration with CppAD, a tool for computation of high accuracy derivatives by means of automatic differentiation to provide derivatives for optimization algorithm. The runtime system also contains the functions provided in the FMI API.
Currently, JModelica.org features four different algorithms for solving dynamic optimization problems. There are three different algorithms based on direct collocation, which rely on the solver IPOPT for obtaining a solution to the resulting NLP. The default algorithm is encoded in C and relies on CppAD for computing the NLP derivatives. The other two algorithms are developed in Python and rely on CasADi for computing derivatives. There is also a derivative free optimization algorithm for model calibration based on measurement data that is applicable to FMUs.
JModelica.org uses Python for scripting. For this purpose, JModelica.org provides a number of different Python packages. The Assimulo package provides integration with state of the art DAE and ODE solvers (including the SUNDIALS suite), PyFMI provides FMU import, whereas PyModelica interacts with the JModelica.org compilers. Finally, PyJMI contains drivers for the optimization algorithms. All packages are available as part of JModelica.org, and Assimulo and PyFMI are also available as stand alone Python packages from www.assimulo.org and www.pyfmi.org.