Lagrange¶
New in v1.4 build a robot in the viewer: parts, meshes, sensors and power, then test it in a world →
Simulate the whole robot, not only its rigid bodies: its battery and motors, the heat in its parts, the air round its rotors, the weather on its sensors and the interference of its own wiring, together on the GPU. Switch any of them off.
Open source (Apache-2.0) · ROS 2 Lyrical on Ubuntu 26.04 · URDF, SDFormat, MJCF and USD as they are · a native Vulkan viewer · a deterministic CPU mode, bit for bit
Install in one command Measured against Gazebo The five-minute tutorial GitHub
1. Headless on a laptop (i9-13900H, RTX 4060 Laptop GPU), shared with other jobs, ±30 %: benchmarks §4–§5. 2. What is met and what is not: the validation report.
Against Gazebo, measured¶
Same scenes, same machine, headless, as fast as each goes; the median of five runs. The comparison has the method, the raw output, the physics accuracy, and where Lagrange is worse: a younger project, one platform, a slower camera here, many contacts on its MuJoCo backend.
Lagrange 1.3.0 |
Gazebo Jetty 10.5.0 |
|
|---|---|---|
AMR in a warehouse, physics only (real-time factor) |
96.6 |
14.8 |
The same with 2D and 3D lidars and an IMU |
54.1 |
12.7 |
One 640 × 480 camera at 30 Hz |
10.7 |
12.3 |
Start-up to the first step |
0.07 s |
2.4 s |
Peak memory, AMR with sensors |
78 MB |
961 MB |
What it simulates¶
MuJoCo or Jolt: contacts, joints, force-torque sensing.
Batteries, buses, motors and their drives at 100 µs; brown-outs and derating.
Lumped nodes, or conduction inside each part from its material.
Rotors, drag, wind and gusts, downwash, a GPU air box and an OpenFOAM link.
Fog, rain, snow and dust, and what they do to lidars, cameras and grip.
Power lines, a robot’s own wiring, compasses, CAN errors, radio links.
Tyres, suspension, powertrains; lanes, lights, crossings and people.
Buoyancy, currents and waves; tethers that sag, snag and tangle.
Why Lagrange¶
Turn any physics off. Every domain has a stand-in: an ideal motor, a constant ambient, ground-truth sensors, or a recording. Test your planner without the battery, or your battery without the physics.
Check every number. Each model is tested against a closed form, a published measurement or OpenFOAM, and the validation report says what is met and what is not. A measured comparison with Gazebo, MuJoCo and PyBullet says where others are better.
Bring your robot as it is. URDF, SDFormat, MJCF or USD; ROS 2 topics, ros2_control, Nav2,
MoveIt 2, PX4 and ArduPilot SITL work with it.
Same run, same answer. A deterministic CPU reference mode, bit for bit, beside the GPU paths; worlds tens of kilometres wide in double precision.
Try it¶
On Ubuntu 26.04 (amd64), one command installs ROS 2 Lyrical and Lagrange from the latest release; nothing is built (other ways to install):
curl -fsSL https://raw.githubusercontent.com/Open-Physical-Systems/Lagrange/main/packaging/install.sh | bash
Then:
source /opt/ros/lyrical/setup.bash
lagrange amr # the sample AMR in its warehouse, with the viewer
lagrange quad # a quadcopter that takes off and hovers
lagrange town # traffic lights, crossings, cars and people
or from Python, headless:
import lagrange
sim = lagrange.Simulation(lagrange.sample_robot(), world=lagrange.sample_world())
sim.step_until(2.0)
print(sim.read("body/base_link/pose"))
Where to go next¶
You want to |
Read |
|---|---|
See every robot and world |
Robots and worlds, and the feature videos |
Install it |
Installing Lagrange: from source, as debs or in a container |
Fly a drone, or test your own |
|
Load your own robot |
|
Build a robot in the viewer |
The robot builder: links, joints, sensors from the catalog, Test, save as URDF |
Find a sensor, add it, read it, break it |
Sensors: every sensor Lagrange simulates, by robot |
Drive a car, or run Autoware |
|
Heat, and a robot’s own EMI |
|
Know how a number is computed |
Physics reference: every model, its equations and its checks |
Extend it |