TVec::Reverse Method

Overload List

#SignatureDescription
1TMtxVec *Reverse(TMtxVec *Vec, int VecIndex, int Index, int Len);Reverse vector elements.
2TMtxVec *Reverse(int Index, int Len);Reverses the calling object elements [Index]..[Index+Len-1].
3TVec *Reverse();Reverse vector elements.
4TVec *Reverse(TMtxVec *Vec);Reverse all Vec elements.

Overload 1: TMtxVec *Reverse(TMtxVec *Vec, int VecIndex, int Index, int Len);

Reverse vector elements.

#NameTypeDescription
1VecTMtxVec *
2VecIndexint
3Indexint
4Lenint
Remarks:

The method reverses Vec vector elements from [VecIndex].. [VecIndex+Len-1] and stores them in the calling vector from [Index]...[Index+Len-1] by using the following equation:

V[k]=Vec[Nk],0kN,where N=Vec.Length1\text{V}[k]=\text{Vec}[N-k],\quad 0\leq k \leq N, \quad \text{where } N=\text{Vec.Length}-1

This overload reverses calling vector elements in-place.

See Also: TVec::Rotate, TVec::Shift
Declared in Dew::Math::TDenseMtxVec · Dew.Math/AbstractMtxVec.h · Cross-compiler

Overload 2: TMtxVec *Reverse(int Index, int Len);

Reverses the calling object elements [Index]..[Index+Len-1].

#NameTypeDescription
1Indexint
2Lenint
Remarks:

An exception is raised if array borders are overrun.

Declared in Dew::Math::TDenseMtxVec · Dew.Math/AbstractMtxVec.h · Cross-compiler

Overload 3: TVec *Reverse();

Reverse vector elements.

Remarks:

The method reverses vector elements by using the following equation:

V[k]=Vec[Nk],0kN,where N=Vec.Length1\text{V}[k]=\text{Vec}[N-k],\quad 0\leq k \leq N, \quad \text{where } N=\text{Vec.Length}-1

This overload reverses all calling vector elements in-place.

See Also: TVec::Rotate, TVec::Shift
Declared in Dew::Math::TVec · Dew.Math/MtxVec.h · Cross-compiler

Overload 4: TVec *Reverse(TMtxVec *Vec);

Reverse all Vec elements.

#NameTypeDescription
1VecTMtxVec *
Remarks:

Xtore the result in the calling vector elements. The TVec::Length and TVec::Complex roperties of the calling vector are set implicitly to match Vec vector.

Declared in Dew::Math::TVec · Dew.Math/MtxVec.h · Cross-compiler