Fast Auxiliary Space Preconditioning 2.7.7 Aug/28/2022
Loading...
Searching...
No Matches
ItrSmootherSTR.c File Reference

Smoothers for dSTRmat matrices. More...

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

Go to the source code of this file.

Functions

void fasp_smoother_dstr_jacobi (dSTRmat *A, dvector *b, dvector *u)
 Jacobi method as the smoother. More...
 
void fasp_smoother_dstr_jacobi1 (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv)
 Jacobi method as the smoother with diag_inv given. More...
 
void fasp_smoother_dstr_gs (dSTRmat *A, dvector *b, dvector *u, const INT order, INT *mark)
 Gauss-Seidel method as the smoother. More...
 
void fasp_smoother_dstr_gs1 (dSTRmat *A, dvector *b, dvector *u, const INT order, INT *mark, REAL *diaginv)
 Gauss-Seidel method as the smoother with diag_inv given. More...
 
void fasp_smoother_dstr_gs_ascend (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv)
 Gauss-Seidel method as the smoother in the ascending manner. More...
 
void fasp_smoother_dstr_gs_descend (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv)
 Gauss-Seidel method as the smoother in the descending manner. More...
 
void fasp_smoother_dstr_gs_order (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv, INT *mark)
 Gauss method as the smoother in the user-defined order. More...
 
void fasp_smoother_dstr_gs_cf (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv, INT *mark, const INT order)
 Gauss method as the smoother in the C-F manner. More...
 
void fasp_smoother_dstr_sor (dSTRmat *A, dvector *b, dvector *u, const INT order, INT *mark, const REAL weight)
 SOR method as the smoother. More...
 
void fasp_smoother_dstr_sor1 (dSTRmat *A, dvector *b, dvector *u, const INT order, INT *mark, REAL *diaginv, const REAL weight)
 SOR method as the smoother. More...
 
void fasp_smoother_dstr_sor_ascend (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv, REAL weight)
 SOR method as the smoother in the ascending manner. More...
 
void fasp_smoother_dstr_sor_descend (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv, REAL weight)
 SOR method as the smoother in the descending manner. More...
 
void fasp_smoother_dstr_sor_order (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv, INT *mark, REAL weight)
 SOR method as the smoother in the user-defined order. More...
 
void fasp_smoother_dstr_sor_cf (dSTRmat *A, dvector *b, dvector *u, REAL *diaginv, INT *mark, const INT order, const REAL weight)
 SOR method as the smoother in the C-F manner. More...
 
void fasp_generate_diaginv_block (dSTRmat *A, ivector *neigh, dvector *diaginv, ivector *pivot)
 Generate inverse of diagonal block for block smoothers. More...
 
void fasp_smoother_dstr_swz (dSTRmat *A, dvector *b, dvector *u, dvector *diaginv, ivector *pivot, ivector *neigh, ivector *order)
 

Detailed Description

Smoothers for dSTRmat matrices.

Note
This file contains Level-2 (Itr) functions. It requires: AuxArray.c, AuxMemory.c, AuxMessage.c, BlaSmallMat.c, BlaSmallMatInv.c, BlaSmallMatLU.c, and BlaSpmvSTR.c

Copyright (C) 2009–Present by the FASP team. All rights reserved.

Released under the terms of the GNU Lesser General Public License 3.0 or later.

Definition in file ItrSmootherSTR.c.

Function Documentation

◆ fasp_generate_diaginv_block()

void fasp_generate_diaginv_block ( dSTRmat A,
ivector neigh,
dvector diaginv,
ivector pivot 
)

Generate inverse of diagonal block for block smoothers.

Parameters
APointer to dCSRmat: the coefficient matrix
neighPointer to ivector: neighborhoods
diaginvPointer to dvector: the inverse of the diagonals
pivotPointer to ivector: the pivot of diagonal blocks
Author
Xiaozhe Hu
Date
10/01/2011

Definition at line 1543 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_gs()

void fasp_smoother_dstr_gs ( dSTRmat A,
dvector b,
dvector u,
const INT  order,
INT mark 
)

Gauss-Seidel method as the smoother.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
orderFlag to indicate the order for smoothing If mark = NULL ASCEND 12: in ascending manner DESCEND 21: in descending manner If mark != NULL USERDEFINED 0 : in the user-defined manner CPFIRST 1 : C-points first and then F-points FPFIRST -1 : F-points first and then C-points
markPointer to the user-defined ordering(when order=0) or CF_marker array(when order!=0)
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 217 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_gs1()

void fasp_smoother_dstr_gs1 ( dSTRmat A,
dvector b,
dvector u,
const INT  order,
INT mark,
REAL diaginv 
)

