AnyLearn
All lessons
Roboticsadvanced

Why Locomotion Is Not a Planning Problem

Walking is rhythmic, fast, and must survive disturbances no planner anticipated. The biological answer is a spinal circuit that generates rhythm without the brain, and it suggests a fundamentally different control architecture.

Updated · AI-authored, review-gated · how lessons are made

Not signed in: your progress and quiz score won't be saved.
Progress1 / 7

The problem planning handles badly

Robot motion is usually framed as planning. Given a start, a goal, and obstacles, search for a collision-free trajectory, then track it with a controller. Our path on motion planning builds exactly that machinery, and for a robot arm reaching for an object it is the right framing.

Legged locomotion fits it poorly, for four reasons.

It is rhythmic and open-ended. There is no goal configuration. Walking means producing a repeating pattern indefinitely, and a planner that computes a trajectory to a target has answered the wrong question.

It is fast. Ground contact events happen in tens of milliseconds. Replanning a full trajectory at that rate is expensive, and on the small processors that fit inside a robot leg, often infeasible.

It is unstable. A walking machine is falling forward continuously and catching itself. Disturbances are not exceptions to handle occasionally, they are the normal condition.

Contact makes the dynamics discontinuous. Every footfall is a discrete event that changes the equations of motion, which is exactly what smooth trajectory optimisation is worst at.

Animals solve all four effortlessly, and how they do it turns out to be architecturally instructive.

Full lesson text

All 7 steps on one page, for reading, reference, and search.

Show

1. The problem planning handles badly

Robot motion is usually framed as planning. Given a start, a goal, and obstacles, search for a collision-free trajectory, then track it with a controller. Our path on motion planning builds exactly that machinery, and for a robot arm reaching for an object it is the right framing.

Legged locomotion fits it poorly, for four reasons.

It is rhythmic and open-ended. There is no goal configuration. Walking means producing a repeating pattern indefinitely, and a planner that computes a trajectory to a target has answered the wrong question.

It is fast. Ground contact events happen in tens of milliseconds. Replanning a full trajectory at that rate is expensive, and on the small processors that fit inside a robot leg, often infeasible.

It is unstable. A walking machine is falling forward continuously and catching itself. Disturbances are not exceptions to handle occasionally, they are the normal condition.

Contact makes the dynamics discontinuous. Every footfall is a discrete event that changes the equations of motion, which is exactly what smooth trajectory optimisation is worst at.

Animals solve all four effortlessly, and how they do it turns out to be architecturally instructive.

2. Rhythm without a brain

The biological finding that reframed the problem is that the rhythm of locomotion is not generated by the brain.

It is produced by circuits in the spinal cord called central pattern generators, and the defining evidence is that they produce rhythmic output when isolated from both the brain and sensory feedback. The pattern is generated centrally, which is what the name records.

The architecture this implies is a division of labour, and it is the opposite of how robots are usually built.

The spinal circuit produces the rhythm and the coordination between limbs. It runs autonomously and fast, close to the muscles.

The brain does not specify joint trajectories. It sends comparatively simple commands: go faster, turn, change gait. A few descending signals modulate a pattern the spinal cord is already generating.

Sensory feedback adjusts and entrains the rhythm rather than driving it, so a disturbance shifts the ongoing pattern instead of requiring a new one.

Auke Ijspeert leads the Biorobotics Laboratory at EPFL, and is well known for work on central pattern generators and their use in robot control, at the intersection of robotics, computational neuroscience, nonlinear dynamical systems, and machine learning.

3. What a CPG buys you as a controller

Translating the biology into engineering terms, a CPG-based controller has five properties that address the four difficulties directly.

Dimensionality reduction. A quadruped has many actuated joints. A CPG reduces the command interface to a few parameters: how fast, which direction, which gait. That is what makes high-level control tractable, and it is why the brain does not need to know about individual joints.

Rhythm is intrinsic. The pattern continues without being recomputed. There is no trajectory to store, re-plan, or track.

Smooth modulation. Change the input slowly and the output changes smoothly, without discontinuities, which matters because commanding a jump in joint position damages hardware.

Robustness through limit cycles. This is the mathematically important one. A CPG settles onto a stable limit cycle, a periodic orbit that the system returns to after being pushed off. Disturbance rejection is a property of the dynamics rather than something a controller must detect and correct.

Natural feedback integration. Sensory signals enter as coupling terms that shift the rhythm, so ground contact information adjusts timing automatically.

That fourth property is worth dwelling on, and the next lesson makes it precise.

4. Two control architectures

The contrast is where the computation lives. Planning puts it in a high-level loop that must run fast enough to handle disturbances. The CPG architecture puts rhythm generation in a fast autonomous layer and reduces the high-level command to a few numbers.

