Position describes where a robot is; heading describes the direction it faces.
A command such as forward depends on heading. State the coordinate convention before tracing movement so different readers can reproduce the same route.
The bigger picture
Motion planning depends on a representation of position and the environment. A planned path is not proof that a robot followed it. Wheel slip, measurement error and changing obstacles can produce a different physical result.
- Represent position
- Plan motion
- Measure result
- Correct error
Concepts to keep close
- Pose
- An object's position and orientation in a defined reference frame.
- Odometry
- Estimating motion from measurements such as wheel movement.
- Feedback control
- Adjusting actions using measurements of the resulting state.
Reasoning through the problem
Define north as increasing y for this exercise.
Record both position and heading.
Trace turns separately from forward movement.
Use the idea carefully
Specify coordinate conventions and units. Trace a short path, compare the expected and observed position and investigate discrepancies. Test boundaries and changed obstacles in simulation. Keep a defined stop condition and do not infer physical safety from a successful path animation.