修改boundary文件中的类型导致错误
-
各位佬,本人初学openfoam,网格划分采用ICEM,做的算例是NACA0018的升阻力系数计算,画的是一个三维网格,想要导入of后将front和back设为empty,以此来进行二维翼型的运算,报错为:
Number of edges not aligned with or perpendicular to non-empty directions: 8191
Writing 16382 points on non-aligned edges to set nonAlignedEdges网格展向0.01m,划分为一个网格,网格如下:
在导入后boundary文件如下:
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | foam-extend: Open Source CFD | | \\ / O peration | Version: 3.2 | | \\ / A nd | Web: http://www.foam-extend.org | | \\/ M anipulation | For copyright notice see file Copyright | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class polyBoundaryMesh; location "constant/polyMesh"; object boundary; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 4 ( AIRFOIL { type wall; nFaces 488; startFace 124440; } BACK { type symmetryPlane; nFaces 62464; startFace 124928; } FRONT { type symmetryPlane; nFaces 62464; startFace 187392; } FAR { type patch; nFaces 488; startFace 249856; } ) // ************************************************************************* //
checkMesh的结果如下:
/*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | foam-extend: Open Source CFD | | \\ / O peration | Version: 3.2 | | \\ / A nd | Web: http://www.foam-extend.org | | \\/ M anipulation | For copyright notice see file Copyright | \*---------------------------------------------------------------------------*/ Build : 3.2-0b2838935026 Exec : checkMesh Date : Jul 24 2024 Time : 13:00:35 Host : ad PID : 24129 CtrlDict : "/home/ad/foam/ad-3.2/run/try4/18/system/controlDict" Case : /home/ad/foam/ad-3.2/run/try4/18 nProcs : 1 SigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create polyMesh for time = 0 Time = 0 Mesh stats all points: 125904 live points: 125904 all faces: 250344 live faces: 250344 internal faces: 124440 cells: 62464 boundary patches: 4 point zones: 0 face zones: 1 cell zones: 1 Overall number of cells of each type: hexahedra: 62464 prisms: 0 wedges: 0 pyramids: 0 tet wedges: 0 tetrahedra: 0 polyhedra: 0 Checking topology... Boundary definition OK. Point usage OK. Upper triangular ordering OK. Face vertices OK. Number of regions: 1 (OK). Checking patch topology for multiply connected surfaces ... Patch Faces Points Area [m^2] Surface topology AIRFOIL 488 976 0.0207938 ok (non-closed singly connected) BACK 62464 62952 737.046 ok (non-closed singly connected) FRONT 62464 62952 737.046 ok (non-closed singly connected) FAR 488 976 0.962719 ok (non-closed singly connected) Checking geometry... This is a 3-D mesh Overall domain bounding box (-14.9955 -15.3298 -1.43395e-42) (15.9509 14.9979 0.01) Mesh (non-empty, non-wedge) directions (1 1 1) Mesh (non-empty) directions (1 1 1) Mesh (non-empty, non-wedge) dimensions 3 Boundary openness (-1.86694e-20 -1.04152e-19 -4.57649e-15) Threshold = 1e-06 OK. Max cell openness = 2.46007e-15 OK. Max aspect ratio = 381.414 OK. Minumum face area = 3.3198e-09. Maximum face area = 0.100407. Face area magnitudes OK. Min volume = 3.3198e-11. Max volume = 0.00100407. Total volume = 7.37046. Cell volumes OK. Mesh non-orthogonality Max: 44.6101 average: 9.96793 Threshold = 70 Non-orthogonality check OK. Face pyramids OK. Max skewness = 0.733611 OK. Mesh OK. End
将boundary文件修改为:
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | foam-extend: Open Source CFD | | \\ / O peration | Version: 3.2 | | \\ / A nd | Web: http://www.foam-extend.org | | \\/ M anipulation | For copyright notice see file Copyright | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class polyBoundaryMesh; location "constant/polyMesh"; object boundary; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // 4 ( AIRFOIL { type wall; nFaces 488; startFace 124440; } BACK { type empty; nFaces 62464; startFace 124928; } FRONT { type empty; nFaces 62464; startFace 187392; } FAR { type patch; nFaces 488; startFace 249856; } ) // ************************************************************************* //
checkMesh得到:
/*---------------------------------------------------------------------------*\ | ========= | | | \\ / F ield | foam-extend: Open Source CFD | | \\ / O peration | Version: 3.2 | | \\ / A nd | Web: http://www.foam-extend.org | | \\/ M anipulation | For copyright notice see file Copyright | \*---------------------------------------------------------------------------*/ Build : 3.2-0b2838935026 Exec : checkMesh Date : Jul 24 2024 Time : 13:02:01 Host : ad PID : 24163 CtrlDict : "/home/ad/foam/ad-3.2/run/try4/18/system/controlDict" Case : /home/ad/foam/ad-3.2/run/try4/18 nProcs : 1 SigFpe : Enabling floating point exception trapping (FOAM_SIGFPE). // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Create polyMesh for time = 0 Time = 0 Mesh stats all points: 125904 live points: 125904 all faces: 250344 live faces: 250344 internal faces: 124440 cells: 62464 boundary patches: 4 point zones: 0 face zones: 1 cell zones: 1 Overall number of cells of each type: hexahedra: 62464 prisms: 0 wedges: 0 pyramids: 0 tet wedges: 0 tetrahedra: 0 polyhedra: 0 Checking topology... Boundary definition OK. Point usage OK. Upper triangular ordering OK. Face vertices OK. Number of regions: 1 (OK). Checking patch topology for multiply connected surfaces ... Patch Faces Points Area [m^2] Surface topology AIRFOIL 488 976 0.0207938 ok (non-closed singly connected) BACK 62464 62952 737.046 ok (non-closed singly connected) FRONT 62464 62952 737.046 ok (non-closed singly connected) FAR 488 976 0.962719 ok (non-closed singly connected) Checking geometry... This is a 2-D mesh Overall domain bounding box (-14.9955 -15.3298 -1.43395e-42) (15.9509 14.9979 0.01) Mesh (non-empty, non-wedge) directions (1 1 0) Mesh (non-empty) directions (1 1 0) Mesh (non-empty, non-wedge) dimensions 2 ***Number of edges not aligned with or perpendicular to non-empty directions: 8191 Writing 16382 points on non-aligned edges to set nonAlignedEdges Boundary openness (-1.86694e-20 -1.04152e-19 -4.57649e-15) Threshold = 1e-06 OK. Max cell openness = 2.46007e-15 OK. Max aspect ratio = 381.414 OK. Minumum face area = 3.3198e-09. Maximum face area = 0.100407. Face area magnitudes OK. Min volume = 3.3198e-11. Max volume = 0.00100407. Total volume = 7.37046. Cell volumes OK. Mesh non-orthogonality Max: 44.6101 average: 9.96793 Threshold = 70 Non-orthogonality check OK. Face pyramids OK. Max skewness = 0.733611 OK. Failed 1 mesh checks. End
我该如何修改?