## Fuel Truck

This example is a modified version of the RollingWheelSetPulling from the Modelica standard library in the mechanics/multiBody module. As in the original model, the force is a function of time and pulls the fuel truck in the x-direction and after 3 seconds in the y-direction, resulting in a turning motion.

The FMU requires the sloshing forces and torque vector, and as FMI 2.0 does not support fields, they are indexed by `f_in[1-3]`

and `t_in[1-3]`

. OpenFOAM computes sloshing forces and torque with the position and the orientation vector (roll pitch yaw) represented by the variables `pos_out[1-3]`

and `RPY_out[1-3]`

. Sloshing torque also needs the center of rotation that is already given with `pos_out[1-3]`

. The inputs and outputs in OpenFOAM are in the world coordinate system.

Comparison of the uncoupled simulation and the coupled simulation shows that the fuel truck in the uncoupled simulation moves slightly faster as the fuel mass of roughly 250 kg is not considered. This is underlined by plotting the position over time.

As the inertia of the fluid is also neglected, the truck in the uncoupled simulation turns faster:

The uncoupled simulation always predicts a sloshing force and torque of zero (see. FuelTruck_uncoupled.py) corresponding to a massless fluid.