Skip to content
Tactiverge

Textbooks/Robotics From First Principles/Chapter 7Lite (plain text) version

7Motion and trajectories

Version 1 · Technically checked (automated checks only) · 3 source lessons · 7 practice items

Text
All chapters and search
  1. 1. Sense, think, act
  2. 2. Actuators and drives
  3. 3. Vectors and frames
  4. 4. Rotations and transforms
  5. 5. Forward kinematics
  6. 6. Inverse kinematics
  7. 7. Motion and trajectories
  8. 8. Where am I? Drift, uncertainty and fusion

Introduction

Knowing the start and the goal is not enough: a robot must get there without jerking, overshooting or tipping its payload. A trapezoidal profile ramps speed up, cruises, then ramps down, so the area under the speed graph equals the distance. For an arm, every joint follows its own profile, timed so they all finish together; and moving in joint space is not the same as moving in a straight line.

Speed up, cruise, slow downarea = 1 m0.5 s1.5 s0.5 s0.5total 2.5 s
Figure 7.1. Speed up, cruise, slow down. A trapezoidal velocity profile for a 1 m move with top speed 0.5 m/s and acceleration 1 m/s²: a 0.5 s ramp up, 1.5 s at constant speed and a 0.5 s ramp down, 2.5 s in total. The shaded area equals the 1 m distance.

Explanation

This chapter is built from 3 School lessons. Each part below is the lesson's own explanation; open the lesson for its predict-and-discover activities.

7.1 Motion profiles: getting there smoothly

The fastest way from A to B is 'full speed, then stop'. Why does no real lift, robot or train move like that?

Linear interpolation

The simplest trajectory: x(t) = x0 + (x1 − x0)·(t/T) for 0 ≤ t ≤ T. Constant speed |x1 − x0|/T the whole way. It's perfect for planning where to be in the middle of a move, but at t = 0 and t = T the speed jumps instantly, which would need infinite acceleration.

The trapezoid

Accelerate at the limit a until reaching the speed limit v, cruise, then decelerate at a to stop exactly at the target. The speed-time graph is a trapezoid; its area is the distance. Position during the first ramp is ½at²; during the cruise, v²/(2a) + v(t − ta); during the final ramp, D − ½a(T − t)².

Triangles and beyond

Short moves never reach v: the trapezoid collapses to a triangle. And the trapezoid still has instant jumps in acceleration (jerk), felt as a small jolt; lifts and precision machines use S-curves that also limit jerk, at the cost of a little more time. The Elevator Build's planner shows that next step.

Derivation: Duration of a trapezoidal move
  1. Ramp up from rest at acceleration a to speed v: time ta = v/a, distance ½·a·ta² = v²/(2a).

  2. Ramp down is the mirror image: another v/a seconds and v²/(2a) metres.

  3. Cruise covers the rest, D − v²/a, at speed v, taking (D − v²/a)/v = D/v − v/a seconds. This needs D ≥ v²/a.

  4. Total: T = 2·(v/a) + D/v − v/a = D/v + v/a. The extra v/a, compared with D/v, is the price of smoothness.

  5. If D < v²/a there's no room to cruise: the profile is a triangle with peak speed √(D·a) and duration 2√(D/a).

Common mix-ups

  • Raising the speed limit always makes the move faster by the same proportion.
    ✓ T = D/v + v/a: for short moves the ramps dominate, and a higher v can barely help (or the move is a triangle anyway).
  • A trapezoidal profile is perfectly smooth.
    ✓ Its speed is continuous, but its acceleration jumps; S-curves smooth that too.

Open the full lesson: Motion profiles: getting there smoothly →

7.2 Joint-space trajectories: moving every joint together

A robot's shoulder must turn 90° and its elbow only 10°. If both run flat out, one finishes long before the other. Is that a problem?

Interpolate each joint

For a move from θ_start to θ_end over time T, each joint follows θᵢ(t) = θᵢ,start + (θᵢ,end − θᵢ,start)·s(t), where s(t) runs from 0 to 1. With s = t/T it's linear interpolation; with s from a trapezoid (normalised by D) every joint ramps smoothly, at once. All joints share one s(t), so they start and finish together.

The slowest joint sets the pace

Each joint has its own speed limit. With linear interpolation, joint i needs speed |Δθᵢ|/T ≤ vᵢ,max, so T ≥ max(|Δθᵢ|/vᵢ,max). Choose the largest of these times and slow the other joints to match. That's 'synchronised' motion: it looks deliberate and keeps the hand's path predictable.

Joint space vs task space

Joint-space moves are cheap and safe (no IK mid-move, no singular surprises), but the hand curves. Task-space moves interpolate the hand position in a straight line and solve IK at each step: needed for welding a seam or inserting a peg, but they can drive the arm into a singularity or a joint limit halfway. Controllers offer both.

