pub struct SpatialForce(pub Vector6<f64>);Expand description
Spatial force vector, combining torque and force components.
A spatial force is represented as a 6-dimensional vector, which can be decomposed into $\begin{bmatrix} f & \tau \end{bmatrix}$, where $f$ is the force (translational component) and $\tau$ is the torque (rotational component).
Tuple Fields§
§0: Vector6<f64>Implementations§
Source§impl SpatialForce
impl SpatialForce
Sourcepub fn from_parts(force: Vector3D, torque: Vector3D) -> Self
pub fn from_parts(force: Vector3D, torque: Vector3D) -> Self
Creates a new SpatialForce from the given force and torque components.
§Arguments
force- The force component of the spatial force.torque- The torque component of the spatial force.
§Returns
A new SpatialForce object combining the given torque and force.
Sourcepub fn zero() -> Self
pub fn zero() -> Self
Creates a new SpatialForce with zeros components.
Sourcepub fn from_vector6(vector: Vector6<f64>) -> Self
pub fn from_vector6(vector: Vector6<f64>) -> Self
Creates a new SpatialForce from the given nalgebra::Vector6
Sourcepub fn from_vector6d(vector: Vector6D) -> Self
pub fn from_vector6d(vector: Vector6D) -> Self
Creates a new SpatialForce from the given Vector6D
Sourcepub fn translation(&self) -> Vector3D
pub fn translation(&self) -> Vector3D
Returns the force’s translation (first 3 components)
Sourcepub fn cross(&self, other: &SpatialForce) -> SpatialForce
pub fn cross(&self, other: &SpatialForce) -> SpatialForce
Sourcepub fn inner(&self, other: &SpatialForce) -> f64
pub fn inner(&self, other: &SpatialForce) -> f64
Computes the inner product of two spatial forces.
Trait Implementations§
Source§impl ActSE3 for SpatialForce
impl ActSE3 for SpatialForce
Source§impl Add<&SpatialForce> for SpatialForce
impl Add<&SpatialForce> for SpatialForce
Source§impl Add for SpatialForce
impl Add for SpatialForce
Source§impl AddAssign<&SpatialForce> for SpatialForce
impl AddAssign<&SpatialForce> for SpatialForce
Source§fn add_assign(&mut self, rhs: &Self)
fn add_assign(&mut self, rhs: &Self)
Performs the
+= operation. Read moreSource§impl AddAssign for SpatialForce
impl AddAssign for SpatialForce
Source§fn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
Performs the
+= operation. Read moreSource§impl Clone for SpatialForce
impl Clone for SpatialForce
Source§fn clone(&self) -> SpatialForce
fn clone(&self) -> SpatialForce
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SpatialForce
impl Debug for SpatialForce
Source§impl Mul<&SpatialForce> for &JacobianColumn
impl Mul<&SpatialForce> for &JacobianColumn
Source§impl PartialEq for SpatialForce
impl PartialEq for SpatialForce
Source§impl Sub<&SpatialForce> for SpatialForce
impl Sub<&SpatialForce> for SpatialForce
Source§impl Sub for SpatialForce
impl Sub for SpatialForce
Source§impl SubAssign<&SpatialForce> for SpatialForce
impl SubAssign<&SpatialForce> for SpatialForce
Source§fn sub_assign(&mut self, rhs: &Self)
fn sub_assign(&mut self, rhs: &Self)
Performs the
-= operation. Read moreSource§impl SubAssign for SpatialForce
impl SubAssign for SpatialForce
Source§fn sub_assign(&mut self, rhs: Self)
fn sub_assign(&mut self, rhs: Self)
Performs the
-= operation. Read moreimpl StructuralPartialEq for SpatialForce
Auto Trait Implementations§
impl Freeze for SpatialForce
impl RefUnwindSafe for SpatialForce
impl Send for SpatialForce
impl Sync for SpatialForce
impl Unpin for SpatialForce
impl UnsafeUnpin for SpatialForce
impl UnwindSafe for SpatialForce
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.