![]() |
Fast Auxiliary Space Preconditioning 2.7.7 Aug/28/2022
|
Array sorting/merging and removing duplicated integers. More...
Go to the source code of this file.
Functions | |
INT | fasp_aux_BiSearch (const INT nlist, const INT *list, const INT value) |
Binary Search. More... | |
INT | fasp_aux_unique (INT numbers[], const INT size) |
Remove duplicates in an sorted (ascending order) array. More... | |
void | fasp_aux_merge (INT numbers[], INT work[], INT left, INT mid, INT right) |
Merge two sorted arrays. More... | |
void | fasp_aux_msort (INT numbers[], INT work[], INT left, INT right) |
Sort the INT array in ascending order with the merge sort algorithm. More... | |
void | fasp_aux_iQuickSort (INT *a, INT left, INT right) |
Sort the array (INT type) in ascending order with the quick sorting algorithm. More... | |
void | fasp_aux_dQuickSort (REAL *a, INT left, INT right) |
Sort the array (REAL type) in ascending order with the quick sorting algorithm. More... | |
void | fasp_aux_iQuickSortIndex (INT *a, INT left, INT right, INT *index) |
Reorder the index of (INT type) so that 'a' is in ascending order. More... | |
void | fasp_aux_dQuickSortIndex (REAL *a, INT left, INT right, INT *index) |
Reorder the index of (REAL type) so that 'a' is ascending in such order. More... | |
Array sorting/merging and removing duplicated integers.
Copyright (C) 2009–Present by the FASP team. All rights reserved.
Definition in file AuxSort.c.
Sort the array (REAL type) in ascending order with the quick sorting algorithm.
a | Pointer to the array needed to be sorted |
left | Starting index |
right | Ending index |
Reorder the index of (REAL type) so that 'a' is ascending in such order.
a | Pointer to the array |
left | Starting index |
right | Ending index |
index | Index of 'a' (out) |
Sort the array (INT type) in ascending order with the quick sorting algorithm.
a | Pointer to the array needed to be sorted |
left | Starting index |
right | Ending index |
Reorder the index of (INT type) so that 'a' is in ascending order.
a | Pointer to the array |
left | Starting index |
right | Ending index |
index | Index of 'a' (out) |
Merge two sorted arrays.
numbers | Pointer to the array needed to be sorted |
work | Pointer to the work array with same size as numbers |
left | Starting index of array 1 |
mid | Starting index of array 2 |
right | Ending index of array 1 and 2 |
Sort the INT array in ascending order with the merge sort algorithm.
numbers | Pointer to the array needed to be sorted |
work | Pointer to the work array with same size as numbers |
left | Starting index |
right | Ending index |
Remove duplicates in an sorted (ascending order) array.
numbers | Pointer to the array needed to be sorted (in/out) |
size | Length of the target array |