Supported Modelica and known limits
This page says what ModOnda runs, what it does not, and where the browser has limits. It is the page to read before you move a model over from another tool. Everything here is measured or read from the code; where nothing has been measured, the page says so.
What is checked, and how
Every example of the Modelica Standard Library (MSL) 4.1.0 is simulated and compared, signal by signal, with the reference results the Modelica Association publishes with the library. Those references were generated with Dymola. A signal matches when ModOnda's curve stays inside a tolerance band around the reference curve: a box of 0.2% of the time span by 0.2% of the signal's range, drawn around each reference point. The test follows the one the library's release process uses. Each example runs with the tolerance its reference was generated with.
| Result | Examples |
|---|---|
| Match the reference | 517 |
| Run to the end, but at least one signal leaves the band | 16 |
| Do not finish within the time limit | 1 |
| Total | 534 |
So "533 of 534 run to the end" means the model translated and simulated without stopping, and "517 match" means every compared signal stayed in the band. The first number is not a claim of correct results, and the second covers only the signals the library chose to compare. Models outside the MSL have no such reference; the checks for them are the regression tests of the project and your own comparison against another tool.
The comparison runs nightly in the project's own continuous integration, against a committed baseline that must not get worse. Modelica Standard Library has the details.
The examples that do not match
One does not finish. Modelica.Electrical.Spice3.Examples.Spice3BenchmarkFourBitBinaryAdder
hits the time limit of the test run.
Seven differ because the reference looks wrong. The evidence is in
the dispute notes: closed-form or converged solutions agree
with ModOnda, not with the reference. They are not counted as matches, and no tolerance was
loosened to make them match.
Fluid.Examples.AST_BatchPlant.Test.TankWithEmptyingPipe1, TanksWithEmptyingPipe1 and
TwoTanks; Electrical.Analog.Examples.Lines.CompareLineTrunks; the two
Magnetic.QuasiStatic.FundamentalWave machines IMC_YD and IMC_Transformer;
Blocks.Examples.DemoSignalCharacteristic.
Nine differ and are open. Electrical.Machines.Examples.InductionMachines.IMC_DCBraking,
Electrical.PowerConverters.Examples.ACAC.Dimmer_R and Dimmer_RL,
Fluid.Examples.BranchingDynamicPipes, ControlledTankSystem.ControlledTanks,
TraceSubstances.RoomCO2 and RoomCO2WithControls,
Mechanics.MultiBody.Examples.Elementary.PointGravityWithPointMasses2 and
Mechanics.Rotational.Examples.LossyGearDemo2. Most miss one or two signals out of many; the
roadmap lists the signals.
Language and library features
The feature table on the library page lists each feature with the examples that match and its known limits. The ones to know before you start:
wheninside a function is rejected, and abreakorreturnunder a run-time condition inside awhileloop is not supported.- Lookup tables from a
usertabC function and MATLAB v7.3 (HDF5) files are not supported. Tables from text, CSV and MATLAB v4, v6 and v7 files are. - A model that contains an FMU component cannot be exported as an FMU.
- Features with no row in the table, such as
expandableconnectors andhomotopy(), have not been measured against the library. They may work; this page does not claim them. - Fluid models: 15 of 23 examples match. The start-up transients of the bigger systems are the weak spot.
- Embedded C and the optimal-control export take a subset of the language.
delay(), 2-D tables,whileloops and clocked equations are rejected there, with a message that names the feature.
Libraries other than the MSL load by name or from a zip (see Libraries). They run as far as the language features above allow; there is no reference comparison for them.
What the browser limits
- Memory. A simulation runs in a tab, and a browser caps the memory of a WebAssembly page at 4 GB. A very large model can reach that. The tab then stops the run, and the workbench says so and offers Run on server.
- Run on server is part of Pro. It sends the model's own Modelica files and the simulation settings to the hosted engine, up to 256 KB of source. The stock libraries (the MSL and ModOnda's own) stay out of the upload because the server has them; an edited library file is sent. Your files are simulated in a temporary folder that is deleted after the run. The privacy notice has the full wording.
- Local engine. The
modonda serveprocess on your own computer has no such limit and uses every core. It is not published during the beta, so for now it is for people who build it. - Sweeps. Free accounts sweep up to 20 runs at a time. The runs go to a pool of workers in your browser, so a sweep is as fast as your computer.
Where your work is kept
The workbench has no account storage for models. Signing in identifies you for the Pro features and does not move your models to a server.
- Your own models (
MyModels.mo, from New model, Duplicate to my models and typing in the text view) are kept in this browser, in local storage. They stay until you clear the site's data. They do not follow you to another browser or computer. - Runs and their result curves are kept in the browser's IndexedDB: up to 300 unpinned runs, and at most 256 MB of them. Pinned runs stay.
- Libraries you install are kept in IndexedDB too.
- Other files you open (for example a
.mofile from disk) are not kept. Load them again, or copy what you need into your own models. - To keep a copy, use Save .mo in the text editor, or Save .zip in the File menu, which packs the open model with the files and resources it needs. Do this before clearing site data and before you rely on a model for real work.
Share links
A link from the Runs pane names the model and carries its parameter changes, the simulation
settings and the plotted variables. It does not contain the model text. It works for anyone
for a model from the MSL, the ModOnda library or an installed library the reader also has. A
model of your own stays in your browser, so the person you send the link to will not find it:
send the .mo file along. The workbench warns you when you copy a link to your own model.
Not published during the beta
The command line (modonda), the Python package and the VS Code extension are described in this
documentation but not published yet. That includes .mos regression scripts: they run through the
command line, not in the browser. Pages that depend on them carry a note at the top.
Coming from Dymola or OpenModelica
What opens as it is: standard Modelica 3.x source in .mo files and packages, the MSL 4.1.0
models, and result files in the Dymola .mat format that Dymola, OMEdit and DyMat read. What
differs: ModOnda has its own symbolic backend and solvers, so step counts, state choices and
the exact numbers of a stiff or chattering model can differ from the other tools, within the
tolerance of the run. Libraries that depend on features outside the Modelica language
are not covered; only the MSL has been measured.
If a model behaves differently from what you expect, the Structure and Debugger views show the states ModOnda chose and the equation behind every variable; they are the quickest way to see where two tools diverge.