Theoretica
Scientific Computing
Loading...
Searching...
No Matches
theoretica::parallel Namespace Reference

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

Functions

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

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

◆ 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

◆ map()

template<typename Function, typename Vector>
Vector theoretica::parallel::map ( 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

◆ 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
nThe integer exponent
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
xThe real exponent
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

◆ transform()

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

Transform a vector by applying a given function to each of its elements, modifying the vector itself and using OpenMP to speed up execution.

Parameters
fThe function to evaluate
vThe vector of inputs
Returns
A reference to the input vector which has been modified