Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Backofen, Rainer
amdis
Commits
0287917c
Commit
0287917c
authored
May 11, 2012
by
Thomas Witkowski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Blub, here and now.
parent
5fba743d
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
11 deletions
+31
-11
AMDiS/src/parallel/MeshDistributor.cc
AMDiS/src/parallel/MeshDistributor.cc
+1
-1
AMDiS/src/parallel/PetscSolverFeti.cc
AMDiS/src/parallel/PetscSolverFeti.cc
+2
-7
AMDiS/src/parallel/SubDomainSolver.cc
AMDiS/src/parallel/SubDomainSolver.cc
+28
-3
No files found.
AMDiS/src/parallel/MeshDistributor.cc
View file @
0287917c
...
...
@@ -550,7 +550,7 @@ namespace AMDiS {
DOFVector
<
double
>
&
dofVec
=
*
(
vec
.
getDOFVector
(
i
));
for
(
it
.
beginDofIter
(
vec
.
getFeSpace
(
i
));
!
it
.
endDofIter
();
it
.
nextDof
())
dofVec
[
it
.
getDofIndex
()]
=
0.0
;
//
stdMpi.getRecvData(rank)[counter++];
dofVec
[
it
.
getDofIndex
()]
=
stdMpi
.
getRecvData
(
rank
)[
counter
++
];
}
}
}
...
...
AMDiS/src/parallel/PetscSolverFeti.cc
View file @
0287917c
...
...
@@ -1413,19 +1413,14 @@ namespace AMDiS {
int
a
=
0
;
levelData
.
getMpiComm
(
meshLevel
).
Allreduce
(
&
tmp
,
&
a
,
1
,
MPI_INT
,
MPI_SUM
);
MSG
(
"RSTART %d
\n
"
,
a
);
for
(
DofMap
::
iterator
it
=
m
.
begin
();
it
!=
m
.
end
();
it
++
)
it
->
second
.
global
+=
a
;
}
else
{
int
groupRowsInterior
=
localDofMap
[
vec
.
getDOFVector
(
0
)
->
getFeSpace
()].
nRankDofs
;
MSG
(
"DA TEST: %d
\n
"
,
groupRowsInterior
);
int
rStart
,
nGlobal
;
mpi
::
getDofNumbering
(
mpiComm
,
groupRowsInterior
,
rStart
,
nGlobal
);
DofMap
&
m
=
localDofMap
[
vec
.
getDOFVector
(
0
)
->
getFeSpace
()].
getMap
();
MSG
(
"RSTART %d
\n
"
,
rStart
);
for
(
DofMap
::
iterator
it
=
m
.
begin
();
it
!=
m
.
end
();
it
++
)
it
->
second
.
global
=
it
->
second
.
local
+
rStart
;
}
...
...
@@ -1434,8 +1429,8 @@ namespace AMDiS {
localDofMap
,
"interior"
,
"dat"
);
MPI
::
Finalize
();
exit
(
0
);
//
MPI::Finalize();
//
exit(0);
#endif
// tmp_primal0 = M_PiB * inv(K_BB) * f_B
...
...
AMDiS/src/parallel/SubDomainSolver.cc
View file @
0287917c
...
...
@@ -200,7 +200,7 @@ namespace AMDiS {
if
(
colsOther
.
size
())
{
int
globalRowIndex
=
interiorMap
->
getMatIndex
(
i
,
*
cursor
);
if
(
multilevel
==
false
)
if
(
multilevel
)
globalRowIndex
+=
rStartInterior
;
for
(
unsigned
int
k
=
0
;
k
<
colsOther
.
size
();
k
++
)
...
...
@@ -245,6 +245,33 @@ namespace AMDiS {
KSPSetFromOptions
(
kspInterior
);
if
(
multilevel
==
false
)
{
PetscViewer
matview
;
PetscViewerBinaryOpen
(
mpiCommCoarseSpace
,
"mat_coarse_int.dat"
,
FILE_MODE_WRITE
,
&
matview
);
MatView
(
matCoarseInt
,
matview
);
PetscViewerDestroy
(
&
matview
);
PetscViewerBinaryOpen
(
mpiCommCoarseSpace
,
"mat_int_coarse.dat"
,
FILE_MODE_WRITE
,
&
matview
);
MatView
(
matIntCoarse
,
matview
);
PetscViewerDestroy
(
&
matview
);
}
else
{
PetscViewer
matview
;
PetscViewerBinaryOpen
(
mpiCommCoarseSpace
,
"mat_coarse_int.dat"
,
FILE_MODE_WRITE
,
&
matview
);
MatView
(
matCoarseInt
,
matview
);
PetscViewerDestroy
(
&
matview
);
PetscViewerBinaryOpen
(
mpiCommCoarseSpace
,
"mat_int_coarse.dat"
,
FILE_MODE_WRITE
,
&
matview
);
MatView
(
matIntCoarse
,
matview
);
PetscViewerDestroy
(
&
matview
);
}
// MPI::Finalize();
// exit(0);
#if 0
PetscViewer matview;
PetscViewerBinaryOpen(mpiCommCoarseSpace, "mat_primal.dat",
...
...
@@ -316,9 +343,7 @@ namespace AMDiS {
}
}
else
{
if
((
*
interiorMap
)[
feSpace
].
isRankDof
(
index
))
{
int
d
=
index
;
index
=
interiorMap
->
getMatIndex
(
i
,
index
)
+
rStartInterior
;
int
t
=
interiorMap
->
getLocalMatIndex
(
i
,
d
);
VecSetValue
(
rhsInterior
,
index
,
*
dofIt
,
INSERT_VALUES
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment