Changes
Page history
added reference to full source code
authored
Aug 11, 2019
by
Praetorius, Simon
Show whitespace changes
Inline
Side-by-side
examples/navier-stokes.md
View page @
8c3f6a5c
...
...
@@ -168,9 +168,9 @@ double vel = 1.0;
Parameters
::
get
(
"stokes->boundary velocity"
,
vel
);
// define boundary values
auto
g
=
[
vel
](
Fie
ldVector
<
double
,
2
>
const
&
x
)
auto
g
=
[
vel
](
Wor
ldVector
const
&
x
)
{
return
Fie
ldVector
<
double
,
2
>
{
0.0
,
vel
*
x
[
1
]
*
(
1.0
-
x
[
1
])
*
(
1.0
-
x
[
0
])};
return
Wor
ldVector
{
0.0
,
vel
*
x
[
1
]
*
(
1.0
-
x
[
1
])
*
(
1.0
-
x
[
0
])};
};
// set boundary conditions for velocity
...
...
@@ -190,3 +190,8 @@ AdaptInfo adaptInfo("adapt");
AdaptInstationary
adapt
(
"adapt"
,
prob
,
adaptInfo
,
probInstat
,
adaptInfo
);
adapt
.
adapt
();
```
Complete Example
----------------
The full source code of the Navier-Stokes example can be found in the repository
at
[
src/navier-stokes.cpp
](
https://gitlab.mn.tu-dresden.de/amdis/amdis-examples/blob/master/src/navier-stokes.cpp
)
.
\ No newline at end of file