如何在OpenFOAM中實現剛體的強迫運動
為了在OpenFOAM中實現剛體的強迫運動,如指定剛體按照正弦函數運動,需要采用動網格,在V6中,有些函數發生了變化,需要注意。
一種是幾何邊界發生強迫運動,還有一種是流體區域發生強迫運動,這兩種的實現方式如下:
1 幾何邊界強迫運動
1.1 dynamicDic文件
dynamicFvMesh dynamicMotionSolverFvMesh;
motionSolverLibs("libfvMotionSolvers.so");
solver displacementLaplacian;
displacementLaplacianCoeffs
{
diffusivity inverseDistance (cylinder);
}
1.2 pointDisplacement文件
boundaryField
{
……
cylinder
{
type oscillatingDisplacement;//圓柱的運動方式有很多種,可以參見筆記《6DOF-sixDoFRigidBodyMotion參數解讀》。
value uniform ( 0 0 0 );
amplitude ( 0 5 0 );
omega 6.28318; //rad/s
}
}
1.3 fvSolution
在wolfdynamics的例子中,c26直接運行會出錯,原因在于fvSolution中缺少一段話:
"pcorr.*"
{
solver GAMG;
smoother GaussSeidel;
cacheAgglomeration no;
tolerance 0.02;
relTol 0;
}
意思我不懂,但是可以從wingMotion2D_pimple的例子中也可以找到這段話。
效果如下圖:
計算文件請見:case10
2 流體區域運動
因為在網上看到有用solidBodyMotionFvMesh的,所以試了一下。
2.1 dynamicMeshDict文件
dynamicFvMesh dynamicMotionSolverFvMesh;
motionSolverLibs("libfvMotionSolvers.so");
motionSolver solidBody;
cellZone none;// 注意:這里必須為體積域,而非邊界;如果沒有一個cellZone,則用整個區域代替,輸入none,可參照https://openfoamwiki.net/index.php/Parameter_Definitions_-_solidBodyMotionFvMesh#amplitude
solidBodyMotionFunction oscillatingLinearMotion;
amplitude (0 5 0); //該三維矢量大小代表運動幅值,分量制定了振動的方向,所有的分量以相同頻率振動,單位一般定義為m。
omega 6.28318; // rad/s (.5 rps)
2.2 pointDisplacement文件
cylinder
{
type calculated;
uniform (0 0 0);
}
效果如下圖:
2.3 結論
(1) solidBodyMotionFvMesh在v6中不復存在!因此要改為dynamicMotionSolverFvMesh。
(2) solidBodyMotionFunction- oscillatingLinearMotion成功,其cellZone為體積域,而非邊界域。但方式二中整個流體域都在動,因為選了整個流體域。
來源:FSI Center
工程師必備
- 項目客服
- 培訓客服
- 平臺客服
TOP




















