Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
amdis
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
iwr
amdis
Commits
5161a040
Commit
5161a040
authored
13 years ago
by
Thomas Witkowski
Browse files
Options
Downloads
Patches
Plain Diff
First try to generalize the FETI-DP solver to a multilevel method.
parent
4c8ae77a
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
AMDiS/src/parallel/PetscSolverFeti.cc
+15
-1
15 additions, 1 deletion
AMDiS/src/parallel/PetscSolverFeti.cc
AMDiS/src/parallel/PetscSolverFeti.h
+5
-0
5 additions, 0 deletions
AMDiS/src/parallel/PetscSolverFeti.h
AMDiS/src/parallel/SubDomainSolver.h
+67
-0
67 additions, 0 deletions
AMDiS/src/parallel/SubDomainSolver.h
with
87 additions
and
1 deletion
AMDiS/src/parallel/PetscSolverFeti.cc
+
15
−
1
View file @
5161a040
...
...
@@ -14,6 +14,7 @@
#include
"parallel/PetscSolverFetiStructs.h"
#include
"parallel/StdMpi.h"
#include
"parallel/MpiHelper.h"
#include
"parallel/SubDomainSolver.h"
#include
"io/VtkWriter.h"
namespace
AMDiS
{
...
...
@@ -185,7 +186,8 @@ namespace AMDiS {
PetscSolverFeti
::
PetscSolverFeti
()
:
PetscSolver
(),
schurPrimalSolver
(
0
)
schurPrimalSolver
(
0
),
multiLevelTest
(
false
)
{
FUNCNAME
(
"PetscSolverFeti::PetscSolverFeti()"
);
...
...
@@ -209,6 +211,12 @@ namespace AMDiS {
TEST_EXIT
(
schurPrimalSolver
==
0
||
schurPrimalSolver
==
1
)
(
"Wrong solver
\"
%d
\"
for the Schur primal complement!
\n
"
,
schurPrimalSolver
);
Parameters
::
get
(
"parallel->multi level test"
,
multiLevelTest
);
if
(
multiLevelTest
)
{
// subDomainSolver = new SubDomainSolver(meshDistributor, mpiComm, &PETSC_COMM_SELF);
}
}
...
...
@@ -260,6 +268,12 @@ namespace AMDiS {
static_cast
<
unsigned
int
>
(
feSpace
->
getAdmin
()
->
getUsedDofs
()))
(
"Should not happen!
\n
"
);
}
// If multi level test, inform sub domain solver about coarse space.
if
(
multiLevelTest
)
{
subDomainSolver
->
setCoarseSpace
(
&
primalDofMap
);
}
}
...
...
This diff is collapsed.
Click to expand it.
AMDiS/src/parallel/PetscSolverFeti.h
+
5
−
0
View file @
5161a040
...
...
@@ -26,6 +26,7 @@
#include
"parallel/PetscSolverFetiStructs.h"
#include
"parallel/ParallelDofMapping.h"
#include
"parallel/ParallelTypes.h"
#include
"parallel/SubDomainSolver.h"
#ifndef AMDIS_PETSC_SOLVER_FETI_H
#define AMDIS_PETSC_SOLVER_FETI_H
...
...
@@ -240,6 +241,10 @@ namespace AMDiS {
Mat
mat_interior_interior
,
mat_duals_duals
,
mat_interior_duals
,
mat_duals_interior
;
KSP
ksp_interior
;
bool
multiLevelTest
;
SubDomainSolver
*
subDomainSolver
;
};
}
...
...
This diff is collapsed.
Click to expand it.
AMDiS/src/parallel/SubDomainSolver.h
0 → 100644
+
67
−
0
View file @
5161a040
// ============================================================================
// == ==
// == AMDiS - Adaptive multidimensional simulations ==
// == ==
// == http://www.amdis-fem.org ==
// == ==
// ============================================================================
//
// Software License for AMDiS
//
// Copyright (c) 2010 Dresden University of Technology
// All rights reserved.
// Authors: Simon Vey, Thomas Witkowski et al.
//
// This file is part of AMDiS
//
// See also license.opensource.txt in the distribution.
/** \file SubDomainSolver.h */
#ifndef AMDIS_SUBDOMAIN_SOLVER_H
#define AMDIS_SUBDOMAIN_SOLVER_H
#include
<map>
#include
<set>
#include
<mpi.h>
#include
<petsc.h>
#include
"parallel/MeshDistributor.h"
#include
"parallel/ParallelDofMapping.h"
namespace
AMDiS
{
using
namespace
std
;
class
SubDomainSolver
{
public:
SubDomainSolver
(
MeshDistributor
*
md
,
MPI
::
Intracomm
*
mpiComm0
,
MPI
::
Intracomm
*
mpiComm1
)
:
meshDistributor
(
md
),
coarseSpaceMpiComm
(
mpiComm0
),
subDomainMpiComm
(
mpiComm1
),
coarseSpace
(
NULL
)
{}
void
setCoarseSpace
(
ParallelDofMapping
*
coarseDofs
)
{
coarseSpace
=
coarseDofs
;
}
void
solve
(
Vec
&
rhs
,
Vec
&
sol
)
{}
protected
:
MeshDistributor
*
meshDistributor
;
MPI
::
Intracomm
*
coarseSpaceMpiComm
;
MPI
::
Intracomm
*
subDomainMpiComm
;
ParallelDofMapping
*
coarseSpace
;
};
}
#endif
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment