Liebe Gitlab-Nutzer, lieber Gitlab-Nutzer, es ist nun möglich sich mittels des ZIH-Logins/LDAP an unserem Dienst anzumelden. Ein Anmelden über dieses erzeugt ein neues Konto. Das alte Konto ist über den Reiter "Standard" erreichbar. Die Administratoren

Dear Gitlab user, it is now possible to log in to our service using the ZIH login/LDAP. Logging in via this will create a new account. The old account can be accessed via the "Standard" tab. The administrators

Commit 2eeb5654 authored by Thomas Witkowski's avatar Thomas Witkowski
Browse files

Work on FETI-DP method.

parent 3509ab94
......@@ -89,7 +89,6 @@ namespace AMDiS {
petscSolver->fillPetscRhs(rhs);
#if 0
processMemUsage(vm, rss);
MSG("STAGE 2\n");
......
This diff is collapsed.
......@@ -33,6 +33,8 @@ namespace AMDiS {
#ifdef HAVE_PETSC_DEV
class PetscSolverFeti;
/** \brief
* This structure is used when defining the MatShell operation for solving
* primal schur complement. \ref petscMultMatSchurPrimal
......@@ -50,8 +52,7 @@ namespace AMDiS {
/// Temporal vecor in the primal variables.
Vec tmp_vec_primal;
/// Pointer to the solver for \ref PetscSolverFeti::mat_bb.
KSP *ksp_b;
PetscSolverFeti *fetiSolver;
};
......@@ -76,8 +77,7 @@ namespace AMDiS {
/// Temporal vector on the primal variables.
Vec tmp_vec_primal;
/// Pointer to the solver for \ref PetscSolverFeti::mat_bb.
KSP *ksp_b;
PetscSolverFeti *fetiSolver;
/// Pointer to the solver of the schur complement on the primal variables.
KSP *ksp_schur_primal;
......@@ -125,6 +125,34 @@ namespace AMDiS {
} FetiPreconditioner;
struct FetiStatisticsData
{
/// Number of application of the FETI-DP operator.
int nFetiApply;
/// Time for solving the reduced FETI system.
double timeFetiApply;
/// Number of application of the Schur primal operator.
int nSchurPrimalApply;
/// Time for appling the Schur primal operator.
double timeSchurPrimalApply;
/// Number of solution of the Schur primal system.
int nSchurPrimalSolve;
/// Time for solving the Schur primal system.
double timeSchurPrimalSolve;
/// Number of solution of the local subdomain problems.
int nLocalSolve;
/// Time for solving the local subdomain problems.
double timeLocalSolve;
};
/** \brief
* FETI-DP implementation based on PETSc.
*/
......@@ -156,6 +184,8 @@ namespace AMDiS {
MeshDistributor::BOUNDARY_FILL_INFO_RECV_DOFS;
}
void solveLocalProblem(Vec &rhs, Vec &sol);
protected:
/// After mesh changes, or if the solver is called the first time, this
/// function creates all matrix and vector objects with the approriated
......@@ -212,15 +242,6 @@ namespace AMDiS {
Vec &vec_sol_primal,
SystemVector &vec);
/** \brief
* Solves the FETI-DP system globally, thus without reducing it to the
* Lagrange multipliers. This should be used for debugging only to test
* if the FETI-DP system is setup correctly.
*
* \param[out] vec Solution DOF vectors.
*/
void solveFetiMatrix(SystemVector &vec);
/** \brief
* Solves the FETI-DP system with reducing it first to the Lagrange
* multipliers. This is what one expects when using the FETI-DP methid :)
......@@ -229,6 +250,10 @@ namespace AMDiS {
*/
void solveReducedFetiMatrix(SystemVector &vec);
void resetStatistics();
void printStatistics();
protected:
/// Number of components in the PDE to be solved.
int nComponents;
......@@ -262,7 +287,7 @@ namespace AMDiS {
/// Index for each non primal variables to the global index of
/// B variables.
DofMapping globalIndexB;
DofMapping globalIndexB, localIndexB;
/// Number of non primal, thus B, variables on rank and globally.
int nRankB, nOverallB, rStartB;
......@@ -287,6 +312,11 @@ namespace AMDiS {
/// variables, \ref mat_b_b
KSP ksp_b;
/// 0: Solve the Schur complement on primal variables with iterative solver.
/// 1: Create the Schur complement matrix explicitly and solve it with a
/// direct solver.
int schurPrimalSolver;
/// PETSc solver object to solve the Schur complement on the
/// primal variables.
KSP ksp_schur_primal;
......@@ -329,6 +359,9 @@ namespace AMDiS {
// Number of local nodes that are duals.
int nLocalDuals;
public:
static FetiStatisticsData fetiStatistics;
};
#endif
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment