petsc-3.7.1 2016-05-15
Report Typos and Errors

PetscMergeIntArrayPair

Merges two SORTED integer arrays that share NO common values along with an additional array of integers. The additional arrays are the same length as sorted arrays and are merged in the order determined by the merging of the sorted pair.

Synopsis

#include "petscsys.h"  
PetscErrorCode  PetscMergeIntArrayPair(PetscInt an,const PetscInt *aI, const PetscInt *aJ, PetscInt bn, const PetscInt *bI, const PetscInt *bJ, PetscInt *n, PetscInt **L, PetscInt **J)
Not Collective Many br

Input Parameters

an - number of values in the first array Many br
aI - first sorted array of integers Many br
aJ - first additional array of integers Many br
bn - number of values in the second array Many br
bI - second array of integers Many br
bJ - second additional of integers Many br

Output Parameters

n - number of values in the merged array (== an + bn) Many br
L - merged sorted array Many br
J - merged additional array Many br

Notes: if L or J point to non-null arrays then this routine will assume they are of the approproate size and use them, otherwise this routine will allocate space for them Many br Many br

See Also

PetscSortReal(), PetscSortIntPermutation(), PetscSortInt(), PetscSortIntWithArray()

Level:intermediate
Location:
src/sys/utils/sorti.c
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages