先程のentryの続きとして いきなりOprnFOAM (2) | 株式会社ソフトフローを参考に OpenFOAM tutorials にある incompressible/simpleFoam/pitzDaily を実行
config by bashrc
$ source /usr/lib/openfoam/openfoam2312/etc/bashrc $ which blockMesh /usr/lib/openfoam/openfoam2312/platforms/linux64GccDPInt32Opt/bin/blockMesh $ which simpleFoam /usr/lib/openfoam/openfoam2312/platforms/linux64GccDPInt32Opt/bin/simpleFoam
copy tutorial files
$ cd ~/tmp
$ cp -r /usr/lib/openfoam/openfoam2312/tutorials/incompressible/simpleFoam/pitzDaily .
$ cd pitzDaily
$ tree
.
|-- 0
| |-- U
| |-- epsilon
| |-- k
| |-- nuTilda
| |-- nut
| |-- omega
| `-- p
|-- constant
| |-- transportProperties
| `-- turbulenceProperties
`-- system
|-- blockMeshDict
|-- controlDict
|-- fvSchemes
|-- fvSolution
`-- streamlines
mesh作成
$ pwd
/home/end0tknr/tmp/pitzDaily
$ blockMesh
/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2312 |
| \\ / A nd | Website: www.openfoam.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : _c39a0f64-20231220 OPENFOAM=2312 version=2312
Arch : "LSB;label=32;scalar=64"
Exec : blockMesh
Date : Jan 02 2024
Time : 21:22:28
Host : a64
PID : 548
I/O : uncollated
Case : /home/end0tknr/tmp/pitzDaily
nProcs : 1
trapFpe: Floating point exception trapping enabled (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster
(fileModificationSkew 5, maxFileModificationPolls 20)
allowSystemOperations : Allowing user-supplied system call operations
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time
Creating block mesh from "system/blockMeshDict"
Creating block edges
No non-planar block faces defined
Creating topology blocks
Creating topology patches - from boundary section
Creating block mesh topology - scaling/transform applied later
Check topology
Basic statistics
Number of internal faces : 5
Number of boundary faces : 20
Number of defined boundary faces : 20
Number of undefined boundary faces : 0
Checking patch -> block consistency
Creating block offsets
Creating merge list (topological search)...
Creating polyMesh from blockMesh
Creating patches
Creating cells
Creating points with scale (0.001 0.001 0.001)
Block 0 cell size :
i : 0.00158284 .. 0.000791418
j : 0.000318841 .. 0.000420268
k : 0.001 .. 0.001
Block 1 cell size :
i : 0.000528387 .. 0.00211355
j : 0.00112889 .. 0.000360188
k : 0.001 .. 0.001
Block 2 cell size :
i : 0.000528387 .. 0.00211355
j : 0.000318841 .. 0.000420268
k : 0.001 .. 0.001
Block 3 cell size :
i : 0.0020578 .. 0.00514451
j : 0.000940741 .. 0.000940741
k : 0.001 .. 0.001
Block 4 cell size :
i : 0.0020466 .. 0.00511651
j : 0.00112889 .. 0.000257962
k : 0.001 .. 0.001
No patch pairs to merge
Writing polyMesh with 0 cellZones
----------------
Mesh Information
----------------
boundingBox: (-0.0206 -0.0254 -0.0005) (0.29 0.0254 0.0005)
nPoints: 25012
nCells: 12225
nFaces: 49180
nInternalFaces: 24170
----------------
Patches
----------------
patch 0 (start: 24170 size: 30) name: inlet
patch 1 (start: 24200 size: 57) name: outlet
patch 2 (start: 24257 size: 223) name: upperWall
patch 3 (start: 24480 size: 250) name: lowerWall
patch 4 (start: 24730 size: 24450) name: frontAndBack
End
simpleFoam ソルバ実行
$ pwd
/home/end0tknr/tmp/pitzDaily
$ simpleFoam
<略>
Time = 281
smoothSolver: Solving for Ux, Initial residual = 0.000121136, Final residual = 1.17873e-05, No Iterations 5
smoothSolver: Solving for Uy, Initial residual = 0.000989188, Final residual = 6.88795e-05, No Iterations 6
GAMG: Solving for p, Initial residual = 0.000787777, Final residual = 6.99625e-05, No Iterations 5
time step continuity errors : sum local = 0.0033408, global = -0.000239685, cumulative = 1.10095
smoothSolver: Solving for epsilon, Initial residual = 0.000121974, Final residual = 6.91195e-06, No Iterations 3
smoothSolver: Solving for k, Initial residual = 0.000228394, Final residual = 1.42278e-05, No Iterations 4
ExecutionTime = 3.97 s ClockTime = 4 s
SIMPLE solution converged in 281 iterations
streamLine streamlines write:
seeded 10 particles
Tracks:10
Total samples:10885
End
ParaViewで表示
$ pwd /home/end0tknr/tmp/pitzDaily $ touch pitzDaily.foam
後は先程のentryと同様です