Gauss-Seidel method as the smoother with diag_inv given.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
orderFlag to indicate the order for smoothing If mark = NULL ASCEND 12: in ascending manner DESCEND 21: in descending manner If mark != NULL USERDEFINED 0 : in the user-defined manner CPFIRST 1 : C-points first and then F-points FPFIRST -1 : F-points first and then C-points
markPointer to the user-defined ordering(when order=0) or CF_marker array(when order!=0)
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 277 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_gs_ascend()

void fasp_smoother_dstr_gs_ascend ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv 
)

Gauss-Seidel method as the smoother in the ascending manner.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 322 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_gs_cf()

void fasp_smoother_dstr_gs_cf ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv,
INT mark,
const INT  order 
)

Gauss method as the smoother in the C-F manner.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
markPointer to the user-defined order array
orderFlag to indicate the order for smoothing CPFIRST 1 : C-points first and then F-points FPFIRST -1 : F-points first and then C-points
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 680 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_gs_descend()

void fasp_smoother_dstr_gs_descend ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv 
)

Gauss-Seidel method as the smoother in the descending manner.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 438 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_gs_order()

void fasp_smoother_dstr_gs_order ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv,
INT mark 
)

Gauss method as the smoother in the user-defined order.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
markPointer to the user-defined order array
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 556 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_jacobi()

void fasp_smoother_dstr_jacobi ( dSTRmat A,
dvector b,
dvector u 
)

Jacobi method as the smoother.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 43 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_jacobi1()

void fasp_smoother_dstr_jacobi1 ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv 
)

Jacobi method as the smoother with diag_inv given.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 92 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_sor()

void fasp_smoother_dstr_sor ( dSTRmat A,
dvector b,
dvector u,
const INT  order,
INT mark,
const REAL  weight 
)

SOR method as the smoother.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
orderFlag to indicate the order for smoothing If mark = NULL
ASCEND 12: in ascending manner DESCEND 21: in descending manner If mark != NULL USERDEFINED 0 : in the user-defined manner CPFIRST 1 : C-points first and then F-points FPFIRST -1 : F-points first and then C-points
markPointer to the user-defined ordering(when order=0) or CF_marker array(when order!=0)
weightOver-relaxation weight
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 873 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_sor1()

void fasp_smoother_dstr_sor1 ( dSTRmat A,
dvector b,
dvector u,
const INT  order,
INT mark,
REAL diaginv,
const REAL  weight 
)

SOR method as the smoother.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
orderFlag to indicate the order for smoothing If mark = NULL ASCEND 12: in ascending manner DESCEND 21: in descending manner If mark != NULL USERDEFINED 0 : in the user-defined manner CPFIRST 1 : C-points first and then F-points FPFIRST -1 : F-points first and then C-points
markPointer to the user-defined ordering(when order=0) or CF_marker array(when order!=0)
diaginvInverse of the diagonal entries
weightOver-relaxation weight
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 935 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_sor_ascend()

void fasp_smoother_dstr_sor_ascend ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv,
REAL  weight 
)

SOR method as the smoother in the ascending manner.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
weightOver-relaxation weight
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 981 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_sor_cf()

void fasp_smoother_dstr_sor_cf ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv,
INT mark,
const INT  order,
const REAL  weight 
)

SOR method as the smoother in the C-F manner.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
markPointer to the user-defined order array
orderFlag to indicate the order for smoothing CPFIRST 1 : C-points first and then F-points FPFIRST -1 : F-points first and then C-points
weightOver-relaxation weight
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 1355 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_sor_descend()

void fasp_smoother_dstr_sor_descend ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv,
REAL  weight 
)

SOR method as the smoother in the descending manner.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
weightOver-relaxation weight
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 1102 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_sor_order()

void fasp_smoother_dstr_sor_order ( dSTRmat A,
dvector b,
dvector u,
REAL diaginv,
INT mark,
REAL  weight 
)

SOR method as the smoother in the user-defined order.

Parameters
APointer to dCSRmat: the coefficient matrix
bPointer to dvector: the right hand side
uPointer to dvector: the unknowns
diaginvAll the inverse matrices for all the diagonal block of A when (A->nc)>1, and NULL when (A->nc)=1
markPointer to the user-defined order array
weightOver-relaxation weight
Author
Shiquan Zhang, Zhiyang Zhou
Date
10/10/2010

Definition at line 1224 of file ItrSmootherSTR.c.

◆ fasp_smoother_dstr_swz()

void fasp_smoother_dstr_swz ( dSTRmat A,
dvector b,
dvector u,
dvector diaginv,
ivector pivot,
ivector neigh,
ivector order 
)

Definition at line 1665 of file ItrSmootherSTR.c.