cisst-saw
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Static Public Member Functions | List of all members
vctDynamicVectorLoopEngines::SoViVi< _incrementalOperationType, _elementOperationType > Class Template Reference

Implement operation of the form $s_o = op_{incr}(op(v_{i1}, v_{i2}))$ for dynamic vectors. More...

#include <vctDynamicVectorLoopEngines.h>

Public Types

typedef
_incrementalOperationType::OutputType 
OutputType
 

Static Public Member Functions

template<class _input1VectorType , class _input2VectorType >
static OutputType Run (const _input1VectorType &input1Vector, const _input2VectorType &input2Vector)
 

Detailed Description

template<class _incrementalOperationType, class _elementOperationType>
class vctDynamicVectorLoopEngines::SoViVi< _incrementalOperationType, _elementOperationType >

Implement operation of the form $s_o = op_{incr}(op(v_{i1}, v_{i2}))$ for dynamic vectors.

This class uses a loop to perform incremental binary vector operations of the form

\[ s_o = \mathrm{op_{incr}(\mathrm{op}(v_{i1}, v_{i2}))} \]

where $v_{i1}$ and $v_{i2}$ are the input vectors and $s_o$ is the scalar output. The vectors have the same size, op stands for the unary operation performed elementwise on $v_{i1}$ and $v_{i2}$ and whose result are used incrementally as input for $op_{incr}$. For a vector of size 3, the result is $s_o = op_{incr}(op_{incr}(op(v1[1], v2[1]), op(v1[0], v2[0])), op(v1[2], v2[2]))$.

Parameters
_incrementalOperationTypeThe type of the incremental operation.
_elementOperationTypeThe type of the unary operation.
See Also
vctFixedSizeVectorRecursiveEngines

Member Typedef Documentation

template<class _incrementalOperationType , class _elementOperationType >
typedef _incrementalOperationType::OutputType vctDynamicVectorLoopEngines::SoViVi< _incrementalOperationType, _elementOperationType >::OutputType

Member Function Documentation

template<class _incrementalOperationType , class _elementOperationType >
template<class _input1VectorType , class _input2VectorType >
static OutputType vctDynamicVectorLoopEngines::SoViVi< _incrementalOperationType, _elementOperationType >::Run ( const _input1VectorType &  input1Vector,
const _input2VectorType &  input2Vector 
)
inlinestatic

Unroll the loop

Parameters
input1VectorThe first input vector (first operand for _elementOperationType).
input2VectorThe second input vector (second operand for _elementOperationType).

The documentation for this class was generated from the following file: