SuperLU Distributed 8.2.1
Distributed memory sparse direct solver
psgsrfs_ABXglobal.c File Reference

Improves the computed solution and provies error bounds. More...

#include <math.h>
#include "superlu_sdefs.h"
Include dependency graph for psgsrfs_ABXglobal.c:

Macros

#define ITMAX   20
 

Functions

static void gather_1rhs_diag_to_all (int_t, float[], Glu_persist_t *, sLocalLU_t *, gridinfo_t *, int_t, int_t[], int_t[], float[], float[])
 
static void redist_all_to_diag (int_t, float[], Glu_persist_t *, sLocalLU_t *, gridinfo_t *, int_t[], float[])
 
void psgsrfs_ABXglobal (superlu_dist_options_t *options, int_t n, SuperMatrix *A, float anorm, sLUstruct_t *LUstruct, gridinfo_t *grid, float *B, int_t ldb, float *X, int_t ldx, int nrhs, float *berr, SuperLUStat_t *stat, int *info)
 

Detailed Description

Improves the computed solution and provies error bounds.

Copyright (c) 2003, The Regents of the University of California, through Lawrence Berkeley National Laboratory (subject to receipt of any required approvals from U.S. Dept. of Energy)

All rights reserved.

The source code is distributed under BSD license, see the file License.txt at the top-level directory.

-- Distributed SuperLU routine (version 4.3) --
Lawrence Berkeley National Lab, Univ. of California Berkeley.
September 1, 1999

Last modified:
December 31, 2015  version 4.3

Macro Definition Documentation

◆ ITMAX

#define ITMAX   20

Function Documentation

◆ gather_1rhs_diag_to_all()

static void gather_1rhs_diag_to_all ( int_t  n,
float  x[],
Glu_persist_t Glu_persist,
sLocalLU_t Llu,
gridinfo_t grid,
int_t  num_diag_procs,
int_t  diag_procs[],
int_t  diag_len[],
float  y[],
float  work[] 
)
static
Gather the components of x vector on the diagonal processes
onto all processes, and combine them into the global vector y.
Here is the caller graph for this function:

◆ psgsrfs_ABXglobal()

void psgsrfs_ABXglobal ( superlu_dist_options_t options,
int_t  n,
SuperMatrix A,
float  anorm,
sLUstruct_t LUstruct,
gridinfo_t grid,
float *  B,
int_t  ldb,
float *  X,
int_t  ldx,
int  nrhs,
float *  berr,
SuperLUStat_t stat,
int *  info 
)
Purpose
=======

psgsrfs_ABXglobal improves the computed solution to a system of linear
equations and provides error bounds and backward error estimates
for the solution.

Arguments
=========

n      (input) int (global)
       The order of the system of linear equations.

A      (input) SuperMatrix*
   The original matrix A, or the scaled A if equilibration was done.
       A is also permuted into the form Pc*Pr*A*Pc', where Pr and Pc
       are permutation matrices. The type of A can be:
       Stype = SLU_NCP; Dtype = SLU_S; Mtype = SLU_GE.

       NOTE: Currently, A must reside in all processes when calling
             this routine.

anorm  (input) double
       The norm of the original matrix A, or the scaled A if
       equilibration was done.

LUstruct (input) sLUstruct_t*
       The distributed data structures storing L and U factors.
       The L and U factors are obtained from psgstrf for
       the possibly scaled and permuted matrix A.
       See superlu_ddefs.h for the definition of 'sLUstruct_t'.

grid   (input) gridinfo_t*
       The 2D process mesh. It contains the MPI communicator, the number
       of process rows (NPROW), the number of process columns (NPCOL),
       and my process rank. It is an input argument to all the
       parallel routines.
       Grid can be initialized by subroutine SUPERLU_GRIDINIT.
       See superlu_ddefs.h for the definition of 'gridinfo_t'.

B      (input) float* (global)
       The N-by-NRHS right-hand side matrix of the possibly equilibrated
       and row permuted system.

       NOTE: Currently, B must reside on all processes when calling
             this routine.

ldb    (input) int (global)
       Leading dimension of matrix B.

X      (input/output) float* (global)
       On entry, the solution matrix X, as computed by PSGSTRS.
       On exit, the improved solution matrix X.
       If DiagScale = COL or BOTH, X should be premultiplied by diag(C)
       in order to obtain the solution to the original system.

       NOTE: Currently, X must reside on all processes when calling
             this routine.

ldx    (input) int (global)
       Leading dimension of matrix X.

nrhs   (input) int
       Number of right-hand sides.

berr   (output) double*, dimension (nrhs)
        The componentwise relative backward error of each solution
        vector X(j) (i.e., the smallest relative change in
        any element of A or B that makes X(j) an exact solution).

stat   (output) SuperLUStat_t*
       Record the statistics about the refinement steps.
       See util.h for the definition of SuperLUStat_t.

info   (output) int*
       = 0: successful exit
       < 0: if info = -i, the i-th argument had an illegal value

Internal Parameters
===================

ITMAX is the maximum number of steps of iterative refinement.
Here is the call graph for this function:

◆ redist_all_to_diag()

static void redist_all_to_diag ( int_t  n,
float  r[],
Glu_persist_t Glu_persist,
sLocalLU_t Llu,
gridinfo_t grid,
int_t  mv_sup_to_proc[],
float  work[] 
)
static
r[] is the residual vector distributed the same way as
matrix-vector product.
Here is the caller graph for this function: