GLOBAL KNOWLEDGE ARK

Robotics & Mechatronics · Simulation, models and reproducible tests

Build and check a minimal robot simulation model

A minimal robot simulation should answer a declared question. Start with enough links, joints, actuator and sensor definitions to test sign, scale and timing before trusting a complicated scene.

All numerical tables, scenarios and records are original constructed teaching data unless a specific external dataset is named. No physical experiment is claimed. A worked simulation model is distinguished from an executed simulator.

Lesson preparation and course links

Use the local explanations and supplied units, diagrams, tables and examples; advanced chapters build on the named local chapters. External links are point-of-need depth, not a requirement to finish an entire map.

Back to the Robotics chapter

After reading, you can

Describe links, joints, actuator and sensor interfaces with declared units and compare elementary responses against supplied calculations or observations.

01

Record a one-axis model

The original ideal model is a 1 kg horizontal mass, one linear coordinate x in metres, force input u in newtons, no friction, no gravity component along the rail, and a position output in metres. This is a mathematical test model, not validated hardware.

Record a one-axis model
ElementDeclaration
Coordinatex positive right; x=0 at model origin
Initial statex=0 m, v=0 m/s
Dynamicsa=u/m
InputApplied force u; separate from a position request
Outputx and v with simulation acquisition time
IntegratorNamed algorithm and step; not silently assumed exact
02

Choose independent expected results

Zero input with zero initial velocity predicts no motion. A positive 2 N input gives acceleration+2 m/s². With constant force for 0.10 s from rest, exact ideal velocity is 0.20 m/s and displacement½at²=0.010 m. Reversing force reverses acceleration; changing the force unit or mass changes the response.

These expectations come from the declared equation, not from reading the simulator’s own ground-truth display. Compare exported state against them. A model can be internally consistent while representing the wrong real robot.

03

Expose a time-step effect

A semi-implicit Euler step updates velocity first, then position using the new velocity. This table is an executed-arithmetic target for the stated algorithm, not a Gazebo result.

Expose a time-step effect
Step size / sSteps to 0.10 sFinal v / (m/s)Final x / m
0.1010.200.020
0.0520.200.015
0.01100.200.011
Exact ideal model—0.200.010
04

Test what the controller can actually observe

A simulator may expose exact model state that a physical robot cannot measure. If the controller is meant to use a sampled/noisy encoder, connect and test that sensor interface rather than substituting perfect state without declaring it. Record noise, bias, sampling, delay and validity models.

A robot description needs consistent joint types, axes, limits, inertial units and actuator mappings. A visually plausible scene does not establish those properties. Inspect zero/sign/scale tests before adding a supplied task sequence.

05

Separate model verification and validation

Matching the ideal arithmetic verifies this implementation against its stated model. Comparing a real configured axis with relevant observed data addresses model validity for that task. The first cannot replace the second. Link the canonical simulation/verification Engineering readings for deeper modelling principles.

Reproduce the two-step calculation

WithΔt=0.05 s and a=2 m/s², first v=0.10 m/s and x=0.10×0.05=0.005 m. Second v=0.20 m/s and x=0.005+0.20×0.05=0.015 m.

The exact displacement is 0.010 m, so this two-step algorithm overestimates by 0.005 m in the ideal case. Reducing step size improves this example, but does not prove every simulator converges or every model is physically valid.

Try the reasoning

  1. What does a zero-input drift test reveal?

    Show the answer and reasoning

    It can expose unintended initial velocity, force, gravity projection or integration/configuration defects; it does not uniquely identify them.

  2. Why not use perfect simulation state without declaring it?

    Show the answer and reasoning

    It can conceal sensor limitations and make software evidence unlike the intended hardware interface.

  3. Is matching 0.010 m sufficient to validate a real axis?

    Show the answer and reasoning

    No. That checks the stipulated ideal model; physical validity needs relevant observations.

  4. At 1 N on 1 kg from rest for 0.2 s, what is ideal displacement?

    Show the answer and reasoning

    ½×1×0.2²=0.020 m, with the stated frictionless constant-force assumptions.

What to carry forward

Verify a minimal model against independent simple calculations, then keep physical validation as a separate task.

References

Sources supporting this lesson’s explanations and examples.

  1. Gazebo Jetty: SensorsGazebo contributorsOfficial simulation tutorialJetty versioned documentationgazebosim.orgRead source
  2. Robotic Manipulation, Chapter 2: Let's get you a robotRuss TedrakeUniversity course working notes2020–2026 working notesmanipulation.mit.eduRead source