FixTheRobot Explore Robotics / Guidance, Navigation and Control / M8 / M8-L1

This lab works on phones, but writing code is much easier on a laptop.

Guidance, Navigation and Control · Guidance Laws · M8-L1 · Advanced

Hold the Survey Line in Wind

Bench log · Hopper on the test range

09:05. The survey vehicle flies its lines at 20 m/s and the customer wants them straight to within two metres. In a crosswind it drifts off, comes back, and wanders; the flight engineer has changed the look-ahead three times and each change fixed one thing and broke another.

You will see what the look-ahead does, rewrite the law to work on the ground track, and choose the look-ahead from the dynamics rather than by trial.

Your task

    Simulation
    solution.pyLoading Python…
    Ctrl+Enter runs
    What Python can I use?

    Plain Python 3 with the standard library and the course library gnckit (import gnckit as g: transfer functions and margins, state space and LQR, the Hopper model, quaternions, a convex solver). NumPy is not available in the browser. Your code runs in a background worker: an endless loop is stopped after a few seconds and the page stays usable. It runs in your browser and is never sent anywhere.

    Hints

    What this lab teaches

    Stage 1: the look-ahead law is a spring-damper on the cross-track error with natural frequency √2 V/L; a short look-ahead is stiff but the autopilot lag takes its damping, a long one is slow. Stage 2: the law acts on the ground course and the ground speed, not on the heading. Stage 3: the choice of L from the roots of the third-order cross-track polynomial.

    Grading evaluates the deviation and the return time of your choice in the crosswind step, compares your law with the exact one on hidden states, and your chosen look-ahead with the exact smallest one on hidden speeds and lags.

    Theory for this lab

    Guidance Laws labs

    1. M8-L1: Hold the Survey Line in Wind: this lab.
    2. M8-L2: Fly the Polynomial Descent

    Educational simplification: a straight line, a constant wind step, a first-order autopilot and a known ground velocity. Module 8 adds turns, the switching between legs and the vector-field alternative.

    Get the next lab

    Get notified when new robotics labs are released. One email per new lab, nothing else.