$$ \gdef\pd#1#2{\frac{\partial #1}{\partial #2}} \gdef\d#1{\, \mathrm{d}#1} \gdef\dx{\d{x}} \gdef\tr#1{\operatorname{tr} (#1)} $$ $$ \gdef\norm#1{\left \lVert #1 \right\rVert} \gdef\seminorm#1{| #1 |} $$ $$ \gdef\vec#1{\mathbf{\boldsymbol{#1}}} \gdef\dvec#1{\bar{\vec #1}} $$

Trait fenris::geometry::Distance

source ·
pub trait Distance<T, QueryGeometry>where
    T: Scalar,{
    // Required method
    fn distance(&self, query_geometry: &QueryGeometry) -> T;

    // Provided method
    fn distance_bound(&self, query_geometry: &QueryGeometry) -> [T; 2] { ... }
}

Required Methods§

source

fn distance(&self, query_geometry: &QueryGeometry) -> T

Provided Methods§

source

fn distance_bound(&self, query_geometry: &QueryGeometry) -> [T; 2]

Returns an interval [l, u] for the distance d, such that d is contained in [l, u].

Implementors§

source§

impl<T> Distance<T, OPoint<T, Const<2>>> for Quad2d<T>where T: Real,

source§

impl<T> Distance<T, OPoint<T, Const<2>>> for SimplePolygon<T, Const<2>>where T: Real,

source§

impl<T> Distance<T, OPoint<T, Const<2>>> for Triangle<T, Const<2>>where T: Real,

source§

impl<T> Distance<T, OPoint<T, Const<3>>> for Hexahedron<T>where T: Real,

source§

impl<T> Distance<T, OPoint<T, Const<3>>> for Tetrahedron<T>where T: Real,

source§

impl<T> Distance<T, OPoint<T, Const<3>>> for Triangle<T, Const<3>>where T: Real,