HP MLIB User's Guide Vol. 2 7th Ed.
738 HP MLIB LAPACK User’s Guide
Basic steps to call a Distributed SuperLU routine
These routines solve the system by forward and back substitutions using the
L and U factors computed by pdgstrf or pzgstrf.
Currently, B must be globally available on all processes.
• pdgsrfs, pdgsrfs_ABXglobal, pzgsrfs, pzgsrfs_ABXglobal: Refine solution in
parallel.
Given A, its factors L and U, and an initial solution X, these routines
perform iterative refinement.
Basic steps to call a Distributed SuperLU routine
We use the driver routines pdgssvx_ABglobal and pzgssvx_ABglobal as
examples to describe the steps to call a Distributed SuperLU routine.
1. Initialize MPI environment and Distributed SuperLU process grid. This is
achieved by the calls to the MPI routine MPI_Init and the routine
superlu_gridinit. It can be built upon any MPI communicator.
2. Set up the input matrix and the right-hand side. Currently the library
requires the input matrix and the right-hand side be available on every
process.
3. Initialize the input arguments: options, ScalePermstruct, LUstruct, stat.
The input argument options controls how the linear system would be solved;
use equilibration or not, how to order the rows and columns of the matrix,
use iterative refinement or not. ScalePermstruct is the data structure in
which matrix A of the linear system and several vectors describing the
transformations done to A are stored. LUstruct is the data structure in
which the distributed L and U factors are stored. stat is a structure
collecting the statistics about runtime and flop count.
4. Call pdgssvx_ABglobal or pzgssvx_ABglobal to solve the linear system.
5. Release the process grid and terminate the MPI environment. After the
computation on a process grid has been completed, the process grid should
be released by a call to the routine superlu_gridexit. When all computations
have been completed, the MPI routine MPI_Finalize should be called.