VF_sortVD_sortVE_sort
VI_sortVBI_sortVSI_sortVLI_sortVQI_sort 
VU_sortVUB_sortVUS_sortVUL_sortVUQ_sortVUI_sort
FunctionSorting into ascending or descending order
Syntax C/C++#include <VFstd.h>
void VF_sort( fVector Y, fVector X, ui size, int dir );
C++ VecObj#include <OptiVec.h>
void vector<T>::sort( const vector<T>& X, int dir=1 );
Pascal/Delphiuses VFstd;
procedure VF_sort( Y, X:fVector; size:UIntSize; dir:Integer );
CUDA function C/C++#include <cudaVFstd.h>
int cudaVF_sort( fVector d_Y, fVector d_X, ui size, int dir );
void VFcu_sort( fVector h_Y, fVector h_X, ui size, int dir );
CUDA function Pascal/Delphiuses VFstd;
function cudaVF_sort( d_Y, d_X:fVector; size:UIntSize; dir:Integer ): IntBool;
procedure VFcu_sort( h_Y, h_X:fVector; size:UIntSize; dir:Integer );
DescriptionThe vector is sorted in ascending order, if dir is positive; negative dir yields descending order. The present implementation uses the "Heapsort" algorithm.
Error handlingnone
Return valuenone
See alsoVF_sortind,   VF_rotate,   VF_rev,   qsort (C/C++ only)

VectorLib Table of Contents  OptiVec home