Auxiliary Arithmetic Algorithms
Maximum Space (L-Infinity)

Functions

template<typename InputIterator , typename T = value_type_i<InputIterator>>
aaa::maximum::norm (InputIterator first, InputIterator last, T init=T{})
 
template<typename Container , typename T = value_type<Container>>
aaa::maximum::norm (const Container &a, T init=T{})
 
template<typename InputIterator , typename T = value_type_i<InputIterator>>
aaa::maximum::squared_norm (InputIterator first, InputIterator last, T init=T{})
 
template<typename Container , typename T = value_type<Container>>
aaa::maximum::squared_norm (const Container &a, T init=T{})
 
template<typename InputIterator1 , typename InputIterator2 , typename T = value_type_i<InputIterator1>>
aaa::maximum::distance (InputIterator1 first_left, InputIterator1 last_left, InputIterator2 first_right, T init=T{})
 
template<typename Container1 , typename Container2 , typename T = value_type<Container1>>
aaa::maximum::distance (const Container1 &left, const Container2 &right, T init=T{})
 
template<typename InputIterator1 , typename InputIterator2 , typename T = value_type_i<InputIterator1>>
aaa::maximum::squared_distance (InputIterator1 first_left, InputIterator1 last_left, InputIterator2 first_right, T init=T{})
 
template<typename Container1 , typename Container2 , typename T = value_type<Container1>>
aaa::maximum::squared_distance (const Container1 &left, const Container2 &right, T init=T{})
 

Detailed Description

Maximum space is also known as Chebyshev space or L-infinity space. Maximum space defines the following functions:

We represent mathematical vectors as either containers, or ranges of iterators. The functions in this module take one or two vectors as input and output a single scalar. This is sometimes refered to as a reduction or fold operation.

Function Documentation

template<typename InputIterator1 , typename InputIterator2 , typename T = value_type_i<InputIterator1>>
T aaa::maximum::distance ( InputIterator1  first_left,
InputIterator1  last_left,
InputIterator2  first_right,
init = T{} 
)

The maximum distance of two vectors. Each vector is represented by a range of iterators.

template<typename Container1 , typename Container2 , typename T = value_type<Container1>>
T aaa::maximum::distance ( const Container1 &  left,
const Container2 &  right,
init = T{} 
)

The maximum distance of two vectors. Each vector is represented by a container. The two containers should have the same size.

template<typename InputIterator , typename T = value_type_i<InputIterator>>
T aaa::maximum::norm ( InputIterator  first,
InputIterator  last,
init = T{} 
)

The maximum norm of a vector. The vector is represented by a range of iterators.

template<typename Container , typename T = value_type<Container>>
T aaa::maximum::norm ( const Container &  a,
init = T{} 
)

The maximum norm of a vector. The vector is represented by a container.

template<typename InputIterator1 , typename InputIterator2 , typename T = value_type_i<InputIterator1>>
T aaa::maximum::squared_distance ( InputIterator1  first_left,
InputIterator1  last_left,
InputIterator2  first_right,
init = T{} 
)

The squared maximum distance of two vectors. Each vector is represented by a range of iterators.

template<typename Container1 , typename Container2 , typename T = value_type<Container1>>
T aaa::maximum::squared_distance ( const Container1 &  left,
const Container2 &  right,
init = T{} 
)

The squared maximum distance of two vectors. Each vector is represented by a container. The two containers should have the same size.

template<typename InputIterator , typename T = value_type_i<InputIterator>>
T aaa::maximum::squared_norm ( InputIterator  first,
InputIterator  last,
init = T{} 
)

The squared maximum norm of a vector. The vector is represented by a range of iterators.

template<typename Container , typename T = value_type<Container>>
T aaa::maximum::squared_norm ( const Container &  a,
init = T{} 
)

The squared maximum norm of a vector. The vector is represented by a container.