Comment

Comment by hazrmard

From the website:

> 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/

[2]: https://fmpy.readthedocs.io/en/latest/

[3]: https://openmodelica.org/

parent hazrmard 1 year ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton