Learning library
Linear algebra
Linear algebra is the working language of robots and learned models. These lessons build it from vector spaces up to rotations, Jacobians, and the singular value decomposition, with every idea tied to a motion or a measurement.
45 lessons, in library order. Search within linear algebra.
Start here
Transform coordinates and recover the input
Build the vector and matrix operations needed to express a robot measurement in another frame and check the way back.
- Vector spaces: build direction from addition and scaling
Describe displacements using coordinates, bases, and linear combinations.
- The dot product: angles, projections, and robot motion
Measure alignment and project a vector onto a direction.
- Matrix multiplication: calculate entries and compose transformations
Apply and compose transformations with explicit matrix shapes.
- Matrix transpose and inverse: when do they agree?
Distinguish rearranging entries from reversing a transformation.
- Coordinate frames: read the same point from a robot and the world
Convert a point between body and world coordinates, including translation.
- Rotation matrices: turn vectors, track frames, and check the order
Check a rotation's constraints and use its transpose to reverse it.
Foundations / 9 min read
Vector spaces: build direction from addition and scaling
Learn vector spaces through robot displacement. Explore span, linear independence, basis, and dimension with an interactive diagram, Python, and exercises.
Foundations / 9 min read
The dot product: angles, projections, and robot motion
Learn the dot product with an interactive vector diagram, a worked projection example, and a robot heading calculation. Includes exercises and solutions.
Foundations / 9 min read
Eigenvalues and eigenvectors: find the lines a matrix preserves
Understand eigenvalues through 2D transformations. Test stretching, reversal, zero eigenvalues, rotation, and repeated values, then connect them to robot error dynamics.
Foundations / 10 min read
Tensors: read shapes, select values, and move axes
Learn tensors through a robot image batch. Explore shape, indexing, slicing, and axis order, then compare reshape with transpose using a runnable Python example.
Foundations / 9 min read
Vector norms and normalization: L1, L2, and L∞
Measure vectors with L1, L2, and infinity norms. Explore unit boundaries, normalize a robot displacement, and distinguish zero vectors from tiny nonzero inputs.
Foundations / 10 min read
Matrix multiplication: calculate entries and compose transformations
Learn matrix multiplication through row-column dot products, compatible shapes, and a rotation-and-stretch experiment that shows why transformation order matters.
Foundations / 11 min read
Cross product: find a normal direction and calculate torque
Calculate a three-dimensional cross product, follow the right-hand rule, and connect its magnitude to area. Explore signed torque with a movable lever arm and force.
Foundations / 10 min read
Matrix transpose and inverse: when do they agree?
Transpose rectangular matrices, calculate a 2×2 inverse, and test when a transpose reverses a transformation. Explore rotations, reflections, and singular maps.
Foundations / 11 min read
Determinants: signed area, volume, and collapsed directions
Calculate a determinant, see how its sign records orientation, and connect zero area to singular matrices. Learn why a small determinant alone does not imply poor conditioning.
Foundations / 12 min read
Rank and null space: reachable outputs and hidden input changes
Use rank, column space, and null space to understand a linear map. Explore rank-nullity, unreachable targets, and families of solutions with a small matrix experiment.
Foundations / 10 min read
Projections and least squares: find the closest fit
Project a vector onto a direction, measure its orthogonal residual, and connect that geometry to least squares, regression, and nonunique coefficients.
Foundations / 12 min read
Singular value decomposition: directions, gains, and low-rank approximation
Build an SVD from orthogonal directions and nonnegative gains. See a circle become an ellipse, identify lost directions, and measure the error from keeping one singular component.
Foundations / 11 min read
Pseudoinverse: choose the smallest least-squares solution
Understand the Moore–Penrose pseudoinverse through exact and inconsistent systems. Separate residual error from solution norm, inspect projectors, and see how an SVD cutoff changes the problem.
Foundations / 10 min read
Coordinate frames: read the same point from a robot and the world
Convert a fixed landmark between robot and world coordinates. Learn frame conventions, translation and rotation, inverse transforms, and point versus displacement.
Foundations / 12 min read
Rotation matrices: turn vectors, track frames, and check the order
Build rotation matrices that preserve length and handedness. Compare fixed-axis rotations in 3D, distinguish rotating a vector from changing its coordinates, and undo a rotation with its transpose.
Foundations / 12 min read
Homogeneous transformations: map sensor coordinates into the world
Combine rotation and translation in one matrix. Follow a sensor-to-robot-to-world frame chain, distinguish points from displacements, and calculate the inverse.
Foundations / 10 min read
Euler angles and gimbal lock: when different angles mean the same orientation
Explore roll, pitch, and yaw with full rotation matrices. Compare equivalent orientations at ±90° pitch and separate Euler angle rates from angular velocity.
Foundations / 12 min read
Axis-angle rotation: build Rodrigues’ formula from three vector terms
Rotate a vector around any nonzero axis. Normalize the direction, follow Rodrigues’ parallel and perpendicular terms, and understand the equivalent descriptions at zero and 180 degrees.
Foundations / 12 min read
Unit quaternions: compose rotations and understand the sign
Rotate vectors with Hamilton quaternions, check composition order, and see why q and minus q describe the same orientation. Includes an interactive experiment and Python.
Foundations / 13 min read
Jacobian matrices: from joint rates to robot tip velocity
Read a Jacobian by its rows and columns, calculate a two-link arm's tip velocity, and compare a local prediction with a finite move. Includes singularities and the multivariate chain rule.
Foundations / 11 min read
Hessians: measure curvature in every direction
Differentiate a gradient to build the Hessian, calculate directional curvature, and classify stationary points. Explore coupled quadratics, saddles, and the limits of zero eigenvalues.
Foundations / 12 min read
Manifolds and tangent spaces: move along a constraint
Use the unit circle to understand local coordinates and tangent vectors. Compare straight steps, exact rotation, and normalization, then examine why averaging headings and rotations needs care.
Foundations / 13 min read
Geodesics: shortest arcs and longer routes on a circle
Compare a shortest circle arc, a longer constant-speed geodesic, and a straight chord. Work through angle wrapping, antipodal ties, coincident endpoints, and the metric that defines distance.
Foundations / 12 min read
Lie groups and Lie algebras: connect robot poses to local motions
Use planar robot poses to understand SE(2), its tangent space se(2), and the Lie bracket. Compare motion order, shrink a commutator loop, and reproduce the calculations in Python.
Foundations / 13 min read
Exponential and logarithm maps: turn a body twist into a pose
Exponentiate a constant planar body twist, calculate its coupled translation, and recover a chosen logarithm. Explore straight-motion limits, half-turn branch choices, and information lost in a full turn.
Foundations / 13 min read
Twists and screw axes: connect point velocities to rigid motion
Build a six-component twist from a screw axis, calculate point velocities, and compare exact helical motion with a tangent prediction. Separate pitch, accumulated displacement, current rate, and pure translation.
Foundations / 12 min read
Adjoint transformations: express a twist in another frame
Transform angular-first twists between body and space frames. Derive the origin-shift term, distinguish linear twist coordinates from point velocity, and check a planar example with an interactive adjoint matrix.
Foundations / 14 min read
Product of exponentials: build a robot arm’s forward kinematics
Build a two-joint arm's tool pose from fixed home screw axes and matrix exponentials. Check the result against geometry, inspect multiplication order, and connect space and body formulas.
Foundations / 14 min read
Wrenches: combine force, moment, and power across frames
Calculate a force's moment about a chosen origin, include a free couple, and transform a moment-first wrench between frames. Use a worked planar load to check the inverse-transpose rule and power invariance.
Foundations / 14 min read
Space and body Jacobians: map joint rates to rigid motion
Build space and body Jacobians from joint screw axes, recover the physical tool velocity, and compare their ranks with a position-only task. Explore a planar two-link arm and verify its derivatives in Python.
Foundations / 14 min read
Robot statics: turn tool loads into holding torques
Use virtual work and a Jacobian transpose to calculate a robot arm's joint loads. Distinguish external and holding torque, check space and body frames, and interpret zero-torque loads.
Foundations / 13 min read
Kinematic singularities: find the tip velocities an arm can produce
Use a two-link robot arm to distinguish exact rank loss from near-singular conditioning. Calculate the minimum-norm joint rates for a requested tip velocity and identify the component the arm cannot produce.
Foundations / 11 min read
Manipulability: read a robot’s velocity ellipse
Map a joint-rate budget into a robot’s possible tool velocities. Read the ellipse’s singular values, compare area with conditioning, and understand singular poses, units, and the limits of force duality.
Foundations / 14 min read
Numerical inverse kinematics: solve a tool position with local steps
Use a position Jacobian and damped least squares to refine a two-joint arm toward a target. Inspect accepted steps, compare starting guesses, and distinguish convergence, a stalled solve, and unreachable geometry.
Foundations / 14 min read
Differential inverse kinematics: turn a tip-velocity command into a joint step
Calculate damped joint rates for a robot tip-velocity command, measure the resulting speed and direction error, and compare an instantaneous prediction with one finite joint step.
Foundations / 12 min read
Kinematic redundancy: use the motion a task leaves free
Split a three-link arm’s joint rates into a primary solution and null-space motion. Check the exact projector, compare damping leakage, and measure why a finite step can move a tool with zero initial velocity.
Foundations / 12 min read
Joint limits in inverse kinematics: solve a bounded velocity step
Turn physical joint ranges and speed limits into bounds on a local inverse-kinematics command. Compare a constrained least-squares solution with clipping, and check the resulting finite arm position.
Foundations / 13 min read
Analytical inverse kinematics: find both arm configurations for a target
Derive both joint-angle solutions for a two-link robot arm, check them with forward kinematics, and identify unreachable targets and merged boundary branches.
Foundations / 11 min read
Robot workspaces: derive the reachable position set
Derive the exact position workspace of a two-link robot with elbow limits. Test targets against its annulus, recover a valid arm configuration, and separate position reach from orientation and path feasibility.
Foundations / 13 min read
Configuration space: follow joint paths across angle boundaries
Represent a robot arm as a point in joint space, follow paths across periodic angle boundaries, and distinguish angular distance from workspace motion and collision clearance.
Foundations / 11 min read
Collision checking: test the motion between endpoints
Check a translating disk against a circular obstacle, including every point between its endpoints. Derive the closest-point test, expose missed samples, and distinguish broad-phase box overlap from a collision.
Foundations / 13 min read
ICP algorithm explained: align two scans step by step
Learn how ICP aligns two point sets. Step through the lab, download the same data and Python solver, and compare a correct fit with misleading residuals.
Foundations / 10 min read
Covariance and uncertainty ellipses: read the shape of error
Read a covariance matrix as a geometric description of spread. Rotate an uncertainty ellipse, compare a Gaussian model with a finite sample, and calculate what a 95% contour means.
Foundations / 9 min read
Lyapunov stability: prove convergence with a function
Build a Lyapunov function, check its derivative, and prove convergence. See why a failed candidate can coexist with a stable system.
Foundations / 10 min read
Multivariable control: manage coupling between outputs
Move one output without disturbing another. Compare independent feedback with matrix decoupling, then test model mismatch and large actuator commands.