(no title)
hazrmard | 1 year ago
> Modelica is a high-level declarative language for describing mathematical behavior. It is typically applied to engineering systems...
We use Modelica quite a bit in HVAC industry. In my case (controls engineer), I can request FMUs of various components from systems engineers for optimization work. (Functional Mockup Unit (FMU)[1]: stand-alone binary representing a dynamical system that can be driven by another application). My background is in Reinforcement learning/Model predictive control/python. Having a physics-driven model written in a domain-specific language which I can embed into my python workflow [2] is convenient.
I will say, Modelica requires a different perspective from "regular" imperative programming (python/matlab). It is a declarative language: you define equations, variables, constraints for a system, regardless of order. The compiler decides how to run the simulation; which variables to solve first etc.
While OpenModelica[3] has come a long way towards making an open source implementation of the language standard, proprietary applications (Dymola) still have an edge in the industry.
[1]: https://fmi-standard.org/
alhirzel|1 year ago
[1] https://juliahub.com/products/juliasim
[2] https://news.ycombinator.com/item?id=26425659
[3] https://docs.sciml.ai/DiffEqDocs/stable/
auxym|1 year ago
wolvesechoes|1 year ago
Still not comparable with Modelica that has proper specification, including graphical representation of models.
whereistimbo|1 year ago
hazrmard|1 year ago
Modelica is acausal. You define the variables and how they are related (equations). The compiler handles variable dependencies and resolution internally.
There are pros & cons of each. Both are used for simulating cyber-physical systems.
toxik|1 year ago
ETA: Apparently MathWorks has Simscape in this category.