Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Backofen, Rainer
amdis
Commits
2e2d7450
Commit
2e2d7450
authored
Jan 03, 2013
by
Praetorius, Simon
Browse files
little changes on extensions/demo/NavierStokesCahnHilliard
parent
ff936634
Changes
3
Hide whitespace changes
Inline
Side-by-side
AMDiS/src/parallel/PetscSolverNavierStokes.h
View file @
2e2d7450
...
...
@@ -164,6 +164,7 @@ namespace AMDiS {
void
setStokesData
(
double
*
invTauPtr
,
SystemVector
*
vec
,
double
*
nu1_
=
NULL
,
double
*
nu2_
=
NULL
,
double
*
rho1_
=
NULL
,
double
*
rho2_
=
NULL
)
{
nu
=
new
double
;
(
*
nu
)
=
0.0
;
invTau
=
invTauPtr
;
solution
=
vec
;
...
...
extensions/demo/NavierStokesCahnHilliard_PC/run
View file @
2e2d7450
# This demo implements the Navier-Stokes-Cahn-Hilliard Benchmark from
# S. Aland, A. Voigt. Benchmark computations of diffuse-interface models for two-dimensional bubble dynamics. Int. J. Num. Meth. Fluids (2012)
output="output2_sequentiell"
initfile="init/nsch.dat.2d"
mkdir $output
...
...
@@ -6,7 +9,7 @@ mkdir serials
cp -r ../src .
cp ../$initfile .
mpiexec -n 2 ../
drivenCavity
../$initfile -ns_ksp_atol 1e-9 -ns_ksp_rtol 0 -ch_ksp_atol 1e-9 -ch_ksp_rtol 0 -laplace_pc_type hypre -laplace_pc_hypre_boomeramg_relax_type_coarse symmetric-SOR/Jacobi
mpiexec -n 2 ../
nsch
../$initfile -ns_ksp_atol 1e-9 -ns_ksp_rtol 0 -ch_ksp_atol 1e-9 -ch_ksp_rtol 0 -laplace_pc_type hypre -laplace_pc_hypre_boomeramg_relax_type_coarse symmetric-SOR/Jacobi
# sequentiell (solver noch auf umfpack stellen) -> #../drivenCavity ../$initfile
###### mpiexec -n 2 valgrind --tool=memcheck -q --num-callers=20 --log-file=valgrind.log.%p ../drivenCavity ../$initfile -malloc off -start_in_debugger
...
...
extensions/demo/NavierStokesCahnHilliard_PC/src/CahnHilliardNavierStokes_.h
View file @
2e2d7450
...
...
@@ -150,10 +150,12 @@ public:
nsProb
->
getProblem
(
0
)
->
addVectorOperator
(
opNuGradC
,
i
,
&
surfaceTension
,
&
surfaceTension
);
}
// < v * grad(c) , theta >
Operator
*
opVGradC
=
new
Operator
(
chProb
->
getFeSpace
(
0
),
chProb
->
getFeSpace
(
1
));
opVGradC
->
addTerm
(
new
WorldVector_FOT
(
nsProb
->
getVelocity
(),
1.0
),
GRD_PHI
);
chProb
->
getProblem
()
->
addMatrixOperator
(
opVGradC
,
1
,
1
,
chProb
->
getTau
());
for
(
size_t
i
=
0
;
i
<
dow
;
i
++
)
{
// < v * grad(c) , theta >
Operator
*
opVGradC
=
new
Operator
(
chProb
->
getFeSpace
(
0
),
chProb
->
getFeSpace
(
1
));
opVGradC
->
addTerm
(
new
VecAtQP_FOT
(
nsProb
->
getSolution
()
->
getDOFVector
(
i
),
new
ID
(),
i
),
GRD_PHI
);
chProb
->
getProblem
()
->
addMatrixOperator
(
opVGradC
,
1
,
1
,
chProb
->
getTau
());
}
/**/
}
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment