Main Content

Trajectory Generation

Generate polynomial, B-spline, and trapezoidal trajectories

These functions use different mathematical equations for generating trajectories for manipulator robots. Polynomials, B-splines, and trapezoidal velocity profiles enable you to generate trajectories for multi-degree-of-freedom (DOF) systems. You can also interpolate between rotation matrices and homogeneous transformations.

The examples show different applications of trajectory execution including planning, control, and simulation for shape tracing and pick-and-place workflows.


expand all

contopptrajGenerate trajectory subject to kinematic constraints (Since R2022b)
minjerkpolytrajGenerate minimum jerk trajectory through waypoints (Since R2021b)
minsnappolytrajGenerate minimum snap trajectory through waypoints (Since R2021b)
trapveltrajGenerate trajectories with trapezoidal velocity profiles (Since R2019a)
cubicpolytrajGenerate third-order polynomial trajectories (Since R2019a)
quinticpolytrajGenerate fifth-order trajectories (Since R2019a)
bsplinepolytrajGenerate polynomial trajectories using B-splines (Since R2019a)
polynomialTrajectoryPiecewise-polynomial trajectory generator (Since R2023a)
rottrajGenerate trajectories between orientation rotation matrices (Since R2019a)
transformtrajGenerate trajectories between two transformations (Since R2019a)
waypointTrajectoryWaypoint trajectory generator (Since R2022a)


Polynomial TrajectoryGenerate polynomial trajectories through waypoints (Since R2019a)
Rotation TrajectoryGenerate trajectory between two orientations (Since R2019a)
Transform TrajectoryGenerate trajectory between two homogeneous transforms (Since R2019a)
Trapezoidal Velocity Profile TrajectoryGenerate trajectories through multiple waypoints using trapezoidal velocity profiles (Since R2019a)