DiscoverLearnDocumentationGet OpenPLXSearch Contact

Concepts System and Environment

This concepts page focuses on setting up simulation scope:

  • creating a Physics3D.System
  • structuring nested systems
  • configuring environment-related model parts
  • connecting model context to runtime usage

Physics3D.System

OpenPLX is developed mainly for authoring mechanical systems, as machines, and simulation environments.

A Physics3D.System may have own an arbitrary number of sub-systems, rigid bodies, geometries and visuals.

Nested systems

A system has a local frame of reference, which is configured by the local_transform attribute. The system will always be local to its parent system.

Frame is Physics3D.System
Wheel is Physics3D.System

MotorCycle is Physics3D.System:
    front_wheel is Wheel
    rear_wheel is Wheel
    frame is Frame

Using the MotorCycle model you may for example model both a large and small motor cycle.

SmallMotorCycle is MotorCycle:
    front_wheel.local_transform.position.x: 0.1
    rear_wheel.local_transform.position.x: -0.1

LargeMotorCycle is MotorCycle:
    front_wheel.local_transform.position.x: 1.0
    rear_wheel.local_transform.position.x: -1.0

The local transform for any system, rigid body or geometry is by default the identity transform, and therefore the frame will end up in the origin. However, neither the wheel or frame systems have any defined geometry, visual or bodies, so we don’t see anything when loading this model.

Simulation.Environment

There are parameters that are fundamental for your simulation scenario, which should only be specified once. For example gravity is specified as:

SimulationScene is Simulation.Environment:
    gravity becomes Simulation.UniformGravitationalField:
        vector: Math.Vec3.from_xyz(0,0,-9.82)

The environment attributes are considered when loading the environment as the root system of your model.

OpenPLX is a work in progress. This draft version will evolve with user feedback and experience. We welcome your input and collaboration.
X