flowchart TD
  A["Goal: move the robot"] --> B["Planning architecture"]
  A --> C["CPG architecture"]
  B --> D["Compute a full joint trajectory"]
  D --> E["Track it with a controller"]
  E --> F["Disturbance requires re-planning"]
  C --> G["High level sends a few drive signals"]
  G --> H["Oscillator network generates rhythm"]
  H --> I["Joint commands emerge continuously"]
  I --> J["Disturbance shifts the ongoing limit cycle"]

5. The lamprey and the salamander

The reason this line of work centres on two specific animals is worth understanding, because the choice was strategic rather than arbitrary.

The lamprey is a jawless fish that swims by propagating a wave of body undulation from head to tail. Its nervous system is simple enough to be studied thoroughly, and its locomotion is generated by a chain of coupled oscillators along the spinal cord. It is the clean model system for axial locomotion.

The salamander is the interesting case, because it does two things. In water it swims with a travelling wave much like a lamprey. On land it walks with a stepping gait, its limbs coordinated in a trot while its body bends in a standing wave.

One animal, one nervous system, two qualitatively different locomotion modes, with fast transitions between them.

That makes it the ideal test of a hypothesis about evolution and architecture: that the primitive swimming circuit was retained and extended with limb oscillators added later, rather than replaced.

Ijspeert's group models the CPGs of these lower vertebrates using systems of coupled oscillators and tests those models onboard amphibious robots, which is what makes the hypothesis falsifiable in hardware rather than only in simulation.

6. Why build the robot

A reasonable objection: if you have a mathematical model of a spinal circuit, why put it in a machine rather than simulating it?

The answer is that a robot is an experimental instrument, and it tests things simulation cannot.

Physics you did not model. A simulation contains the dynamics you wrote down. A robot is subject to real friction, real compliance, real fluid forces, and real sensor delay. A controller that works in simulation and fails on hardware has revealed that your model omitted something, which is information.

Interventions impossible in animals. You cannot cleanly delete a neural population in a salamander and observe locomotion. In a robot you can ablate any part of the controller and watch precisely what degrades.

Hypotheses about biology. This is the striking inversion. The robot is not merely an application of neuroscience, it is a test of it. If a spinal cord model produces salamander-like swimming and walking in hardware, that is evidence about how the animal works.

Ijspeert's robots are used to test hypotheses about locomotion in lampreys and salamanders, particularly the interplay between feedforward and feedback control, meaning between central pattern generators and reflexes.

7. Where CPGs fit among the alternatives

CPGs are one of several approaches to legged control, and being clear about the trade-offs prevents overselling them.

ApproachStrengthWeakness
Trajectory optimisationOptimal, handles constraints explicitlyExpensive, struggles with contact discontinuities
Model predictive controlRe-plans continuously, principledNeeds an accurate model and real-time solving
Reinforcement learningLearns behaviours hard to specifyData hungry, opaque, sim-to-real gap
Central pattern generatorsCheap, robust, few parametersNot optimal, weaker at deliberate footstep placement

The honest assessment is that CPGs are not optimal controllers. They produce a rhythmic pattern that works, not the best possible gait for a given terrain and energy budget.

Where they win is the combination of properties: extremely low computational cost, intrinsic robustness from limit cycle dynamics, few parameters to tune, and smooth behaviour under changing commands.

Where they lose is deliberate, precise foot placement. Stepping exactly onto a stone requires reasoning about where the foot will land, which is planning, and rhythm generation does not do it alone.

The practical picture in modern systems is layered rather than exclusive, and the final lesson returns to how these combine.

Check your understanding

The lesson ends with a 5-question quiz. Take it in the player above to see your score.

  1. What defines a central pattern generator?
    • A spinal circuit that produces rhythmic output even when isolated from the brain and sensory feedback
    • A planning algorithm that generates periodic trajectories
    • A brain region that computes joint trajectories for walking
    • A feedback controller driven entirely by ground contact sensors
  2. Why does trajectory planning fit legged locomotion poorly?
    • Legged robots lack sufficient sensors for state estimation
    • Joint angles cannot be measured accurately enough during contact
    • Locomotion is rhythmic and open-ended with no goal configuration, fast, unstable, and made discontinuous by contact events
    • Planning algorithms cannot represent periodic motions at all
  3. What does the limit cycle property give a CPG-based controller?
    • Guaranteed energy optimality for a given gait
    • Exact tracking of a commanded joint trajectory
    • The ability to change gait without changing parameters
    • Disturbance rejection as an intrinsic property of the dynamics rather than something a controller must detect and correct
  4. Why is the salamander the key model animal for this research?
    • Its nervous system is the simplest of any vertebrate
    • One nervous system produces two qualitatively different locomotion modes, swimming and walking, with fast transitions
    • It is the only animal whose CPGs have been fully mapped
    • Its limbs have the same degrees of freedom as a typical robot leg
  5. What is the main weakness of CPG-based control?
    • It requires more computation than model predictive control
    • It cannot produce smooth joint commands
    • It is not optimal and handles deliberate precise foot placement poorly
    • It cannot incorporate sensory feedback

Related lessons