Preconditioner.h
Go to the documentation of this file.
/*****************************************************************************
*
* Copyright (c) 2003-2017 by The University of Queensland
* http://www.uq.edu.au
*
* Primary Business: Queensland, Australia
* Licensed under the Apache License, version 2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Development until 2012 by Earth Systems Science Computational Center (ESSCC)
* Development 2012-2013 by School of Earth Sciences
* Development from 2014 by Centre for Geoscience Computing (GeoComp)
*
*****************************************************************************/
#ifndef __PASO_PRECONDITIONER_H__
#define __PASO_PRECONDITIONER_H__
#include "Paso.h"
#include "BOOMERAMG.h"
#include "SystemMatrix.h"
namespace paso {
struct MergedSolver;
struct Preconditioner;
typedef boost::shared_ptr<Preconditioner> Preconditioner_ptr;
typedef boost::shared_ptr<const Preconditioner> const_Preconditioner_ptr;
struct Preconditioner_Smoother;
struct Preconditioner_AMG_Root;
struct Solver_ILU;
struct Solver_RILU;
// general preconditioner interface
struct Preconditioner
{
dim_t type;
dim_t sweeps;
Preconditioner_Smoother* jacobi;
Preconditioner_Smoother* gs;
Preconditioner_AMG_Root* amg;
Solver_ILU* ilu;
Solver_RILU* rilu;
};
void Preconditioner_free(Preconditioner*);
Preconditioner* Preconditioner_alloc(SystemMatrix_ptr A, Options* options);
void Preconditioner_solve(Preconditioner* prec, SystemMatrix_ptr A, double*, double*);
// GAUSS SEIDEL & Jacobi
struct Preconditioner_LocalSmoother
{
bool Jacobi;
double* diag;
double* buffer;
index_t* pivot;
};
struct Preconditioner_Smoother
{
Preconditioner_LocalSmoother* localSmoother;
bool is_local;
};
void Preconditioner_Smoother_free(Preconditioner_Smoother * in);
void Preconditioner_LocalSmoother_free(Preconditioner_LocalSmoother * in);
Preconditioner_Smoother* Preconditioner_Smoother_alloc(
SystemMatrix_ptr A, bool jacobi, bool is_local, bool verbose);
Preconditioner_LocalSmoother* Preconditioner_LocalSmoother_alloc(
SparseMatrix_ptr A, bool jacobi, bool verbose);
void Preconditioner_Smoother_solve(SystemMatrix_ptr A,
Preconditioner_Smoother* gs, double* x, const double* b,
dim_t sweeps, bool x_is_initial);
void Preconditioner_LocalSmoother_solve(SparseMatrix_ptr A,
Preconditioner_LocalSmoother* gs, double* x, const double* b,
dim_t sweeps, bool x_is_initial);
SolverResult Preconditioner_Smoother_solve_byTolerance(SystemMatrix_ptr A,
Preconditioner_Smoother* gs, double* x, const double* b,
double atol, dim_t* sweeps, bool x_is_initial);
void Preconditioner_LocalSmoother_Sweep(SparseMatrix_ptr A,
Preconditioner_LocalSmoother* gs, double* x);
void Preconditioner_LocalSmoother_Sweep_sequential(
SparseMatrix_ptr A, Preconditioner_LocalSmoother* gs,
double* x);
void Preconditioner_LocalSmoother_Sweep_tiled(SparseMatrix_ptr A,
Preconditioner_LocalSmoother* gs, double* x);
void Preconditioner_LocalSmoother_Sweep_colored(SparseMatrix_ptr A,
Preconditioner_LocalSmoother* gs, double* x);
typedef enum
{
PASO_AMG_UNDECIDED=-1,
PASO_AMG_IN_F=0,
PASO_AMG_IN_C=1
} AMGBlockSelect;
struct Preconditioner_AMG
{
int level;
SystemMatrix_ptr A_C;
SystemMatrix_ptr P;
SystemMatrix_ptr R;
Preconditioner_Smoother* Smoother;
int post_sweeps;
int pre_sweeps;
dim_t options_smoother;
bool verbose;
index_t reordering;
int refinements;
double* r;
double* x_C;
double* b_C;
MergedSolver* merged_solver;
Preconditioner_AMG* AMG_C;
};
Preconditioner_AMG* Preconditioner_AMG_alloc(SystemMatrix_ptr A, int level,
Options* options);
void Preconditioner_AMG_free(Preconditioner_AMG* in);
void Preconditioner_AMG_solve(SystemMatrix_ptr A, Preconditioner_AMG* amg,
double* x, double* b);
void Preconditioner_AMG_setStrongConnections(SystemMatrix_ptr A,
dim_t* degree_S, index_t* offset_S, index_t* S,
double theta, double tau);
void Preconditioner_AMG_setStrongConnections_Block(SystemMatrix_ptr A,
dim_t* degree_S, index_t* offset_S, index_t* S,
double theta, double tau);
SystemMatrix_ptr Preconditioner_AMG_getProlongation(SystemMatrix_ptr A,
const index_t* offset_S, const dim_t* degree_S,
const index_t* S, dim_t n_C, index_t* counter_C,
index_t interpolation_method);
void Preconditioner_AMG_setClassicProlongation(SystemMatrix_ptr P,
SystemMatrix_ptr A, const index_t* offset_S,
const dim_t* degree_S, const index_t* S,
const index_t* counter_C);
void Preconditioner_AMG_setClassicProlongation_Block(SystemMatrix_ptr P,
SystemMatrix_ptr A, const index_t* offset_S,
const dim_t* degree_S, const index_t* S,
const index_t* counter_C);
void Preconditioner_AMG_setDirectProlongation(SystemMatrix_ptr P,
SystemMatrix_ptr A, const index_t* offset_S,
const dim_t* degree_S, const index_t* S,
const index_t* counter_C);
void Preconditioner_AMG_setDirectProlongation_Block(SystemMatrix_ptr P,
SystemMatrix_ptr A, const index_t* offset_S,
const dim_t* degree_S, const index_t* S,
const index_t* counter_C);
double Preconditioner_AMG_getCoarseLevelSparsity(const Preconditioner_AMG* in);
dim_t Preconditioner_AMG_getNumCoarseUnknowns(const Preconditioner_AMG* in);
int Preconditioner_AMG_getMaxLevel(const Preconditioner_AMG* in);
void Preconditioner_AMG_transposeStrongConnections(dim_t n,
const dim_t* degree_S, const index_t* offset_S,
const index_t* S, dim_t nT, dim_t* degree_ST,
index_t* offset_ST, index_t* ST);
void Preconditioner_AMG_CIJPCoarsening(dim_t n, dim_t my_n,
AMGBlockSelect* split_marker, const dim_t* degree_S,
const index_t* offset_S, const index_t* S,
const dim_t* degree_ST, const index_t* offset_ST,
const index_t* ST, const_Connector_ptr col_connector,
escript::const_Distribution_ptr col_dist);
SystemMatrix_ptr Preconditioner_AMG_getRestriction(SystemMatrix_ptr P);
SystemMatrix_ptr Preconditioner_AMG_buildInterpolationOperator(
SystemMatrix_ptr A, SystemMatrix_ptr P, SystemMatrix_ptr R);
SystemMatrix_ptr Preconditioner_AMG_buildInterpolationOperatorBlock(
SystemMatrix_ptr A, SystemMatrix_ptr P, SystemMatrix_ptr R);
SparseMatrix_ptr Preconditioner_AMG_mergeSystemMatrix(SystemMatrix_ptr A);
void Preconditioner_AMG_mergeSolve(Preconditioner_AMG* amg);
struct Preconditioner_LocalAMG
{
dim_t level;
SparseMatrix_ptr A_C; // coarse level matrix
SparseMatrix_ptr P; // prolongation n x n_C
SparseMatrix_ptr R; // restriction n_C x n
Preconditioner_LocalSmoother* Smoother;
int post_sweeps;
int pre_sweeps;
index_t reordering; // applied reordering in direct solver
int refinements; // number of refinements in direct solver (typically=0)
double* r; // buffer for residual
double* x_C; // solution of coarse level system
double* b_C; // right hand side of coarse level system
struct Preconditioner_LocalAMG* AMG_C;
};
Preconditioner_LocalAMG* Preconditioner_LocalAMG_alloc(SparseMatrix_ptr A,
int level, Options* options);
void Preconditioner_LocalAMG_free(Preconditioner_LocalAMG* in);
void Preconditioner_LocalAMG_solve(SparseMatrix_ptr A,
Preconditioner_LocalAMG* amg, double* x, double* b);
void Preconditioner_LocalAMG_RungeStuebenSearch(dim_t n, const index_t* offset,
const dim_t* degree, const index_t* S,
AMGBlockSelect* split_marker, bool usePanel);
void Preconditioner_LocalAMG_setStrongConnections_Block(SparseMatrix_ptr A,
dim_t* degree, index_t* S, double theta, double tau);
void Preconditioner_LocalAMG_setStrongConnections(SparseMatrix_ptr A,
dim_t* degree, index_t* S, double theta, double tau);
SparseMatrix_ptr Preconditioner_LocalAMG_getProlongation(SparseMatrix_ptr A,
const index_t* offset_S, const dim_t* degree_S,
const index_t* S, dim_t n_C, const index_t* counter_C,
index_t interpolation_method);
void Preconditioner_LocalAMG_setDirectProlongation_Block(SparseMatrix_ptr P,
const_SparseMatrix_ptr A, const index_t* counter_C);
void Preconditioner_LocalAMG_setDirectProlongation(SparseMatrix_ptr P,
const_SparseMatrix_ptr A, const index_t* counter_C);
void Preconditioner_LocalAMG_setClassicProlongation(SparseMatrix_ptr P,
SparseMatrix_ptr A, const index_t* offset_S,
const dim_t* degree_S, const index_t* S,
const index_t* counter_C);
void Preconditioner_LocalAMG_setClassicProlongation_Block(SparseMatrix_ptr P,
SparseMatrix_ptr A, const index_t* offset_S,
const dim_t* degree_S, const index_t* S,
const index_t* counter_C);
int Preconditioner_LocalAMG_getMaxLevel(const Preconditioner_LocalAMG* in);
double Preconditioner_LocalAMG_getCoarseLevelSparsity(const Preconditioner_LocalAMG* in);
dim_t Preconditioner_LocalAMG_getNumCoarseUnknowns(const Preconditioner_LocalAMG* in);
void Preconditioner_LocalAMG_enforceFFConnectivity(dim_t n,
const index_t* offset_S, const dim_t* degree_S,
const index_t* S, AMGBlockSelect* split_marker);
struct Preconditioner_AMG_Root
{
bool is_local;
Preconditioner_AMG* amg;
Preconditioner_LocalAMG* localamg;
Preconditioner_BoomerAMG* boomeramg;
int sweeps;
Preconditioner_Smoother* amgsubstitute;
};
Preconditioner_AMG_Root* Preconditioner_AMG_Root_alloc(SystemMatrix_ptr A,
Options* options);
void Preconditioner_AMG_Root_free(Preconditioner_AMG_Root* in);
void Preconditioner_AMG_Root_solve(SystemMatrix_ptr A,
Preconditioner_AMG_Root* amg, double* x, double* b);
struct Solver_ILU
{
double* factors;
};
struct Solver_RILU
{
dim_t n;
dim_t n_block;
dim_t n_F;
dim_t n_C;
double* inv_A_FF;
index_t* A_FF_pivot;
SparseMatrix_ptr A_FC;
SparseMatrix_ptr A_CF;
index_t* rows_in_F;
index_t* rows_in_C;
index_t* mask_F;
index_t* mask_C;
double* x_F;
double* b_F;
double* x_C;
double* b_C;
Solver_RILU* RILU_of_Schur;
};
void Solver_ILU_free(Solver_ILU * in);
Solver_ILU* Solver_getILU(SparseMatrix_ptr A, bool verbose);
void Solver_solveILU(SparseMatrix_ptr A, Solver_ILU* ilu, double* x, const double* b);
void Solver_RILU_free(Solver_RILU* in);
Solver_RILU* Solver_getRILU(SparseMatrix_ptr A, bool verbose);
void Solver_solveRILU(Solver_RILU* rilu, double* x, double* b);
void Solver_updateIncompleteSchurComplement(SparseMatrix_ptr A_CC,
SparseMatrix_ptr A_CF, double* invA_FF, index_t* A_FF_pivot,
SparseMatrix_ptr A_FC);
} // namespace paso
#endif // __PASO_PRECONDITIONER_H__
paso::Solver_RILU::RILU_of_Schur
Solver_RILU * RILU_of_Schur
Definition: Preconditioner.h:323
paso::Preconditioner_AMG_Root::is_local
bool is_local
Definition: Preconditioner.h:284
paso::Solver_getRILU
Solver_RILU * Solver_getRILU(SparseMatrix_ptr A, bool verbose)
Definition: RILU.cpp:71
paso::Preconditioner_Smoother_free
void Preconditioner_Smoother_free(Preconditioner_Smoother *in)
Definition: Smoother.cpp:34
paso::Preconditioner_Smoother_solve
void Preconditioner_Smoother_solve(SystemMatrix_ptr A, Preconditioner_Smoother *gs, double *x, const double *b, dim_t sweeps, bool x_is_initial)
Definition: Smoother.cpp:100
paso::Preconditioner::type
dim_t type
Definition: Preconditioner.h:39
paso::Preconditioner_AMG::AMG_C
Preconditioner_AMG * AMG_C
Definition: Preconditioner.h:145
paso::Preconditioner_AMG_Root::boomeramg
Preconditioner_BoomerAMG * boomeramg
Definition: Preconditioner.h:287
paso::Preconditioner_AMG_getRestriction
SystemMatrix_ptr Preconditioner_AMG_getRestriction(SystemMatrix_ptr P)
Definition: AMG_Restriction.cpp:47
paso::Solver_RILU::inv_A_FF
double * inv_A_FF
Definition: Preconditioner.h:311
Paso.h
paso::Preconditioner_LocalAMG::P
SparseMatrix_ptr P
Definition: Preconditioner.h:223
paso::Preconditioner_LocalSmoother_free
void Preconditioner_LocalSmoother_free(Preconditioner_LocalSmoother *in)
Definition: Smoother.cpp:42
paso::AMGBlockSelect
AMGBlockSelect
Definition: Preconditioner.h:108
paso::const_SparseMatrix_ptr
boost::shared_ptr< const SparseMatrix > const_SparseMatrix_ptr
Definition: SparseMatrix.h:37
paso::Preconditioner_LocalAMG_solve
void Preconditioner_LocalAMG_solve(SparseMatrix_ptr A, Preconditioner_LocalAMG *amg, double *x, double *b)
Definition: LocalAMG.cpp:308
paso::Preconditioner_LocalAMG_getCoarseLevelSparsity
double Preconditioner_LocalAMG_getCoarseLevelSparsity(const Preconditioner_LocalAMG *in)
Definition: LocalAMG.cpp:63
paso::Preconditioner_LocalAMG::post_sweeps
int post_sweeps
Definition: Preconditioner.h:227
paso::PASO_AMG_UNDECIDED
Definition: Preconditioner.h:110
paso::Preconditioner_AMG::A_C
SystemMatrix_ptr A_C
coarse level matrix
Definition: Preconditioner.h:120
paso::Solver_RILU::rows_in_C
index_t * rows_in_C
Definition: Preconditioner.h:316
paso::Preconditioner_AMG_Root::amgsubstitute
Preconditioner_Smoother * amgsubstitute
Definition: Preconditioner.h:289
paso::Preconditioner_LocalAMG::b_C
double * b_C
Definition: Preconditioner.h:233
paso::Preconditioner_AMG_Root
Definition: Preconditioner.h:282
paso::Preconditioner_AMG_mergeSystemMatrix
SparseMatrix_ptr Preconditioner_AMG_mergeSystemMatrix(SystemMatrix_ptr A)
paso::Solver_RILU::x_C
double * x_C
Definition: Preconditioner.h:321
paso::Preconditioner_LocalAMG_setStrongConnections
void Preconditioner_LocalAMG_setStrongConnections(SparseMatrix_ptr A, dim_t *degree_S, index_t *S, const double theta, const double tau)
Definition: LocalAMG.cpp:375
paso::Preconditioner_AMG_solve
void Preconditioner_AMG_solve(SystemMatrix_ptr A, Preconditioner_AMG *amg, double *x, double *b)
Definition: AMG.cpp:321
paso::Preconditioner_LocalSmoother_Sweep_colored
void Preconditioner_LocalSmoother_Sweep_colored(SparseMatrix_ptr A, Preconditioner_LocalSmoother *gs, double *x)
Definition: Smoother.cpp:338
SystemMatrix.h
paso::Preconditioner_AMG::x_C
double * x_C
solution of coarse level system
Definition: Preconditioner.h:140
paso::Options
Definition: Options.h:89
paso::Preconditioner_BoomerAMG
Definition: BOOMERAMG.h:44
paso::Preconditioner_AMG_Root::localamg
Preconditioner_LocalAMG * localamg
Definition: Preconditioner.h:286
paso::Solver_ILU_free
void Solver_ILU_free(Solver_ILU *in)
Definition: ILU.cpp:35
paso::Preconditioner_alloc
Preconditioner * Preconditioner_alloc(SystemMatrix_ptr A, Options *options)
Definition: Preconditioner.cpp:47
paso::Preconditioner_AMG_getNumCoarseUnknowns
dim_t Preconditioner_AMG_getNumCoarseUnknowns(const Preconditioner_AMG *in)
Definition: AMG.cpp:99
paso::Preconditioner_LocalSmoother::pivot
index_t * pivot
Definition: Preconditioner.h:64
paso::Preconditioner_AMG_Root_solve
void Preconditioner_AMG_Root_solve(SystemMatrix_ptr A, Preconditioner_AMG_Root *prec, double *x, double *b)
Definition: AMG_Root.cpp:119
paso::Preconditioner_LocalAMG::x_C
double * x_C
Definition: Preconditioner.h:232
paso::Preconditioner::jacobi
Preconditioner_Smoother * jacobi
Jacobi preconditioner.
Definition: Preconditioner.h:42
paso::Preconditioner_LocalAMG_setClassicProlongation
void Preconditioner_LocalAMG_setClassicProlongation(SparseMatrix_ptr P_p, SparseMatrix_ptr A_p, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const index_t *counter_C)
Definition: LocalAMG_Prolongation.cpp:355
paso::Preconditioner_AMG_Root_free
void Preconditioner_AMG_Root_free(Preconditioner_AMG_Root *in)
Definition: AMG_Root.cpp:37
paso::Preconditioner::amg
Preconditioner_AMG_Root * amg
AMG preconditioner.
Definition: Preconditioner.h:46
paso::Preconditioner_LocalAMG_setStrongConnections_Block
void Preconditioner_LocalAMG_setStrongConnections_Block(SparseMatrix_ptr A, dim_t *degree_S, index_t *S, double theta, double tau)
Definition: LocalAMG.cpp:423
paso::Solver_RILU::b_F
double * b_F
Definition: Preconditioner.h:320
paso::Preconditioner_AMG_setStrongConnections_Block
void Preconditioner_AMG_setStrongConnections_Block(SystemMatrix_ptr A, dim_t *degree_S, index_t *offset_S, index_t *S, double theta, double tau)
Definition: AMG.cpp:494
paso::Preconditioner_LocalSmoother_Sweep
void Preconditioner_LocalSmoother_Sweep(SparseMatrix_ptr A, Preconditioner_LocalSmoother *gs, double *x)
Definition: Smoother.cpp:201
paso::Solver_updateIncompleteSchurComplement
void Solver_updateIncompleteSchurComplement(SparseMatrix_ptr A_CC, SparseMatrix_ptr A_CF, double *invA_FF, index_t *A_FF_pivot, SparseMatrix_ptr A_FC)
Definition: SchurComplement.cpp:28
paso::Preconditioner_Smoother::is_local
bool is_local
Definition: Preconditioner.h:70
paso::Preconditioner_LocalAMG::refinements
int refinements
Definition: Preconditioner.h:230
BOOMERAMG.h
paso::Preconditioner_LocalAMG_alloc
Preconditioner_LocalAMG * Preconditioner_LocalAMG_alloc(SparseMatrix_ptr A_p, int level, Options *options)
Definition: LocalAMG.cpp:92
paso::Preconditioner_AMG::r
double * r
buffer for residual
Definition: Preconditioner.h:138
paso::PASO_AMG_IN_C
Definition: Preconditioner.h:112
paso::Preconditioner_LocalSmoother_alloc
Preconditioner_LocalSmoother * Preconditioner_LocalSmoother_alloc(SparseMatrix_ptr A, bool jacobi, bool verbose)
Definition: Smoother.cpp:64
paso::Preconditioner_LocalAMG_enforceFFConnectivity
void Preconditioner_LocalAMG_enforceFFConnectivity(dim_t n, const index_t *offset_S, const dim_t *degree_S, const index_t *S, AMGBlockSelect *split_marker)
ensures that two F nodes are connected via a C node
Definition: LocalAMG.cpp:702
paso::Preconditioner_Smoother_solve_byTolerance
SolverResult Preconditioner_Smoother_solve_byTolerance(SystemMatrix_ptr A, Preconditioner_Smoother *gs, double *x, const double *b, double atol, dim_t *sweeps, bool x_is_initial)
Definition: Smoother.cpp:127
paso::Preconditioner_LocalAMG::pre_sweeps
int pre_sweeps
Definition: Preconditioner.h:228
paso::Preconditioner_AMG::post_sweeps
int post_sweeps
Definition: Preconditioner.h:127
paso::Preconditioner_LocalAMG::level
dim_t level
Definition: Preconditioner.h:221
paso::Preconditioner_LocalSmoother_solve
void Preconditioner_LocalSmoother_solve(SparseMatrix_ptr A, Preconditioner_LocalSmoother *gs, double *x, const double *b, dim_t sweeps, bool x_is_initial)
Definition: Smoother.cpp:161
paso::SparseMatrix_ptr
boost::shared_ptr< SparseMatrix > SparseMatrix_ptr
Definition: SparseMatrix.h:35
paso::Preconditioner_LocalAMG_setDirectProlongation_Block
void Preconditioner_LocalAMG_setDirectProlongation_Block(SparseMatrix_ptr P_p, const_SparseMatrix_ptr A_p, const index_t *counter_C)
Definition: LocalAMG_Prolongation.cpp:227
paso::Preconditioner_ptr
boost::shared_ptr< Preconditioner > Preconditioner_ptr
Definition: Preconditioner.h:27
paso::Preconditioner_LocalAMG::AMG_C
struct Preconditioner_LocalAMG * AMG_C
Definition: Preconditioner.h:234
paso::Solver_RILU::mask_F
index_t * mask_F
Definition: Preconditioner.h:317
paso::Solver_solveRILU
void Solver_solveRILU(Solver_RILU *rilu, double *x, double *b)
Definition: RILU.cpp:289
paso::Preconditioner::rilu
Solver_RILU * rilu
RILU preconditioner.
Definition: Preconditioner.h:50
paso::Preconditioner_LocalSmoother_Sweep_sequential
void Preconditioner_LocalSmoother_Sweep_sequential(SparseMatrix_ptr A, Preconditioner_LocalSmoother *gs, double *x)
inplace Gauss-Seidel sweep in sequential mode
Definition: Smoother.cpp:221
paso::Preconditioner_LocalAMG::R
SparseMatrix_ptr R
Definition: Preconditioner.h:224
paso::SystemMatrix_ptr
boost::shared_ptr< SystemMatrix > SystemMatrix_ptr
Definition: SystemMatrix.h:40
paso::Preconditioner_LocalAMG::reordering
index_t reordering
Definition: Preconditioner.h:229
paso::Solver_getILU
Solver_ILU * Solver_getILU(SparseMatrix_ptr A, bool verbose)
constructs the incomplete block factorization
Definition: ILU.cpp:44
paso::Preconditioner_AMG_getCoarseLevelSparsity
double Preconditioner_AMG_getCoarseLevelSparsity(const Preconditioner_AMG *in)
Definition: AMG.cpp:87
paso::Preconditioner::gs
Preconditioner_Smoother * gs
Gauss-Seidel preconditioner.
Definition: Preconditioner.h:44
paso::Preconditioner_AMG_Root_alloc
Preconditioner_AMG_Root * Preconditioner_AMG_Root_alloc(SystemMatrix_ptr A, Options *options)
Definition: AMG_Root.cpp:48
paso
Definition: AMG.cpp:45
paso::Preconditioner_LocalAMG_getNumCoarseUnknowns
dim_t Preconditioner_LocalAMG_getNumCoarseUnknowns(const Preconditioner_LocalAMG *in)
Definition: LocalAMG.cpp:75
paso::Preconditioner_LocalAMG_setClassicProlongation_Block
void Preconditioner_LocalAMG_setClassicProlongation_Block(SparseMatrix_ptr P_p, SparseMatrix_ptr A_p, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const index_t *counter_C)
Definition: LocalAMG_Prolongation.cpp:451
paso::Solver_RILU::n_block
dim_t n_block
Definition: Preconditioner.h:308
paso::Preconditioner_Smoother_alloc
Preconditioner_Smoother * Preconditioner_Smoother_alloc(SystemMatrix_ptr A, bool jacobi, bool is_local, bool verbose)
constructs the symmetric Gauss-Seidel preconditioner
Definition: Smoother.cpp:54
paso::Preconditioner_LocalSmoother_Sweep_tiled
void Preconditioner_LocalSmoother_Sweep_tiled(SparseMatrix_ptr A, Preconditioner_LocalSmoother *gs, double *x)
escript::DataTypes::index_t
int index_t
type for array/matrix indices used both globally and on each rank
Definition: DataTypes.h:59
paso::Solver_RILU::A_CF
SparseMatrix_ptr A_CF
Definition: Preconditioner.h:314
paso::Preconditioner_LocalAMG
Local AMG preconditioner.
Definition: Preconditioner.h:219
paso::Solver_ILU
ILU preconditioner.
Definition: Preconditioner.h:299
paso::Preconditioner_AMG_CIJPCoarsening
void Preconditioner_AMG_CIJPCoarsening(dim_t n, dim_t my_n, AMGBlockSelect *split_marker, const dim_t *degree_S, const index_t *offset_S, const index_t *S, const dim_t *degree_ST, const index_t *offset_ST, const index_t *ST, const_Connector_ptr col_connector, escript::const_Distribution_ptr col_dist)
Definition: AMG.cpp:677
paso::Preconditioner_LocalSmoother::buffer
double * buffer
Definition: Preconditioner.h:63
paso::Preconditioner_Smoother::localSmoother
Preconditioner_LocalSmoother * localSmoother
Definition: Preconditioner.h:69
paso::Preconditioner_AMG::Smoother
Preconditioner_Smoother * Smoother
Definition: Preconditioner.h:126
paso::Preconditioner_AMG::refinements
int refinements
number of refinements in direct solver (typically =0)
Definition: Preconditioner.h:136
paso::Preconditioner_free
void Preconditioner_free(Preconditioner *in)
Definition: Preconditioner.cpp:35
paso::PASO_AMG_IN_F
Definition: Preconditioner.h:111
paso::Preconditioner_AMG_mergeSolve
void Preconditioner_AMG_mergeSolve(Preconditioner_AMG *amg)
paso::Preconditioner_AMG_alloc
Preconditioner_AMG * Preconditioner_AMG_alloc(SystemMatrix_ptr A, int level, Options *options)
Definition: AMG.cpp:116
paso::Preconditioner
Definition: Preconditioner.h:37
paso::Preconditioner_LocalAMG_getMaxLevel
int Preconditioner_LocalAMG_getMaxLevel(const Preconditioner_LocalAMG *in)
Definition: LocalAMG.cpp:55
paso::Preconditioner_AMG::R
SystemMatrix_ptr R
restriction n_C x n
Definition: Preconditioner.h:124
paso::Preconditioner_AMG::pre_sweeps
int pre_sweeps
Definition: Preconditioner.h:128
paso::Solver_solveILU
void Solver_solveILU(SparseMatrix_ptr A, Solver_ILU *ilu, double *x, const double *b)
Definition: ILU.cpp:316
paso::Solver_RILU_free
void Solver_RILU_free(Solver_RILU *in)
Definition: RILU.cpp:35
paso::Preconditioner_AMG_setClassicProlongation
void Preconditioner_AMG_setClassicProlongation(SystemMatrix_ptr P, SystemMatrix_ptr A, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const index_t *counter_C)
Definition: AMG_Prolongation.cpp:664
paso::Preconditioner_AMG_setDirectProlongation_Block
void Preconditioner_AMG_setDirectProlongation_Block(SystemMatrix_ptr P, SystemMatrix_ptr A, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const index_t *counter_C)
Definition: AMG_Prolongation.cpp:469
paso::Preconditioner_LocalAMG::Smoother
Preconditioner_LocalSmoother * Smoother
Definition: Preconditioner.h:226
paso::Solver_RILU
RILU preconditioner.
Definition: Preconditioner.h:305
paso::Solver_RILU::A_FF_pivot
index_t * A_FF_pivot
Definition: Preconditioner.h:312
paso::Preconditioner_Smoother
Definition: Preconditioner.h:67
paso::Preconditioner_AMG::level
int level
Definition: Preconditioner.h:118
escript::const_Distribution_ptr
boost::shared_ptr< const Distribution > const_Distribution_ptr
Definition: Distribution.h:26
paso::Solver_RILU::n
dim_t n
Definition: Preconditioner.h:307
paso::Preconditioner_AMG_setClassicProlongation_Block
void Preconditioner_AMG_setClassicProlongation_Block(SystemMatrix_ptr P, SystemMatrix_ptr A, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const index_t *counter_C)
Definition: AMG_Prolongation.cpp:894
paso::Preconditioner_AMG_getMaxLevel
int Preconditioner_AMG_getMaxLevel(const Preconditioner_AMG *in)
Definition: AMG.cpp:78
paso::Preconditioner_AMG::P
SystemMatrix_ptr P
prolongation n x n_C
Definition: Preconditioner.h:122
paso::MergedSolver
Definition: MergedSolver.h:36
paso::Preconditioner_AMG::reordering
index_t reordering
applied reordering in direct solver
Definition: Preconditioner.h:134
paso::Preconditioner_AMG
Local preconditioner.
Definition: Preconditioner.h:116
paso::Preconditioner_AMG_setStrongConnections
void Preconditioner_AMG_setStrongConnections(SystemMatrix_ptr A, dim_t *degree_S, index_t *offset_S, index_t *S, double theta, double tau)
Definition: AMG.cpp:378
paso::Preconditioner_AMG::verbose
bool verbose
used in direct solver
Definition: Preconditioner.h:132
paso::Preconditioner_AMG::merged_solver
MergedSolver * merged_solver
used on the coarsest level
Definition: Preconditioner.h:144
paso::Solver_RILU::rows_in_F
index_t * rows_in_F
Definition: Preconditioner.h:315
paso::Preconditioner_AMG_Root::sweeps
int sweeps
Definition: Preconditioner.h:288
paso::Preconditioner_LocalAMG_free
void Preconditioner_LocalAMG_free(Preconditioner_LocalAMG *in)
Definition: LocalAMG.cpp:43
paso::Preconditioner_solve
void Preconditioner_solve(Preconditioner *prec, SystemMatrix_ptr A, double *x, double *b)
Definition: Preconditioner.cpp:120
paso::Preconditioner_AMG::b_C
double * b_C
right hand side of coarse level system
Definition: Preconditioner.h:142
paso::Solver_RILU::A_FC
SparseMatrix_ptr A_FC
Definition: Preconditioner.h:313
paso::Preconditioner_AMG_setDirectProlongation
void Preconditioner_AMG_setDirectProlongation(SystemMatrix_ptr P, SystemMatrix_ptr A, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const index_t *counter_C)
Definition: AMG_Prolongation.cpp:332
paso::const_Preconditioner_ptr
boost::shared_ptr< const Preconditioner > const_Preconditioner_ptr
Definition: Preconditioner.h:29
paso::Preconditioner_LocalAMG::A_C
SparseMatrix_ptr A_C
Definition: Preconditioner.h:222
paso::Preconditioner::sweeps
dim_t sweeps
Definition: Preconditioner.h:40
paso::Solver_RILU::b_C
double * b_C
Definition: Preconditioner.h:322
paso::Solver_RILU::x_F
double * x_F
Definition: Preconditioner.h:319
paso::const_Connector_ptr
boost::shared_ptr< const Connector > const_Connector_ptr
Definition: Coupler.h:39
paso::Preconditioner_AMG_getProlongation
SystemMatrix_ptr Preconditioner_AMG_getProlongation(SystemMatrix_ptr A_p, const index_t *offset_S, const dim_t *degree_S, const index_t *S, const dim_t n_C, index_t *counter_C, const index_t interpolation_method)
Definition: AMG_Prolongation.cpp:57
paso::Preconditioner_LocalAMG_setDirectProlongation
void Preconditioner_LocalAMG_setDirectProlongation(SparseMatrix_ptr P_p, const_SparseMatrix_ptr A_p, const index_t *counter_C)
Definition: LocalAMG_Prolongation.cpp:146
paso::Preconditioner_AMG_buildInterpolationOperatorBlock
SystemMatrix_ptr Preconditioner_AMG_buildInterpolationOperatorBlock(SystemMatrix_ptr A, SystemMatrix_ptr P, SystemMatrix_ptr R)
Definition: AMG_Interpolation.cpp:1950
paso::Solver_RILU::n_C
dim_t n_C
Definition: Preconditioner.h:310
paso::Preconditioner_AMG::options_smoother
dim_t options_smoother
used in direct solver
Definition: Preconditioner.h:130
paso::SolverResult
SolverResult
Definition: Paso.h:42
paso::Preconditioner_LocalSmoother
Definition: Preconditioner.h:59
paso::Preconditioner_AMG_buildInterpolationOperator
SystemMatrix_ptr Preconditioner_AMG_buildInterpolationOperator(SystemMatrix_ptr A, SystemMatrix_ptr P, SystemMatrix_ptr R)
Definition: AMG_Interpolation.cpp:556
paso::Preconditioner_AMG_transposeStrongConnections
void Preconditioner_AMG_transposeStrongConnections(dim_t n, const dim_t *degree_S, const index_t *offset_S, const index_t *S, const dim_t nT, dim_t *degree_ST, index_t *offset_ST, index_t *ST)
Definition: AMG.cpp:650
paso::Preconditioner_LocalAMG_getProlongation
SparseMatrix_ptr Preconditioner_LocalAMG_getProlongation(SparseMatrix_ptr A_p, const index_t *offset_S, const dim_t *degree_S, const index_t *S, dim_t n_C, const index_t *counter_C, index_t interpolation_method)
Definition: LocalAMG_Prolongation.cpp:55
S
#define S(_J_, _I_)
Definition: ShapeFunctions.cpp:121
paso::Solver_RILU::mask_C
index_t * mask_C
Definition: Preconditioner.h:318
paso::Solver_RILU::n_F
dim_t n_F
Definition: Preconditioner.h:309
paso::Preconditioner_LocalSmoother::diag
double * diag
Definition: Preconditioner.h:62
escript::DataTypes::dim_t
index_t dim_t
Definition: DataTypes.h:64
paso::Solver_ILU::factors
double * factors
Definition: Preconditioner.h:301
paso::Preconditioner_LocalAMG::r
double * r
Definition: Preconditioner.h:231
paso::Preconditioner_LocalAMG_RungeStuebenSearch
void Preconditioner_LocalAMG_RungeStuebenSearch(dim_t n, const index_t *offset_S, const dim_t *degree_S, const index_t *S, AMGBlockSelect *split_marker, bool usePanel)
Definition: LocalAMG.cpp:489
paso::Preconditioner_AMG_Root::amg
Preconditioner_AMG * amg
Definition: Preconditioner.h:285
paso::Preconditioner_AMG_free
void Preconditioner_AMG_free(Preconditioner_AMG *in)
Definition: AMG.cpp:65
paso::Preconditioner::ilu
Solver_ILU * ilu
ILU preconditioner.
Definition: Preconditioner.h:48
paso::Preconditioner_LocalSmoother::Jacobi
bool Jacobi
Definition: Preconditioner.h:61