Common mix-ups

  • Moving every joint in a straight line moves the hand in a straight line.
    ✓ FK is nonlinear; a straight line in joint space is usually a curve for the hand.
  • Each joint should move at its own top speed.
    ✓ Synchronised moves slow the faster joints so all finish together; otherwise the path is unpredictable.

Open the full lesson: Joint-space trajectories: moving every joint together →

7.3 Modelling rotating parts: x = L cos θ, y = L sin θ

A windscreen wiper, a crane jib and a robot's first link all trace the same shape. Which equation draws all three?

A link is a scaled unit circle

A link of length L at angle θ (from +x, anticlockwise) has its tip at x = L cos θ, y = L sin θ. It's the unit-circle point (cos θ, sin θ) stretched by L. If the pivot is not at the origin but at (px, py), add that offset: x = px + L cos θ, y = py + L sin θ.

Going back: angle from position

Given a tip position (x, y) relative to the pivot, the joint angle is θ = atan2(y, x) and the length is √(x² + y²). This is the seed of inverse kinematics: working backwards from where the tip is (or should be) to the angle that puts it there. atan2, not tan⁻¹, because joints swing through every quadrant.

How fast does the tip move?

If the joint turns at angular speed ω (rad/s), the tip moves along its circle at v = L·ω. Long links make fast tips: a 2 m crane jib turning at 0.5 rad/s moves its tip at 1 m/s. The tip's velocity points along the circle, perpendicular to the link: (−L ω sin θ, L ω cos θ).

Common mix-ups

  • x = L sin θ and y = L cos θ.
    ✓ With θ measured from the x axis, x uses cosine and y uses sine. (Swap them only if θ is measured from the y axis.)
  • Every point on a rotating link moves at the same speed.
    ✓ Speed is L·ω: points further from the pivot move faster.

Open the full lesson: Modelling rotating parts: x = L cos θ, y = L sin θ →

Worked examples

Motion profiles: getting there smoothly: example 1

D = 5.5 rad, a = 0.5 rad/s², v = 0.5 rad/s. Where is the joint at t = 6 s?

Solution

ta = 1 s, ramp distance 0.25 rad, T = 5.5/0.5 + 1 = 12 s. At t = 6 s it's cruising: 0.25 + 0.5 × (6 − 1) = 2.75 rad.

Joint-space trajectories: moving every joint together: example 1

A joint goes from 20° to 80° linearly over 3 s. Where is it at t = 1.2 s?

Solution

θ = 20 + 60 × (1.2/3) = 20 + 24 = 44°. Speed 20°/s throughout.

Modelling rotating parts: x = L cos θ, y = L sin θ: example 1

A crane jib 12 m long, pivoted 3 m above the ground, is raised to 40°. How high is its tip?

Solution

y = 3 + 12 sin 40° = 3 + 12 × 0.6428 ≈ 10.71 m. Its tip is 12 cos 40° ≈ 9.19 m out from the pivot.

Interactive figures

Figure 7.2 from Motion profiles: getting there smoothlyStart with D = 2 m, v = 1 m/s, a = 1 m/s² and check the 3 s prediction. Then shrink D until the trapezoid becomes a triangle: at what distance does that happen? Finally raise a: what happens to the trapezoid's duration as a gets very large?
Can't use the interactive? Read a description instead

The profile comparer plots position against time (top) and speed against time (bottom) for a constant-velocity move (dashed orange: speed jumps instantly) and a trapezoidal move (solid blue: speed ramps up, cruises, ramps down). The readout gives both durations, the ramp and cruise times, and both positions at the chosen time.

Interactive figure (online). Description: The profile comparer plots position against time (top) and speed against time (bottom) for a constant-velocity move (dashed orange: speed jumps instantly) and a trapezoidal move (solid blue: speed ramps up, cruises, ramps down). The readout gives both durations, the ramp and cruise times, and both positions at the chosen time.

Laboratory

Everything runs in your browser. No kit, nothing mains-powered. Simulations are simplified educational models.

Guided practice

Answers are checked on the server; wrong answers get a hint and another try. Signed in, solved items also count towards the source lesson.

Practice 1

A slider moves at constant speed from x = 10 cm to x = 50 cm in 4 s. Where is it at t = 1 s, in cm?

cm

Practice 2 · a fresh version every time

A joint follows a trapezoidal profile over 2.5 rad: it accelerates at 2 rad/s² up to 1 rad/s, cruises, then decelerates at 2 rad/s² to stop. How far has it moved at t = 1.1 s, in radians? (3 decimal places)

rad

