|
[Sponsors] |
November 13, 2014, 20:37 |
No cells read from file ".msh"
|
#1 |
Member
Join Date: Nov 2014
Posts: 88
Rep Power: 12 |
Hi everyone,
I have this error when I used gmshToFoam which I can't understand what I have not done correctly. Code:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // Create time Starting to read mesh format at line 2 Read format version 2.2 ascii 0 Starting to read physical names at line 5 Physical names:7 Surface 1 WTInlet Surface 2 WTOutlet Surface 3 Walls Surface 4 ADInet Surface 5 ADOutlet Volume 6 WT Volume 7 AD Starting to read points at line 15 Vertices to be read:89657 Vertices read:89657 Starting to read cells at line 89675 Cells to be read:178816 Mapping region 4 to Foam patch 0 Mapping region 5 to Foam patch 1 Mapping region 1 to Foam patch 2 Mapping region 3 to Foam patch 3 Cells: total:0 hex :0 prism:0 pyr :0 tet :0 --> FOAM FATAL IO ERROR: No cells read from file "adexpt.msh" Does your file specify any 3D elements (hex=5, prism=6, pyramid=7, tet=4)? Perhaps you have not exported the 3D elements? file: adexpt.msh at line 268493. From function readCells(..) in file gmshToFoam.C at line 726. FOAM exiting Appreciate any help please. |
|
November 13, 2014, 20:53 |
|
#2 |
Member
Join Date: Nov 2014
Posts: 88
Rep Power: 12 |
I found my answer.
OF only deals with 3D mesh. so I had to export the msh in 3D meshes, not 2D. cheers. |
|
February 2, 2015, 11:06 |
|
#3 | |
Senior Member
ok
Join Date: Oct 2013
Posts: 346
Rep Power: 14 |
Quote:
actually, I got the same problem that you posted. How could changed the file below from 2D to 3D mesh? Could you help please. Here is my gmsh file Code:
D = 1; R = 0.5*D; CX = 4*D; CY = 0.0; S = 1.0/Sqrt(2); DR1 = R*S; DR2 = (R + 2.0*D)*S; Point(1) = {0, -4*D, 0}; Point(2) = {0, CY - DR2, 0}; Point(3) = (0, CY + DR2, 0); Point(4) = {0, 4*D, 0}; Point(5) = {CX - DR2, -4*D, 0}; Point(6) = {CX - DR2, CY - DR2, 0}; Point(7) = {CX - DR2, CY + DR2, 0}; Point(8) = {CX - DR2, 4*D, 0}; Point(9) = {CX - DR1, CY - DR1, 0}; Point(10) = {CX - DR1, CY + DR1, 0}; Point(11) = {CX, CY, 0}; Point(12) = {CX + DR1, CY - DR1, 0}; Point(13) = {CX + DR1, CY + DR1, 0}; Point(14) = {CX + DR2, -4*D, 0}; Point(15) = {CX + DR2, CY - DR2, 0}; Point(16) = {CX + DR2, CY + DR2, 0}; Point(17) = {CX + DR2, 4*D, 0}; Point(18) = {16*D, -4*D, 0}; Point(19) = {16*D, CY - DR2, 0}; Point(20) = {16*D, CY + DR2, 0}; Point(21) = {16*D, 4*D, 0}; Point(22) = {0, CY, 0}; Point(23) = {CX - 2*D, CY, 0}; Point(24) = {CX + 2*D, CY, 0}; Point(25) = {16*D, CY, 0}; Point(26) = {CX, -4*D, 0}; Point(27) = {CX, CY - 2*D, 0}; Point(28) = {CX, CY + 2*D, 0}; Point(29) = {CX, 4*D, 0}; Point(30) = {CX, CY - R, 0}; Point(31) = {CX - R, CY, 0}; Point(32) = {CX, CY + R, 0}; Point(33) = {CX + R, CY, 0}; Line(1) = {4, 8}; Line(2) = {8, 29}; Line(3) = {29, 17}; Line(4) = {17, 21}; Line(5) = {21, 20}; Line(6) = {20, 25}; Line(7) = {25, 19}; Line(8) = {19, 18}; Line(9) = {18, 14}; Line(10) = {14, 26}; Line(11) = {26, 5}; Line(12) = {5, 1}; Line(13) = {1, 2}; Line(14) = {2, 22}; Line(15) = {22, 3}; Line(16) = {3, 4}; Line(17) = {3, 7}; Line(18) = {7, 8}; Line(19) = {2, 6}; Line(20) = {6, 5}; Line(21) = {15, 14}; Line(22) = {15, 19}; Line(23) = {16, 17}; Line(24) = {16, 20}; Line(25) = {25, 24}; Line(26) = {23, 22}; Line(27) = {28, 29}; Line(28) = {27, 26}; Line(29) = {27, 15}; Line(30) = {15, 24}; Line(31) = {24, 16}; Line(32) = {16, 28}; Line(33) = {28, 7}; Line(34) = {7, 23}; Line(35) = {23, 6}; Line(36) = {6, 27}; Line(37) = {30, 27}; Line(38) = {31, 23}; Line(39) = {33, 24}; Line(40) = {32, 28}; Line(41) = {10, 7}; Line(42) = {9, 6}; Line(43) = {13, 16}; Line(44) = {12, 15}; Circle(45) = {31, 11, 10}; Circle(46) = {10, 11, 32}; Circle(47) = {32, 11, 13}; Circle(48) = {13, 11, 33}; Circle(49) = {33, 11, 12}; Circle(50) = {12, 11, 30}; Circle(51) = {30, 11, 9}; Circle(52) = {9, 11, 31}; Line Loop(53) = {17, 18, -1, -16}; Ruled Surface(54) = {53}; Line Loop(55) = {33, 18, 2, -27}; Ruled Surface(56) = {55}; Line Loop(57) = {32, 27, 3, -23}; Ruled Surface(58) = {57}; Line Loop(59) = {24, -5, -4, -23}; Ruled Surface(60) = {59}; Line Loop(61) = {25, 31, 24, 6}; Ruled Surface(62) = {61}; Line Loop(63) = {30, -25, 7, -22}; Ruled Surface(64) = {63}; Line Loop(65) = {8, 9, -21, 22}; Ruled Surface(66) = {65}; Line Loop(67) = {21, 10, -28, 29}; Ruled Surface(68) = {67}; Line Loop(69) = {11, -20, 36, 28}; Ruled Surface(70) = {69}; Line Loop(71) = {12, 13, 19, 20}; Ruled Surface(72) = {71}; Line Loop(73) = {19, -35, 26, -14}; Ruled Surface(74) = {73}; Line Loop(75) = {34, 26, 15, 17}; Ruled Surface(76) = {75}; Line Loop(77) = {42, -35, -38, -52}; Ruled Surface(78) = {77}; Line Loop(79) = {36, -37, 51, 42}; Ruled Surface(80) = {79}; Line Loop(81) = {29, -44, 50, 37}; Ruled Surface(82) = {81}; Line Loop(83) = {44, 30, -39, 49}; Ruled Surface(84) = {83}; Line Loop(85) = {39, 31, -43, 48}; Ruled Surface(86) = {85}; Line Loop(87) = {43, 32, -40, 47}; Ruled Surface(88) = {87}; Line Loop(89) = {46, 40, 33, -41}; Ruled Surface(90) = {89}; Line Loop(91) = {38, -34, -41, -45}; Ruled Surface(92) = {91}; RHO1 = 20; // Vertical near-wall parts RHO2 = 15; RHO3 = 15; RHO4 = 100; // Outlet channel RHO5 = 20; RHO6 = 20; // Inlet channel RHO7 = 30; Transfinite Line {13, 20, 28, 21, 8} = RHO1; Transfinite Line {16, 18, 27, 23, 5} = RHO1; Transfinite Line {15, 34, 45} = RHO2; // Dense mesh in the middle Transfinite Line {48, 6} = RHO7 Using Progression 0.97; Transfinite Line {31} = RHO7 Using Progression 1.03; Transfinite Line {14, 35, 52} = RHO2; // Dense mesh in the middle Transfinite Line {49, 7} = RHO7 Using Progression 1.03; Transfinite Line {30} = RHO7 Using Progression 0.97; Transfinite Line {11, 36, 51, 46, 33, 2} = RHO3; Transfinite Line {10, 29, 50, 47, 32, 3} = RHO3; Transfinite Line {9, 22, 25, 24, 4} = RHO4; Transfinite Line {42, 37, 44, 39, 43, 40, 41, 38} = RHO5 Using Progression 1.02; Transfinite Line {1, 17, 26, 19, 12} = RHO6; Transfinite Surface "*"; Recombine Surface "*"; Extrude {0, 0, D} { Surface{54, 76, 74, 72, 70, 80, 78, 92, 90, 56, 58, 88, 86, 84, 82, 68, 66, 64, 62, 60}; Layers{1}; Recombine; } Line Loop(533) = {52, 45, 46, 47, 48, 49, 50, 51}; Plane Surface(534) = {533}; cylindervolume[]={Extrude {0, 0, D} { Surface{534}; Layers{1}; Recombine; } }; //cylindervolume[] is a list //with this naming policy i do not need to know the volume ID to set a group on it Physical Surface("inlet") = {113, 131, 157, 171}; Physical Surface("outlet") = {453, 483, 509, 523}; Physical Surface("walls") = {167, 189, 435, 457, 527, 329, 307, 109}; Physical Surface("cylinder") = {417, 399, 377, 219, 245, 267, 277, 355}; Physical Surface("top") = {114, 136, 158, 180, 202, 444, 466, 488, 510, 532, 334, 312, 246, 224, 422, 400, 378, 356, 290, 268}; Physical Surface("bottom") = {54, 76, 74, 72, 70, 68, 66, 64, 62, 60, 58, 56, 92, 78, 80, 82, 84, 86, 88, 90}; Physical Volume("channel") = {5, 4, 3, 7, 6, 15, 16, 14, 17, 18, 19, 20, 11, 12, 13, 9, 8, 10, 1, 2}; Physical Volume("cylinderv") = cylindervolume[]; //Mesh 3; Save "elastic_cylinder-2D.msh"; Maimouna |
||
April 23, 2018, 16:12 |
|
#4 |
New Member
Gazi Yavuz
Join Date: Apr 2018
Posts: 17
Rep Power: 8 |
Can someone please help because i have the same problem and there is no info about that. I can not overcome that error
|
|
May 15, 2018, 07:23 |
|
#5 |
New Member
M Kaushik Reddy
Join Date: May 2018
Posts: 2
Rep Power: 0 |
Please help me out on how to export it into a 3D mesh. Someone?
|
|
August 13, 2018, 16:42 |
|
#6 |
New Member
Gazi Yavuz
Join Date: Apr 2018
Posts: 17
Rep Power: 8 |
I found the solution. You must specify 1 iterated extrusion through the 2D plane in order to define a unit cell for the direction through which flow goes. Even though you solve a 2-Dimensional problem, your domain must have that width for OpenFoam to solve the problem.
|
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[OpenFOAM.org] Patches to compile OpenFOAM 2.2 on Mac OS X | gschaider | OpenFOAM Installation | 136 | October 10, 2017 18:25 |
[swak4Foam] groovyBC in openFOAM-2.0 for parabolic velocity bc | ofslcm | OpenFOAM Community Contributions | 25 | March 6, 2017 11:03 |
[OpenFOAM.org] Error creating ParaView-4.1.0 OpenFOAM 2.3.0 | tlcoons | OpenFOAM Installation | 13 | April 20, 2016 18:34 |
[Other] Adding solvers from DensityBasedTurbo to foam-extend 3.0 | Seroga | OpenFOAM Community Contributions | 9 | June 12, 2015 18:18 |
Trouble compiling utilities using source-built OpenFOAM | Artur | OpenFOAM Programming & Development | 14 | October 29, 2013 11:59 |