#include "petscmat.h" PetscErrorCode MatSetPreallocationCOOLocal(Mat A,PetscCount ncoo,PetscInt coo_i[],PetscInt coo_j[])Collective on Mat
A | - matrix being preallocated | |
ncoo | - number of entries | |
coo_i | - row indices (local numbering; may be modified) | |
coo_j | - column indices (local numbering; may be modified) |
The indices coo_i and coo_j may be modified within this function. They might be translated to corresponding global indices, but the caller should not rely on them having any specific value after this function returns. The arrays can be freed or reused immediately after this function returns.
Entries can be repeated, see MatSetValuesCOO(). Entries with negative row or column indices are allowed but will be ignored. The corresponding entries in MatSetValuesCOO() will be ignored too. Remote entries are allowed and will be properly added or inserted to the matrix.