Skip to main content

FKChain

Trait FKChain 

Source
pub trait FKChain<const N: usize>:
    Clone
    + Send
    + Sync {
    type Error: Into<DekeError>;

    // Required methods
    fn fk(&self, q: &SRobotQ<N>) -> Result<[Affine3A; N], Self::Error>;
    fn fk_end(&self, q: &SRobotQ<N>) -> Result<Affine3A, Self::Error>;
    fn joint_axes_positions(
        &self,
        q: &SRobotQ<N>,
    ) -> Result<([Vec3A; N], [Vec3A; N], Vec3A), Self::Error>;

    // Provided methods
    fn dof(&self) -> usize { ... }
    fn base_tf(&self) -> Affine3A { ... }
    fn max_reach(&self) -> Result<f32, Self::Error> { ... }
    fn jacobian(&self, q: &SRobotQ<N>) -> Result<[[f32; N]; 6], Self::Error> { ... }
    fn jacobian_dot(
        &self,
        q: &SRobotQ<N>,
        qdot: &SRobotQ<N>,
    ) -> Result<[[f32; N]; 6], Self::Error> { ... }
    fn jacobian_ddot(
        &self,
        q: &SRobotQ<N>,
        qdot: &SRobotQ<N>,
        qddot: &SRobotQ<N>,
    ) -> Result<[[f32; N]; 6], Self::Error> { ... }
}

Required Associated Types§

Required Methods§

Source

fn fk(&self, q: &SRobotQ<N>) -> Result<[Affine3A; N], Self::Error>

Source

fn fk_end(&self, q: &SRobotQ<N>) -> Result<Affine3A, Self::Error>

Source

fn joint_axes_positions( &self, q: &SRobotQ<N>, ) -> Result<([Vec3A; N], [Vec3A; N], Vec3A), Self::Error>

Returns joint rotation axes and axis-origin positions in world frame at configuration q, plus the end-effector position.

Provided Methods§

Source

fn dof(&self) -> usize

Source

fn base_tf(&self) -> Affine3A

Configuration-independent transform from the robot’s base frame to the world frame. Defaults to identity; wrappers that install a static prefix (e.g. TransformedFK with a prefix set, or URDFChain with fixed leading joints baked in) override this so downstream consumers (collision validators, visualizers) can place the static base body at the correct pose.

Source

fn max_reach(&self) -> Result<f32, Self::Error>

Theoretical maximum reach: sum of link lengths (upper bound, ignores joint limits).

Source

fn jacobian(&self, q: &SRobotQ<N>) -> Result<[[f32; N]; 6], Self::Error>

Geometric Jacobian (6×N) at configuration q. Rows 0–2: linear velocity, rows 3–5: angular velocity.

Source

fn jacobian_dot( &self, q: &SRobotQ<N>, qdot: &SRobotQ<N>, ) -> Result<[[f32; N]; 6], Self::Error>

First time-derivative of the geometric Jacobian.

Source

fn jacobian_ddot( &self, q: &SRobotQ<N>, qdot: &SRobotQ<N>, qddot: &SRobotQ<N>, ) -> Result<[[f32; N]; 6], Self::Error>

Second time-derivative of the geometric Jacobian.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl FKChain<1> for DynamicDHChain

Source§

impl FKChain<1> for DynamicHPChain

Source§

impl FKChain<1> for DynamicURDFChain

Source§

impl FKChain<2> for DynamicDHChain

Source§

impl FKChain<2> for DynamicHPChain

Source§

impl FKChain<2> for DynamicURDFChain

Source§

impl FKChain<3> for DynamicDHChain

Source§

impl FKChain<3> for DynamicHPChain

Source§

impl FKChain<3> for DynamicURDFChain

Source§

impl FKChain<4> for DynamicDHChain

Source§

impl FKChain<4> for DynamicHPChain

Source§

impl FKChain<4> for DynamicURDFChain

Source§

impl FKChain<5> for DynamicDHChain

Source§

impl FKChain<5> for DynamicHPChain

Source§

impl FKChain<5> for DynamicURDFChain

Source§

impl FKChain<6> for DynamicDHChain

Source§

impl FKChain<6> for DynamicHPChain

Source§

impl FKChain<6> for DynamicURDFChain

Source§

impl FKChain<7> for DynamicDHChain

Source§

impl FKChain<7> for DynamicHPChain

Source§

impl FKChain<7> for DynamicURDFChain

Source§

impl FKChain<8> for DynamicDHChain

Source§

impl FKChain<8> for DynamicHPChain

Source§

impl FKChain<8> for DynamicURDFChain

Source§

impl<const M: usize, const N: usize, FK: FKChain<N>> FKChain<M> for PrismaticFK<M, N, FK>

Source§

type Error = <FK as FKChain<N>>::Error

Source§

impl<const N: usize> FKChain<N> for BoxFK<N>

Source§

impl<const N: usize> FKChain<N> for DHChain<N>

Source§

impl<const N: usize> FKChain<N> for HPChain<N>

Source§

impl<const N: usize> FKChain<N> for URDFChain<N>

Source§

impl<const N: usize, FK: FKChain<N>> FKChain<N> for TransformedFK<N, FK>

Source§

type Error = <FK as FKChain<N>>::Error