library.sort
Submodule¶
Module Summary¶
Interfaces for the NAG Mark 30.2 sort Chapter.
sort
- Sorting and Searching
This module is concerned with sorting and searching numeric or character data. It handles only the simplest types of data structure and it is concerned only with internal sorting and searching – that is, sorting and searching a set of data which can all be stored within the program.
If you have large files of data or complicated data structures to be sorted or searched you should use a comprehensive sorting or searching program or package.
Functionality Index¶
Ranking
arbitrary data:
arbitrary_rank()
columns of a matrix
integer numbers:
intmat_rank_columns()
real numbers:
realmat_rank_columns()
rows of a matrix
integer numbers:
intmat_rank_rows()
real numbers:
realmat_rank_rows()
vector
Rearranging (according to pre-determined ranks)
vector
character data:
charvec_rank_rearrange()
complex numbers:
cmplxvec_rank_rearrange()
integer numbers:
intvec_rank_rearrange()
real numbers:
realvec_rank_rearrange()
Searching (i.e., exact match or the nearest lower value)
Service functions
check validity of a permutation:
permute_check()
decompose a permutation into cycles:
permute_decompose()
invert a permutation (ranks to indices or vice versa):
permute_invert()
Sorting (i.e., rearranging into sorted order)
quick sort
vector
For full information please refer to the NAG Library document
https://support.nag.com/numeric/nl/nagdoc_30.2/flhtml/m01/m01intro.html