|
cisst-saw
|
Implement operation of the form \((v_{1}, v_{2}) = op(v_{1}, v_{2})\) for fixed size vectors. More...
#include <vctFixedSizeVectorRecursiveEngines.h>
Public Types | |
| typedef vctFixedSizeVectorRecursiveEngines< _size-1 >::template VioVio< _elementOperationType > | RecursiveStep |
Static Public Member Functions | |
| template<class _inputOutputVector1Type, class _inputOutputVector2Type> | |
| static void | Unfold (_inputOutputVector1Type &inputOutput1, _inputOutputVector2Type &inputOutput2) |
Implement operation of the form \((v_{1}, v_{2}) = op(v_{1}, v_{2})\) for fixed size vectors.
This class uses template specialization to perform binary vector operations of the form
\[(v_{1}, v_{2}) = \mathrm{op}(v_{1}, v_{2}) \]
where both \(v_{1}, v_{2}\) are input and output vectors of an equal fixed size, determined at compilation time. The operation is evaluated elementwise, that is, \((v_{1}[i], v_{2}[i] = \mathrm{op}(v_{1}[i], v_{2}[i])\). The typical operation in this case is swapping the elements of the two vectors.
| _elementOperationType | The type of the binary operation that inputs and rewrites corresponding elements in both vectors. |
| typedef vctFixedSizeVectorRecursiveEngines<_size-1>::template VioVio<_elementOperationType> VioVio< _elementOperationType >::RecursiveStep |
|
inlinestatic |
Unfold the recursion. Performs the operation _elementOperationType elementwise on the last elements of the input/output vector(s) and call Unfold for the _size - 1 elements left (i.e. unfold the recursive calls).
| inputOutput1 | The first input-output vector. |
| inputOutput2 | The second input-output vector. |