-
-
Notifications
You must be signed in to change notification settings - Fork 105
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Channel transport with OpenFOAM (#315)
- Loading branch information
1 parent
bddfd5e
commit 1a1f2d5
Showing
15 changed files
with
497 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
FoamFile | ||
{ | ||
version 2.0; | ||
format ascii; | ||
class volVectorField; | ||
object U; | ||
} | ||
|
||
dimensions [0 1 -1 0 0 0 0]; | ||
internalField uniform (10 0 0); | ||
|
||
boundaryField | ||
{ | ||
inlet | ||
{ | ||
type fixedValue; | ||
value $internalField; | ||
} | ||
outlet | ||
{ | ||
type zeroGradient; | ||
} | ||
obstacle | ||
{ | ||
type noSlip; | ||
} | ||
upperWall | ||
{ | ||
type noSlip; | ||
} | ||
lowerWall | ||
{ | ||
type noSlip; | ||
} | ||
frontAndBack | ||
{ | ||
type empty; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
FoamFile | ||
{ | ||
version 2.0; | ||
format ascii; | ||
class volScalarField; | ||
object p; | ||
} | ||
|
||
dimensions [0 2 -2 0 0 0 0]; | ||
|
||
internalField uniform 0; | ||
|
||
boundaryField | ||
{ | ||
inlet | ||
{ | ||
type zeroGradient; | ||
} | ||
|
||
outlet | ||
{ | ||
type fixedValue; | ||
value uniform 0; | ||
} | ||
|
||
obstacle | ||
{ | ||
type zeroGradient; | ||
} | ||
|
||
upperWall | ||
{ | ||
type zeroGradient; | ||
} | ||
|
||
lowerWall | ||
{ | ||
type zeroGradient; | ||
} | ||
|
||
frontAndBack | ||
{ | ||
type empty; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/bin/sh | ||
set -e -u | ||
|
||
. ../../tools/cleaning-tools.sh | ||
|
||
clean_openfoam . |
11 changes: 11 additions & 0 deletions
11
channel-transport/fluid-openfoam/constant/transportProperties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
FoamFile | ||
{ | ||
version 2.0; | ||
format ascii; | ||
class dictionary; | ||
object transportProperties; | ||
} | ||
|
||
transportModel Newtonian; | ||
|
||
nu nu [ 0 2 -1 0 0 0 0 ] 1; |
9 changes: 9 additions & 0 deletions
9
channel-transport/fluid-openfoam/constant/turbulenceProperties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
FoamFile | ||
{ | ||
version 2.0; | ||
format ascii; | ||
class dictionary; | ||
object turbulenceProperties; | ||
} | ||
|
||
simulationType laminar; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#!/bin/sh | ||
set -e -u | ||
|
||
blockMesh | ||
touch fluid-openfoam.foam | ||
|
||
../../tools/run-openfoam.sh "$@" | ||
. ../../tools/openfoam-remove-empty-dirs.sh && openfoam_remove_empty_dirs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,146 @@ | ||
FoamFile | ||
{ | ||
version 2.0; | ||
format ascii; | ||
class dictionary; | ||
object blockMeshDict; | ||
} | ||
|
||
x0 0.; | ||
x1 2.; | ||
x2 3.; | ||
x3 6.; | ||
|
||
y0 0.; | ||
y1 1.; | ||
y2 2.; | ||
|
||
z0 0; | ||
z1 1; | ||
|
||
vertices | ||
( | ||
($x0 $y0 $z0 ) // 0 | ||
($x1 $y0 $z0 ) // 1 | ||
($x2 $y0 $z0 ) // 2 | ||
($x3 $y0 $z0 ) // 3 | ||
($x0 $y1 $z0 ) // 4 | ||
($x1 $y1 $z0 ) // 5 | ||
($x2 $y1 $z0 ) // 6 | ||
($x3 $y1 $z0 ) // 7 | ||
($x0 $y2 $z0 ) // 8 | ||
($x1 $y2 $z0 ) // 9 | ||
($x2 $y2 $z0 ) // 10 | ||
($x3 $y2 $z0 ) // 11 | ||
|
||
($x0 $y0 $z1 ) // 12 | ||
($x1 $y0 $z1 ) // 13 | ||
($x2 $y0 $z1 ) // 14 | ||
($x3 $y0 $z1 ) // 15 | ||
($x0 $y1 $z1 ) // 16 | ||
($x1 $y1 $z1 ) // 17 | ||
($x2 $y1 $z1 ) // 18 | ||
($x3 $y1 $z1 ) // 19 | ||
($x0 $y2 $z1 ) // 20 | ||
($x1 $y2 $z1 ) // 21 | ||
($x2 $y2 $z1 ) // 22 | ||
($x3 $y2 $z1 ) // 23 | ||
); | ||
|
||
|
||
// Grading | ||
h1 16; | ||
h2 8; | ||
h3 24; | ||
v1 8; | ||
|
||
blocks | ||
( | ||
hex ( 0 1 5 4 12 13 17 16 ) | ||
($h1 $v1 1 ) | ||
simpleGrading (1 1 1) | ||
|
||
hex ( 2 3 7 6 14 15 19 18 ) | ||
($h3 $v1 1) | ||
simpleGrading (1 1 1) | ||
|
||
hex ( 4 5 9 8 16 17 21 20 ) | ||
($h1 $v1 1) | ||
simpleGrading (1 1 1) | ||
|
||
hex ( 5 6 10 9 17 18 22 21 ) | ||
($h2 $v1 1) | ||
simpleGrading (1 1 1) | ||
|
||
hex ( 6 7 11 10 18 19 23 22 ) | ||
($h3 $v1 1 ) | ||
simpleGrading (1 1 1) | ||
); | ||
|
||
boundary | ||
( | ||
inlet | ||
{ | ||
type patch; | ||
faces | ||
( | ||
( 0 4 16 12 ) | ||
( 4 8 20 16 ) | ||
); | ||
} | ||
outlet | ||
{ | ||
type patch; | ||
faces | ||
( | ||
( 3 7 19 15 ) | ||
( 7 11 23 19 ) | ||
); | ||
} | ||
obstacle | ||
{ | ||
type wall; | ||
faces | ||
( | ||
( 1 5 17 13 ) | ||
( 5 6 18 17 ) | ||
( 6 2 14 18 ) | ||
); | ||
} | ||
upperWall | ||
{ | ||
type wall; | ||
faces | ||
( | ||
( 8 9 21 20 ) | ||
( 9 10 22 21 ) | ||
( 10 11 23 22 ) | ||
); | ||
} | ||
lowerWall | ||
{ | ||
type wall; | ||
faces | ||
( | ||
( 0 1 13 12 ) | ||
( 2 3 15 14 ) | ||
); | ||
} | ||
frontAndBack | ||
{ | ||
type empty; | ||
faces | ||
( | ||
( 0 1 5 4 ) | ||
( 2 3 7 6 ) | ||
( 4 5 9 8 ) | ||
( 5 6 10 9 ) | ||
( 6 7 11 10 ) | ||
( 12 13 17 16 ) | ||
( 14 15 19 18 ) | ||
( 16 17 21 20 ) | ||
( 17 18 22 21 ) | ||
( 18 19 23 22 ) | ||
); | ||
} | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
FoamFile | ||
{ | ||
version 2.0; | ||
format ascii; | ||
class dictionary; | ||
object controlDict; | ||
} | ||
|
||
application pimpleFoam; | ||
|
||
startFrom startTime; | ||
|
||
startTime 0; | ||
|
||
stopAt endTime; | ||
|
||
endTime 1.0; | ||
|
||
deltaT 0.005; | ||
|
||
writeControl adjustableRunTime; | ||
|
||
writeInterval 0.005; | ||
|
||
purgeWrite 0; | ||
|
||
writeFormat ascii; | ||
|
||
writePrecision 6; | ||
|
||
writeCompression off; | ||
|
||
timeFormat general; | ||
|
||
timePrecision 6; | ||
|
||
functions | ||
{ | ||
preCICE_Adapter | ||
{ | ||
type preciceAdapterFunctionObject; | ||
libs ("libpreciceAdapterFunctionObject.so"); | ||
} | ||
} |
Oops, something went wrong.