Real-time vehicle models have traditionally been simplified. A model with a few dozen degrees of freedom fits comfortably inside a 1 ms step, so that is what drives the simulator and the hardware-in-the-loop rig. Meanwhile, the chassis team’s offline models in Simpack or MSC Adams describe the same vehicle in far more detail. The result is two cars: the one the engineers designed and the one the driver and the ECU actually meet.
Multibody vehicle models with hundreds of degrees of freedom can now run in hard real time. That lets one detailed model serve the desk, the driving simulator and the test rig.
Where hundreds of degrees of freedom come from
A detailed vehicle model reaches that size quickly:
- Suspension links mounted on elastic bushings rather than ideal joints, so each link keeps all six degrees of freedom.
- Subframes, engine and transmission on compliant mounts.
- Flexible bodies such as frame rails, twist beams, anti-roll bars and the steering column, represented by their mode shapes.
- A driveline with compliant half shafts, propeller shaft and differentials.
- A steering system with column, intermediate shaft, rack and assist.
- Tire models with their own internal states for the belt and the contact patch.
- For trucks, a ladder frame, cab suspension and trailers, which multiply everything above.
These details carry the effects that simplified models miss: compliance steer, body and frame flex, driveline wind-up, and the way the vehicle responds over rough roads.
Why it is hard in real time
In hard real time, every step has a deadline, typically 1 ms, and the deadline has to be met on every step. A model that is fast on average but occasionally runs long is not a real-time model. Large multibody models make this hard in three ways. Stiff elements such as bushings and tires push toward small steps or implicit solvers. Implicit solvers iterate, and a varying number of iterations means a varying step time. And once the model is spread across several cores, exchanging data between them costs time as well.
How we make it fit
- Measure the worst case. Profile each subsystem across realistic maneuvers and rough-road inputs, and size the system to the longest step, not the average one.
- Bound the solver. Use fixed-step integration with a fixed or capped number of iterations, so the cost of every step is predictable.
- Partition the model. Split the vehicle into subsystems, such as axles, tires, driveline and steering, and run them in parallel on dedicated cores, exchanging a small, well-defined set of signals every step.
- Use more than one rate. Run stiff, fast subsystems at a higher rate and slower ones at a lower rate, instead of running everything at the rate the fastest part needs.
- Remove what does not matter. Truncate flexible-body modes above the frequency range of interest and simplify contacts that never engage, then check the result against the offline model after every change.
- Protect the cores. Run on a real-time operating system with the simulation cores isolated from interrupts and other processes, and start each step from a periodic timer or an external clock.
- Keep watching. Log cycle times and overruns on every run, so a rare spike shows up in the data and not as an unexplained jump in a test result.
Proving it is the same car
Real-time performance only matters if the model still behaves like the original. Run the same maneuvers through the offline model and the real-time version, compare the signals that matter for the application, such as wheel loads, steering torque, yaw rate and body accelerations, and agree acceptance limits with the vehicle team before the model goes onto a rig.
What it enables
- One vehicle model from engineering analysis to driving simulator to hardware-in-the-loop rig, with no separate real-time approximation to maintain.
- Drivers in the simulator who feel compliance, flex and driveline effects that a simplified model cannot reproduce.
- ECUs on hardware-in-the-loop rigs tested against loads and motions closer to the real vehicle.
Real-time platforms from several vendors can run Simulink, Simpack and Adams models alongside hand-written code, directly or as FMUs.