Fast Auxiliary Space Preconditioning  1.8.4 Feb/15/2016
smoother_csr.c File Reference

Smoothers for dCSRmat matrices. More...

#include <math.h>
#include "fasp.h"
#include "fasp_functs.h"

Go to the source code of this file.

Functions

void fasp_smoother_dcsr_jacobi (dvector *u, const INT i_1, const INT i_n, const INT s, dCSRmat *A, dvector *b, INT L)
 Jacobi method as a smoother. More...
 
void fasp_smoother_dcsr_gs (dvector *u, const INT i_1, const INT i_n, const INT s, dCSRmat *A, dvector *b, INT L)
 Gauss-Seidel method as a smoother. More...
 
void fasp_smoother_dcsr_gs_cf (dvector *u, dCSRmat *A, dvector *b, INT L, INT *mark, const INT order)
 Gauss-Seidel smoother with C/F ordering for Au=b. More...
 
void fasp_smoother_dcsr_sgs (dvector *u, dCSRmat *A, dvector *b, INT L)
 Symmetric Gauss-Seidel method as a smoother. More...
 
void fasp_smoother_dcsr_sor (dvector *u, const INT i_1, const INT i_n, const INT s, dCSRmat *A, dvector *b, INT L, const REAL w)
 SOR method as a smoother. More...
 
void fasp_smoother_dcsr_sor_cf (dvector *u, dCSRmat *A, dvector *b, INT L, const REAL w, INT *mark, const INT order)
 SOR smoother with C/F ordering for Au=b. More...
 
void fasp_smoother_dcsr_ilu (dCSRmat *A, dvector *b, dvector *x, void *data)
 ILU method as a smoother. More...
 
void fasp_smoother_dcsr_kaczmarz (dvector *u, const INT i_1, const INT i_n, const INT s, dCSRmat *A, dvector *b, INT L, const REAL w)
 Kaczmarz method as a smoother. More...
 
void fasp_smoother_dcsr_L1diag (dvector *u, const INT i_1, const INT i_n, const INT s, dCSRmat *A, dvector *b, INT L)
 Diagonal scaling (using L1 norm) as a smoother. More...
 
void fasp_smoother_dcsr_gs_rb3d (dvector *u, dCSRmat *A, dvector *b, INT L, const INT order, INT *mark, const INT maximap, const INT nx, const INT ny, const INT nz)
 Colored Gauss-Seidel smoother for Au=b. More...
 

Detailed Description

Smoothers for dCSRmat matrices.

Definition in file smoother_csr.c.

Function Documentation

void fasp_smoother_dcsr_gs ( dvector u,
const INT  i_1,
const INT  i_n,
const INT  s,
dCSRmat A,
dvector b,
INT  L 
)

Gauss-Seidel method as a smoother.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
i_1Starting index
i_nEnding index
sIncreasing step
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
Author
Xuehai Huang, Chensong Zhang
Date
09/26/2009

Modified by Chunsheng Feng, Zheng Li on 09/01/2012

Definition at line 195 of file smoother_csr.c.

void fasp_smoother_dcsr_gs_cf ( dvector u,
dCSRmat A,
dvector b,
INT  L,
INT mark,
const INT  order 
)

Gauss-Seidel smoother with C/F ordering for Au=b.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
markC/F marker array
orderC/F ordering: -1: F-first; 1: C-first
Author
Zhiyang Zhou
Date
11/12/2010

Modified by Chunsheng Feng, Xiaoqiang Yue on 05/24/2012

Definition at line 364 of file smoother_csr.c.

void fasp_smoother_dcsr_gs_rb3d ( dvector u,
dCSRmat A,
dvector b,
INT  L,
const INT  order,
INT mark,
const INT  maximap,
const INT  nx,
const INT  ny,
const INT  nz 
)

Colored Gauss-Seidel smoother for Au=b.

