I'm working on a Modelica compiler written in pure python that outputs a sympy model. Please let me know if anyone is interested in contributing.
Please see the jupyter notebook below for a quick overview of the current capabilities:
The useful thing about the modelica language is that it can all be mapped into one differential algebraic equation, that can be represented in certain cases well in sympy.
This allows one model in Modelica to be used to generate:
1. Sympy models for mathematical analysis/ simulation.
2. C/C++ code for embedded controllers/ estimators (to be done).
3. Whatever else you can dream up.
The compiler is very hack-able. I'm using jinja 2 for rendering the AST.
I'm using antlr4 python runtime to robustly construct the AST.
I really need some good python programmers to help me get to the point that the compiler can handle more language constructs and parse the entire Modelica standard library.
Feel free to contact me if you are interested: