Link Search Menu Expand Document

Distributed co-simulation

libcosim can run distributed co-simulation which allows you to:

  1. Run multiple instances of a model even though the FMU only allows it to be instantiated once.
  2. Run FMUs that are not compatible with your OS or bitness.
  3. Parallelize the workload onto multiple computation nodes.

Distributed simulation is currently enabled through integration with the software proxyfmu. Both FMI 1.0 and FMI 2.0 for Co-simulation is supported.

See below for ways to load an FMU using proxyfmu.

    <Simulator name="FMU1"
    <Simulator name="FMU2"
    <ssd:Component name="FMU1"
    <ssd:Component name="FMU2"

When choosing localhost as the hostname and omitting the port, libcosim handles spawning new processes for the models to run. Just make sure that the proxyfmuexecutable is available. It could either be located in the current directory or in the directory of the executable that uses it (e.g. cosim or cosim demo app). However, it is also possible to run models on a different PC. To accomplish this, start proxyfmu_booter on the target PC with --port <arg> as an argument. Then supply the IP and port number to the configuration. proxyfmu should be located in the same folder as proxyfmu_booter.

The Demo Cases include configuration for distributed co-simulation with proxyfmu, and this section shows how it’s done with the cosim demo app.

Copyright © 2020 DNV GL AS, Kongsberg Maritime CM AS, SINTEF Ocean AS and NTNU