Parameters
uInitial guess and the new approximation to the solution
APointer to stiffness matrix
bPointer to right hand side
LNumber of iterations
orderOrdering: -1: Forward; 1: Backward
markMarker for C/F points
maximapSize of IMAP
nxNumber vertex of X direction
nyNumber vertex of Y direction
nzNumber vertex of Z direction
Author
Chunsheng Feng
Date
02/08/2012

Definition at line 1425 of file smoother_csr.c.

void fasp_smoother_dcsr_ilu ( dCSRmat A,
dvector b,
dvector x,
void *  data 
)

ILU method as a smoother.

Parameters
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
xPointer to dvector: the unknowns (IN: initial, OUT: approximation)
dataPointer to user defined data
Author
Shiquan Zhang, Xiaozhe Hu
Date
2010/11/12

form residual zr = b - A x

Definition at line 1067 of file smoother_csr.c.

void fasp_smoother_dcsr_jacobi ( dvector u,
const INT  i_1,
const INT  i_n,
const INT  s,
dCSRmat A,
dvector b,
INT  L 
)

Jacobi method as a smoother.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
i_1Starting index
i_nEnding index
sIncreasing step
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
Author
Xuehai Huang, Chensong Zhang
Date
09/26/2009

Modified by Chunsheng Feng, Zheng Li on 08/29/2012

Definition at line 59 of file smoother_csr.c.

void fasp_smoother_dcsr_kaczmarz ( dvector u,
const INT  i_1,
const INT  i_n,
const INT  s,
dCSRmat A,
dvector b,
INT  L,
const REAL  w 
)

Kaczmarz method as a smoother.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
i_1Starting index
i_nEnding index
sIncreasing step
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
wOver-relaxation weight
Author
Xiaozhe Hu
Date
2010/11/12

Modified by Chunsheng Feng, Zheng Li on 2012/09/01

Definition at line 1145 of file smoother_csr.c.

void fasp_smoother_dcsr_L1diag ( dvector u,
const INT  i_1,
const INT  i_n,
const INT  s,
dCSRmat A,
dvector b,
INT  L 
)

Diagonal scaling (using L1 norm) as a smoother.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
i_1Starting index
i_nEnding index
sIncreasing step
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
Author
Xiaozhe Hu, James Brannick
Date
01/26/2011

Modified by Chunsheng Feng, Zheng Li on 09/01/2012

Definition at line 1286 of file smoother_csr.c.

void fasp_smoother_dcsr_sgs ( dvector u,
dCSRmat A,
dvector b,
INT  L 
)

Symmetric Gauss-Seidel method as a smoother.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
Author
Xiaozhe Hu
Date
10/26/2010

Modified by Chunsheng Feng, Zheng Li on 09/01/2012

Definition at line 629 of file smoother_csr.c.

void fasp_smoother_dcsr_sor ( dvector u,
const INT  i_1,
const INT  i_n,
const INT  s,
dCSRmat A,
dvector b,
INT  L,
const REAL  w 
)

SOR method as a smoother.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
i_1Starting index
i_nEnding index
sIncreasing step
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
wOver-relaxation weight
Author
Xiaozhe Hu
Date
10/26/2010

Modified by Chunsheng Feng, Zheng Li on 09/01/2012

Definition at line 745 of file smoother_csr.c.

void fasp_smoother_dcsr_sor_cf ( dvector u,
dCSRmat A,
dvector b,
INT  L,
const REAL  w,
INT mark,
const INT  order 
)

SOR smoother with C/F ordering for Au=b.

Parameters
uPointer to dvector: the unknowns (IN: initial, OUT: approximation)
APointer to dBSRmat: the coefficient matrix
bPointer to dvector: the right hand side
LNumber of iterations
wOver-relaxation weight
markC/F marker array
orderC/F ordering: -1: F-first; 1: C-first
Author
Zhiyang Zhou
Date
2010/11/12

Modified by Chunsheng Feng, Zheng Li on 08/29/2012

Definition at line 873 of file smoother_csr.c.