[go: up one dir, main page]

Trait InnerSpace

Source
pub trait InnerSpace: NormedSpace {
    // Required method
    fn inner_product(&self, other: &Self) -> Self::ComplexField;

    // Provided method
    fn angle(&self, other: &Self) -> Self::RealField { ... }
}
Expand description

A vector space equipped with an inner product.

It must be a normed space as well and the norm must agree with the inner product. The inner product must be symmetric, linear in its first argument, and positive definite.

Required Methods§

Source

fn inner_product(&self, other: &Self) -> Self::ComplexField

Computes the inner product of self with other.

Provided Methods§

Source

fn angle(&self, other: &Self) -> Self::RealField

Measures the angle between two vectors.

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§