|
| chrono::ChFrame | dh_frame (const DHRow &row) |
| | \(R_z(\theta)\, T_z(d)\, T_x(a)\, R_x(\alpha)\)
|
| chrono::ChFrame | dh_fk (const std::vector< DHRow > &table) |
| | The product of the frames of all the rows: the pose of the last frame in the first.
|
| std::vector< DHRow > | spatial_dh_table (const SpatialArm &arm, const SpatialJoints &q) |
| | The Denavit-Hartenberg table of a SpatialArm at joint angles q. dh_fk of it is spatial_fk.
|
| chrono::ChFrame | joint_rotation (real_t q) |
| | The frame of a revolute joint turned by q [rad] about its z axis: a rotation, with no offset.
|
| ChVector3d | planar_fk (const PlanarArm &arm, const PlanarJoints &q) |
| | Where the tip is, written out with trigonometry: \(x = l_1 \cos q_1 + l_2 \cos(q_1 + q_2)\), \(y = l_1 \sin q_1 + l_2 \sin(q_1 + q_2)\).
|
| ChFrame | planar_fk_frames (const PlanarArm &arm, const PlanarJoints &q) |
| | The pose of the tip as a chain of frames, \(X_{WE} = X_{W1} X_{12} X_{2E}\): each joint adds a rotation about z, each link an offset along x.
|
| std::vector< PlanarJoints > | planar_ik (const PlanarArm &arm, real_t x, real_t y) |
| | The joint angles that put the tip at (x, y), from the law of cosines.
|
| RealMat2d | planar_jacobian (const PlanarArm &arm, const PlanarJoints &q) |
| | The Jacobian \(\partial(x, y) / \partial(q_1, q_2)\). It is singular when \(\sin q_2 = 0\): the arm fully stretched or folded.
|
| std::vector< ChFrame<> > | spatial_fk_all (const SpatialArm &arm, const SpatialJoints &q) |
| | The pose in the world of every joint frame, followed by the end-effector: \(X_{W1}, X_{W2}, X_{W3}, X_{WE}\).
|
| ChFrame | spatial_fk (const SpatialArm &arm, const SpatialJoints &q) |
| | The pose of the end-effector in the world, \(X_{WE}\).
|
| std::vector< SpatialJoints > | spatial_ik (const SpatialArm &arm, const ChVector3d &p_W) |
| std::optional< SpatialJoints > | spatial_ik_elbow_up (const SpatialArm &arm, const ChVector3d &p_W) |
| RealMat3d | numerical_jacobian (const SpatialArm &arm, const SpatialJoints &q) |
| | The Jacobian \(\partial(x, y, z) / \partial(q_1, q_2, q_3)\) of the end-effector's position by central differences. It needs only the forward kinematics.
|
| IKResult | numerical_ik (const SpatialArm &arm, const ChVector3d &target, SpatialJoints q0, real_t damping, int max_iterations, real_t tolerance, real_t max_step, const IKObserver &observer) |
| std::vector< SpatialJoints > | spatial_ik (const SpatialArm &arm, const chrono::ChVector3d &p_W) |
| | All the joint angles that put the end-effector at p_W.
|
| std::optional< SpatialJoints > | spatial_ik_elbow_up (const SpatialArm &arm, const chrono::ChVector3d &p_W) |
| | The solution facing the target with the elbow up, or nothing when p_W is out of reach.
|
| IKResult | numerical_ik (const SpatialArm &arm, const chrono::ChVector3d &target, SpatialJoints q0, real_t damping, int max_iterations=100, real_t tolerance=1.0e-6, real_t max_step=0.5, const IKObserver &observer={}) |
| | Inverse kinematics by iteration from q0: \(q \leftarrow q + \Delta q\) until the end-effector is within tolerance of the target.
|
| chrono::ChMatrix33d | rot_x (real_t angle) |
| | The rotation by angle [rad] about the x axis. It leaves the x axis unchanged:
|
| chrono::ChMatrix33d | rot_z (real_t angle) |
| | The rotation by angle [rad] about the z axis.
|
| real_t | wrap_angle (real_t angle) |
| | The angle [rad] wrapped to \((-\pi, \pi]\), so that angles that differ by whole turns compare equal.
|