The hull's turning response follows a first-order Nomoto maneuvering model, the standard linearized approximation used in ship-control engineering to relate rudder angle to yaw (turn) rate. An onboard PID autopilot compares true heading to the bearing toward the active waypoint and commands a rudder angle to null that error, exactly as a real autonomous surface vessel's guidance loop would.
Nomoto (1st order):
dr/dt = (K·δ − r) / T
dψ/dt = r
Autopilot (PID on heading error e):
e = wrap(bearing_wp − ψ)
δ_cmd = Kp·e + Kd·(de/dt), clamped ±35°
Position (with current drift c):
dx/dt = V·cos(ψ) + cx, dz/dt = V·sin(ψ) + cz
- Throttle — sets forward speed V, feeding the position-integration terms.
- Manual rudder — commands δ directly (ignored while autopilot is engaged).
- Sea state / current — scales wave-induced roll/pitch (simulated IMU accelerations) and the lateral current drift c.
- Autopilot — hands rudder control to the PID law above, steering toward the waypoint buoy.
- New waypoint — drops a fresh target and resets cross-track distance.
Real ASVs (autonomous surface vessels) fuse an IMU's roll/pitch/heading-rate output with GNSS position in exactly this kind of loop to hold a track safely through waves and current.