Theoretica
A C++ numerical and automatic mathematical library
theoretica::parallel Namespace Reference

Parallelized element-wise evaluation of functions. More...

Functions

template<typename Function , typename Vector >
Vector apply_function (Function f, const Vector &v)
 Parallel element-wise evaluation of a function, using OpenMP to speed up execution over a vector. More...
 
template<typename Vector >
Vector square (const Vector &v)
 Parallel element-wise evaluation of the square function. More...
 
template<typename Vector >
Vector cube (const Vector &v)
 Parallel element-wise evaluation of the cube function. More...
 
template<typename Vector >
Vector abs (const Vector &v)
 Parallel element-wise evaluation of the abs function. More...
 
template<typename Vector >
Vector pow (const Vector &v, int n)
 Parallel element-wise evaluation of the pow function. More...
 
template<typename Vector >
Vector powf (const Vector &v, real x)
 Parallel element-wise evaluation of the powf function. More...
 
template<typename Vector >
Vector sqrt (const Vector &v)
 Parallel element-wise evaluation of the sqrt function. More...
 
template<typename Vector >
Vector cbrt (const Vector &v)
 Parallel element-wise evaluation of the cbrt function. More...
 
template<typename Vector >
Vector exp (const Vector &v)
 Parallel element-wise evaluation of the exp function. More...
 
template<typename Vector >
Vector ln (const Vector &v)
 Parallel element-wise evaluation of the ln function. More...
 
template<typename Vector >
Vector log2 (const Vector &v)
 Parallel element-wise evaluation of the log2 function. More...
 
template<typename Vector >
Vector log10 (const Vector &v)
 Parallel element-wise evaluation of the log10 function. More...
 
template<typename Vector >
Vector sin (const Vector &v)
 Parallel element-wise evaluation of the sin function. More...
 
template<typename Vector >
Vector cos (const Vector &v)
 Parallel element-wise evaluation of the cos function. More...
 
template<typename Vector >
Vector tan (const Vector &v)
 Vectorized (element-wise evaluation) of the tan function. More...
 
template<typename Vector >
Vector cot (const Vector &v)
 Vectorized (element-wise evaluation) of the cot function. More...
 
template<typename Vector >
Vector asin (const Vector &v)
 Vectorized (element-wise evaluation) of the asin function. More...
 
template<typename Vector >
Vector acos (const Vector &v)
 Vectorized (element-wise evaluation) of the acos function. More...
 
template<typename Vector >
Vector atan (const Vector &v)
 Vectorized (element-wise evaluation) of the atan function. More...
 
template<typename Vector >
Vector sinh (const Vector &v)
 Vectorized (element-wise evaluation) of the sinh function. More...
 
template<typename Vector >
Vector cosh (const Vector &v)
 Vectorized (element-wise evaluation) of the cosh function. More...
 
template<typename Vector >
Vector tanh (const Vector &v)
 Vectorized (element-wise evaluation) of the tanh function. More...
 
template<typename Vector >
Vector coth (const Vector &v)
 Vectorized (element-wise evaluation) of the coth function. More...
 

Detailed Description

Parallelized element-wise evaluation of functions.

Function Documentation

◆ abs()

template<typename Vector >
Vector theoretica::parallel::abs ( const Vector &  v)
inline

Parallel element-wise evaluation of the abs function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ acos()

template<typename Vector >
Vector theoretica::parallel::acos ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the acos function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ apply_function()

template<typename Function , typename Vector >
Vector theoretica::parallel::apply_function ( Function  f,
const Vector &  v 
)
inline

Parallel element-wise evaluation of a function, using OpenMP to speed up execution over a vector.

Parameters
fThe function to evaluate
vThe vector of inputs
Returns
The transformed vector

◆ asin()

template<typename Vector >
Vector theoretica::parallel::asin ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the asin function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ atan()

template<typename Vector >
Vector theoretica::parallel::atan ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the atan function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ cbrt()

template<typename Vector >
Vector theoretica::parallel::cbrt ( const Vector &  v)
inline

Parallel element-wise evaluation of the cbrt function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ cos()

template<typename Vector >
Vector theoretica::parallel::cos ( const Vector &  v)
inline

Parallel element-wise evaluation of the cos function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ cosh()

template<typename Vector >
Vector theoretica::parallel::cosh ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the cosh function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ cot()

template<typename Vector >
Vector theoretica::parallel::cot ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the cot function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ coth()

template<typename Vector >
Vector theoretica::parallel::coth ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the coth function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ cube()

template<typename Vector >
Vector theoretica::parallel::cube ( const Vector &  v)
inline

Parallel element-wise evaluation of the cube function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ exp()

template<typename Vector >
Vector theoretica::parallel::exp ( const Vector &  v)
inline

Parallel element-wise evaluation of the exp function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ ln()

template<typename Vector >
Vector theoretica::parallel::ln ( const Vector &  v)
inline

Parallel element-wise evaluation of the ln function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ log10()

template<typename Vector >
Vector theoretica::parallel::log10 ( const Vector &  v)
inline

Parallel element-wise evaluation of the log10 function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ log2()

template<typename Vector >
Vector theoretica::parallel::log2 ( const Vector &  v)
inline

Parallel element-wise evaluation of the log2 function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ pow()

template<typename Vector >
Vector theoretica::parallel::pow ( const Vector &  v,
int  n 
)
inline

Parallel element-wise evaluation of the pow function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ powf()

template<typename Vector >
Vector theoretica::parallel::powf ( const Vector &  v,
real  x 
)
inline

Parallel element-wise evaluation of the powf function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ sin()

template<typename Vector >
Vector theoretica::parallel::sin ( const Vector &  v)
inline

Parallel element-wise evaluation of the sin function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ sinh()

template<typename Vector >
Vector theoretica::parallel::sinh ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the sinh function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ sqrt()

template<typename Vector >
Vector theoretica::parallel::sqrt ( const Vector &  v)
inline

Parallel element-wise evaluation of the sqrt function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ square()

template<typename Vector >
Vector theoretica::parallel::square ( const Vector &  v)
inline

Parallel element-wise evaluation of the square function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ tan()

template<typename Vector >
Vector theoretica::parallel::tan ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the tan function.

Parameters
vThe vector of inputs
Returns
The transformed vector

◆ tanh()

template<typename Vector >
Vector theoretica::parallel::tanh ( const Vector &  v)
inline

Vectorized (element-wise evaluation) of the tanh function.

Parameters
vThe vector of inputs
Returns
The transformed vector