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
Aland, Sebastian
amdis
Commits
ac632050
Commit
ac632050
authored
Feb 17, 2013
by
Praetorius, Simon
Browse files
AMDiS now compiles with -pedantic
parent
3102cc9b
Changes
1
Hide whitespace changes
Inline
Side-by-side
extensions/base_problems/CahnHilliardNavierStokes.cc
View file @
ac632050
...
...
@@ -8,9 +8,17 @@ using namespace AMDiS;
CahnHilliardNavierStokes
::
CahnHilliardNavierStokes
(
const
std
::
string
&
name_
)
:
super
(
name_
),
reinit
(
NULL
),
velocity
(
NULL
),
useMobility
(
false
),
useConservationForm
(
false
),
laplaceType
(
0
),
nonLinTerm
(
3
),
doubleWell
(
1
),
oldTimestep
(
0.0
),
viscosity
(
1.0
),
density
(
1.0
),
c
(
0.0
),
gamma
(
1.0
),
eps
(
0.1
),
minusEps
(
-
0.1
),
...
...
@@ -18,16 +26,8 @@ CahnHilliardNavierStokes::CahnHilliardNavierStokes(const std::string &name_) :
minusEpsInv
(
-
10.0
),
epsSqr
(
0.01
),
minusEpsSqr
(
-
0.01
),
laplaceType
(
0
),
nonLinTerm
(
3
),
oldTimestep
(
0.0
),
viscosity
(
1.0
),
density
(
1.0
),
c
(
0.0
),
sigma
(
1.0
),
surfaceTension
(
1.0
),
reinit
(
NULL
),
velocity
(
NULL
),
fileWriter
(
NULL
)
{
// parameters for CH
...
...
@@ -75,8 +75,7 @@ CahnHilliardNavierStokes::CahnHilliardNavierStokes(const std::string &name_) :
CahnHilliardNavierStokes
::~
CahnHilliardNavierStokes
()
{
FUNCNAME
(
"CahnHilliardNavierStokes::~CahnHilliardNavierStokes()"
);
{
if
(
reinit
!=
NULL
)
{
delete
reinit
;
reinit
=
NULL
;
...
...
@@ -91,8 +90,7 @@ CahnHilliardNavierStokes::~CahnHilliardNavierStokes()
void
CahnHilliardNavierStokes
::
initData
()
{
FUNCNAME
(
"CahnHilliardNavierStokes::initData()"
);
{
dim
=
getMesh
()
->
getDim
();
// create instance redistancing class
reinit
=
new
HL_SignedDistTraverse
(
"reinit"
,
dim
);
...
...
@@ -106,8 +104,7 @@ void CahnHilliardNavierStokes::initData()
void
CahnHilliardNavierStokes
::
transferInitialSolution
(
AdaptInfo
*
adaptInfo
)
{
FUNCNAME
(
"CahnHilliardNavierStokes::transferInitialSolution()"
);
{
calcVelocity
();
for
(
int
i
=
0
;
i
<
2
+
dow
;
i
++
)
...
...
@@ -314,8 +311,7 @@ void CahnHilliardNavierStokes::fillOperators()
void
CahnHilliardNavierStokes
::
addLaplaceTerm
(
int
i
)
{
FUNCNAME
(
"CahnHilliardNavierStokes::addLaplaceTerm()"
);
{
/// < alpha*[grad(u)+grad(u)^t] , grad(psi) >
if
(
laplaceType
==
1
)
{
for
(
size_t
j
=
0
;
j
<
dow
;
++
j
)
{
...
...
@@ -332,8 +328,7 @@ void CahnHilliardNavierStokes::addLaplaceTerm(int i)
}
void
CahnHilliardNavierStokes
::
closeTimestep
(
AdaptInfo
*
adaptInfo
)
{
FUNCNAME
(
"CahnHilliardNavierStokes::closeTimestep()"
);
{
calcVelocity
();
fileWriter
->
writeFiles
(
adaptInfo
,
false
);
writeFiles
(
adaptInfo
,
false
);
...
...
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