|
HyPar
1.0
Finite-Difference Hyperbolic-Parabolic PDE Solver on Cartesian Grids
|
Copy from a HyPar array to a PETSc vector. More...
#include <stdlib.h>#include <vector>#include <basic.h>#include <arrayfunctions.h>#include <simulation_object.h>#include <bandedmatrix.h>#include <petscinterface_struct.h>Go to the source code of this file.
Macros | |
| #define | __FUNCT__ "TransferVecToPETSc" |
Functions | |
| int | TransferVecToPETSc (const double *const u, Vec Y, void *ctxt, const int sim_idx, const int offset) |
| int | TransferMatToPETSc (void *J, Mat A, void *ctxt) |
Copy from a HyPar array to a PETSc vector.
Definition in file TransferToPETSc.cpp.
| #define __FUNCT__ "TransferVecToPETSc" |
Definition at line 17 of file TransferToPETSc.cpp.
| int TransferVecToPETSc | ( | const double *const | u, |
| Vec | Y, | ||
| void * | ctxt, | ||
| const int | sim_idx, | ||
| const int | offset | ||
| ) |
Copy data to a PETSc vector (used by PETSc time integrators, and with no ghost points) from a HyPar::u array (with ghost points).
| u | HyPar::u type array (with ghost points) |
| Y | PETSc vector |
| ctxt | Object of type PETScContext |
| sim_idx | Simulation object index |
| offset | Offset |
Definition at line 24 of file TransferToPETSc.cpp.
| int TransferMatToPETSc | ( | void * | J, |
| Mat | A, | ||
| void * | ctxt | ||
| ) |
Copy a matrix of type BandedMatrix to a PETSc matrix.
| J | Matrix of type BandedMatrix |
| A | PETSc matrix |
| ctxt | Object of type PETScContext |
Definition at line 53 of file TransferToPETSc.cpp.