Practice 3

With v = 2 m/s and a = 1 m/s², which move is too short to reach full speed?

Practice 4

Why don't robot controllers use pure constant-velocity moves between points?

Practice 5

Joint 1 moves 120° with a limit of 60°/s; joint 2 moves 45° with a limit of 30°/s. For a synchronised linear move, what is the shortest duration, in seconds?

s

Practice 6

A welding robot must follow a straight seam. Which trajectory type is needed?

Practice 7

A 0.6 m link turns at 2 rad/s. How fast does its tip move, in m/s?

m/s
  1. A slider moves at constant speed from x = 10 cm to x = 50 cm in 4 s. Where is it at t = 1 s, in cm? (cm)
  2. A joint follows a trapezoidal profile over 2.5 rad: it accelerates at 2 rad/s² up to 1 rad/s, cruises, then decelerates at 2 rad/s² to stop. How far has it moved at t = 1.1 s, in radians? (3 decimal places) (rad)
  3. With v = 2 m/s and a = 1 m/s², which move is too short to reach full speed?
    • D = 6 m
    • D = 4.5 m
    • D = 3 m
    • D = 8 m
  4. Why don't robot controllers use pure constant-velocity moves between points?
    • They're slower
    • They demand an instant speed change at start and stop: infinite acceleration and huge jolts
    • They can't reach the target
    • They use more electricity in cruise
  5. Joint 1 moves 120° with a limit of 60°/s; joint 2 moves 45° with a limit of 30°/s. For a synchronised linear move, what is the shortest duration, in seconds? (s)
  6. A welding robot must follow a straight seam. Which trajectory type is needed?
    • Joint-space linear interpolation
    • Task-space (straight hand path) with IK at each step
    • Either: they give the same path
    • Constant velocity in joint space
  7. A 0.6 m link turns at 2 rad/s. How fast does its tip move, in m/s? (m/s)

Engineering applications

  • Lifts

    A lift cabin follows a smoothed profile so passengers never feel a sudden lurch. Limiting acceleration, and how quickly acceleration changes, matters as much for comfort as the top speed.

  • Carrying liquids

    A robot carrying a cup of coffee limits acceleration so the liquid does not slosh over the rim. The trip takes slightly longer, and nobody gets wet.

Watch

Optional verified videos. Nothing loads from YouTube until you press play.

Why robots don't jump between poses, and how smooth time-scaling keeps velocity and acceleration sensible.

5 min 41 s · captions on YouTube · source

Nothing loads from YouTube until you press play.

  • Modern Robotics, Chapters 9.1 and 9.2: Point-to-Point Trajectories (Part 1 of 2) (Northwestern Robotics)

Chapter summary

  • Linear interpolation moves from start to goal at constant speed, with jerky starts and stops.
  • A trapezoidal profile ramps up, cruises and ramps down; distance is the area under the speed graph.
  • Short moves never reach top speed and become triangular profiles.
  • Synchronising joints means timing every joint's profile to finish together.

Glossary

Equations of uniform acceleration
When acceleration is constant, displacement, initial velocity, final velocity, acceleration and time are linked by four short equations.
Linear interpolation
Linear interpolation estimates a value between two known points by assuming a straight line between them.
Radians and degrees
A radian is the angle at which the arc length equals the radius. A full turn is 2π radians, which is 360 degrees.

Definitions from the Field Guide.

Project: A gentle delivery

A robot must carry a tray 3 m across a room in under 8 seconds without exceeding an acceleration of 0.5 m/s². Design a trapezoidal profile that meets both limits, plot speed and position against time, and show the distance under the speed graph is 3 m.

Deliverables

  • The profile parameters with working
  • Plots of speed and position against time
  • A check that every limit is met

Keep your work in your Engineering Journal; it stays private unless you choose to share it.

References

  • Kevin M. Lynch and Frank C. Park (2017). Modern Robotics: Mechanics, Planning, and Control. Cambridge University Press.
  • Mark W. Spong et al. (2006). Robot Modeling and Control. Wiley.

Further reading from the source lessons

Publication record

Version
1
Status
Technically checked (automated checks only)
Technical review
Automated checks only, last run 2026-11-29. No human, educator or mentor review is claimed.src/content/textbooks/textbooks.test.ts: schema, every lesson, diagram, practice item, video, Field Guide entry, lab and reference resolves; figure numbers recomputed; no practice answers in client payloads.
Written by
Compiled and written by the Tactiverge team with AI assistance, from Tactiverge School lessons that were themselves written with AI assistance.
Licence
All rights reserved by the founders unless a licence is approved.
Corrections
None recorded yet.Spotted a mistake? Use “Report a problem” on any chapter, or see the corrections page.