ESYS13
Revision_
|
#include "Paso.h"
#include "Preconditioner.h"
#include "Options.h"
#include "PasoUtil.h"
#include "UMFPACK.h"
#include "MKL.h"
#include <stdio.h>
#define MY_DEBUG 0 |
#define MY_DEBUG1 1 |
#define SHOW_TIMING FALSE |
Referenced by Paso_Preconditioner_AMG_alloc(), and Paso_Preconditioner_AMG_solve().
int compareindex | ( | const void * | a, |
const void * | b | ||
) |
Paso_Preconditioner_AMG* Paso_Preconditioner_AMG_alloc | ( | Paso_SystemMatrix * | A_p, |
dim_t | level, | ||
Paso_Options * | options | ||
) |
References Paso_Preconditioner_AMG::A_C, Paso_Preconditioner_AMG::AMG_C, Paso_Preconditioner_AMG::b_C, Paso_Options::coarsening_selection_time, Paso_Options::coarsening_threshold, Paso_SystemMatrix::col_coupleBlock, Paso_SystemMatrix::col_coupler, Paso_SystemMatrix::col_distribution, Esys_MPIInfo::comm, Paso_Coupler::connector, Paso_Options::diagonal_dominance_threshold, Esys_checkPtr(), Esys_noError(), Esys_timer(), FALSE, Paso_Options::interpolation_method, Paso_Pattern::len, Paso_Preconditioner_AMG::level, Paso_Options::level_max, Paso_SystemMatrix::mainBlock, MAX, MEMALLOC, Paso_Preconditioner_AMG::merged_solver, Paso_Options::min_coarse_matrix_size, Paso_Options::min_coarse_sparsity, Paso_SystemMatrix::mpi_info, MPI_INT, Paso_SparseMatrix::numCols, Paso_SparseMatrix::numRows, Paso_Preconditioner_AMG::P, PASO_AMG_IN_F, PASO_JACOBI, Paso_MergedSolver_alloc(), Paso_Preconditioner_AMG_alloc(), Paso_Preconditioner_AMG_buildInterpolationOperator(), Paso_Preconditioner_AMG_CIJPCoarsening(), Paso_Preconditioner_AMG_free(), Paso_Preconditioner_AMG_getProlongation(), Paso_Preconditioner_AMG_getRestriction(), Paso_Preconditioner_AMG_setStrongConnections(), Paso_Preconditioner_AMG_setStrongConnections_Block(), Paso_Preconditioner_AMG_transposeStrongConnections(), Paso_Preconditioner_Smoother_alloc(), Paso_SystemMatrix_copyColCoupleBlock(), Paso_SystemMatrix_copyRemoteCoupleBlock(), Paso_SystemMatrix_getGlobalNumRows(), Paso_SystemMatrix_getSparsity(), Paso_Util_cumsum_maskedFalse(), Paso_Util_cumsum_maskedTrue(), Paso_SparseMatrix::pattern, Paso_Preconditioner_AMG::post_sweeps, Paso_Options::post_sweeps, Paso_Preconditioner_AMG::pre_sweeps, Paso_Options::pre_sweeps, Paso_Preconditioner_AMG::R, Paso_Preconditioner_AMG::r, Paso_SystemMatrix::row_block_size, Paso_SystemMatrix::row_coupleBlock, S, SHOW_TIMING, Esys_MPIInfo::size, Paso_Preconditioner_AMG::Smoother, Paso_Options::smoother, TMPMEMALLOC, TMPMEMFREE, Paso_Options::verbose, and Paso_Preconditioner_AMG::x_C.
Referenced by Paso_Preconditioner_AMG_alloc(), and Paso_Preconditioner_AMG_Root_alloc().
void Paso_Preconditioner_AMG_CIJPCoarsening | ( | const dim_t | n, |
const dim_t | my_n, | ||
index_t * | 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, | ||
Paso_Connector * | col_connector, | ||
Paso_Distribution * | col_dist | ||
) |
References Esys_setError(), FALSE, PASO_AMG_IN_C, PASO_AMG_IN_F, Paso_comparIndex(), Paso_Coupler_alloc(), Paso_Coupler_fillOverlap(), Paso_Coupler_free(), Paso_Distribution_createRandomVector(), Paso_Distribution_numPositives(), SYSTEM_ERROR, TMPMEMALLOC, TMPMEMFREE, and TRUE.
Referenced by Paso_Preconditioner_AMG_alloc().
void Paso_Preconditioner_AMG_free | ( | Paso_Preconditioner_AMG * | in | ) |
References Paso_Preconditioner_AMG::A_C, Paso_Preconditioner_AMG::AMG_C, Paso_Preconditioner_AMG::b_C, MEMFREE, Paso_Preconditioner_AMG::merged_solver, Paso_Preconditioner_AMG::P, Paso_MergedSolver_free(), Paso_Preconditioner_AMG_free(), Paso_Preconditioner_Smoother_free(), Paso_SystemMatrix_free(), Paso_Preconditioner_AMG::R, Paso_Preconditioner_AMG::r, Paso_Preconditioner_AMG::Smoother, and Paso_Preconditioner_AMG::x_C.
Referenced by Paso_Preconditioner_AMG_alloc(), Paso_Preconditioner_AMG_free(), and Paso_Preconditioner_AMG_Root_free().
double Paso_Preconditioner_AMG_getCoarseLevelSparsity | ( | const Paso_Preconditioner_AMG * | in | ) |
void Paso_Preconditioner_AMG_setStrongConnections | ( | Paso_SystemMatrix * | A, |
dim_t * | degree_S, | ||
index_t * | offset_S, | ||
index_t * | S, | ||
const double | theta, | ||
const double | tau | ||
) |
References ABS, Paso_SystemMatrix::col_coupleBlock, Paso_Coupler::connector, Paso_Pattern::index, Paso_SystemMatrix::mainBlock, MAX, Paso_SystemMatrix::mpi_info, Paso_SparseMatrix::numRows, Paso_Coupler_alloc(), Paso_Coupler_finishCollect(), Paso_Coupler_free(), Paso_Coupler_startCollect(), Paso_SparseMatrix::pattern, Paso_Pattern::ptr, Paso_Coupler::recv_buffer, Paso_SystemMatrix::remote_coupleBlock, Paso_SystemMatrix::row_coupleBlock, Paso_SystemMatrix::row_coupler, Esys_MPIInfo::size, TMPMEMALLOC, TMPMEMFREE, and Paso_SparseMatrix::val.
Referenced by Paso_Preconditioner_AMG_alloc().
void Paso_Preconditioner_AMG_setStrongConnections_Block | ( | Paso_SystemMatrix * | A, |
dim_t * | degree_S, | ||
index_t * | offset_S, | ||
index_t * | S, | ||
const double | theta, | ||
const double | tau | ||
) |
References Paso_SystemMatrix::block_size, Paso_SystemMatrix::col_coupleBlock, Paso_Coupler::connector, Paso_Pattern::index, Paso_SystemMatrix::mainBlock, MAX, Paso_SystemMatrix::mpi_info, Paso_SparseMatrix::numRows, Paso_Coupler_alloc(), Paso_Coupler_finishCollect(), Paso_Coupler_free(), Paso_Coupler_startCollect(), Paso_SparseMatrix::pattern, Paso_Pattern::ptr, Paso_Coupler::recv_buffer, Paso_SystemMatrix::remote_coupleBlock, Paso_SystemMatrix::row_coupleBlock, Paso_SystemMatrix::row_coupler, Esys_MPIInfo::size, TMPMEMALLOC, TMPMEMFREE, and Paso_SparseMatrix::val.
Referenced by Paso_Preconditioner_AMG_alloc().
void Paso_Preconditioner_AMG_solve | ( | Paso_SystemMatrix * | A, |
Paso_Preconditioner_AMG * | amg, | ||
double * | x, | ||
double * | b | ||
) |
References Paso_Preconditioner_AMG::A_C, Paso_Preconditioner_AMG::AMG_C, Paso_Preconditioner_AMG::b_C, Esys_timer(), FALSE, Paso_Preconditioner_AMG::level, Paso_SystemMatrix::mainBlock, Paso_Preconditioner_AMG::merged_solver, Paso_SparseMatrix::numRows, Paso_Preconditioner_AMG::P, Paso_Copy(), Paso_MergedSolver_solve(), Paso_Preconditioner_AMG_solve(), Paso_Preconditioner_Smoother_solve(), Paso_SystemMatrix_MatrixVector_CSR_OFFSET0(), Paso_Preconditioner_AMG::post_sweeps, Paso_Preconditioner_AMG::pre_sweeps, Paso_Preconditioner_AMG::R, Paso_Preconditioner_AMG::r, Paso_SparseMatrix::row_block_size, SHOW_TIMING, Paso_Preconditioner_AMG::Smoother, TRUE, and Paso_Preconditioner_AMG::x_C.
Referenced by Paso_Preconditioner_AMG_Root_solve(), and Paso_Preconditioner_AMG_solve().
void Paso_Preconditioner_AMG_transposeStrongConnections | ( | const 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 | ||
) |
Referenced by Paso_Preconditioner_AMG_alloc().