|
[Sponsors] | |||||
|
|
|
#1 |
|
New Member
Ben Connell
Join Date: Apr 2009
Location: Groton, CT, USA
Posts: 6
Rep Power: 6 ![]() |
Hi-
I'm trying to learn how to create meshes in gmsh and import them to openfoam. I think I'm following the proper approach, but when i use gmshtofoam i get a warning that there are undefined faces which are put in a default patch called "defaultFaces". The number of undefined faces is the same as the number of non-volumetric elements (lines and triangles) listed in the msh file. The openfoam grid is generated, but I have this defaultFaces patch that I need to set boundary conditions for ... and I don't know what these conditions should be set as. I have the same problem when using the sample CubeVer1.msh from the openfoam installation, so I don't think it's an issue with the way I'm generating my mesh in gmsh. Am I missing something? Any insight as to how I should set the defaultFaces patch boundary conditions? I was considering writing a program to remove the non-volumetric elements from the msh file. Any help is much appreciated. Thanks -Ben |
|
|
|
|
|
|
|
|
#2 |
|
New Member
Ben Connell
Join Date: Apr 2009
Location: Groton, CT, USA
Posts: 6
Rep Power: 6 ![]() |
I stripped the non-volumetric elements out the the .msh file to test the effect, gmshtofoam still gave the same number of undefined faces.
For the original .msh file it set the p and U boundaries to zerogradient to see what would happen. That solution doesn't look right. -Ben |
|
|
|
|
|
|
|
|
#3 |
|
Senior Member
|
Hi Ben,
Usually you want to define physical surfaces for each patch and a physical volume for the whole mesh. From there, I would not worry about a undefined faces warning and would also not define them in the boundary file. have fun, -Louis |
|
|
|
|
|
|
|
|
#4 |
|
New Member
Ben Connell
Join Date: Apr 2009
Location: Groton, CT, USA
Posts: 6
Rep Power: 6 ![]() |
Thanks Louis-
I did have defined physical surfaces and a physical volume, but it still gave the warning. Of all the combination of things I thought I tried, I guess I didn't try the right combination. When I finally deleted the defaultFaces patch from the "boundary" file (and reduced the corresponding integer number of faces above by one), I was able to ignore the warning and run successfully. Thanks very much for your help, -Ben |
|
|
|
|
|
|
|
|
#5 |
|
New Member
Ben Connell
Join Date: Apr 2009
Location: Groton, CT, USA
Posts: 6
Rep Power: 6 ![]() |
.... in the message above I guess I should have said "integer number of boundary surfaces" (not faces)
|
|
|
|
|
|
|
|
|
#6 |
|
Senior Member
|
glad you got it working
-Louis |
|
|
|
|
|
|
|
|
#7 |
|
Senior Member
Join Date: Sep 2010
Location: Nice (Fr)
Posts: 156
Rep Power: 4 ![]() |
Hi
i deleted defaultFaces, but i don't know where to remove 1 from the faces, can you explain clearly in which file? because in my boundary File i have: defaultFaces { type patch; nFaces 0; startFace 1783; } when i delete it all, it says error: Expected a ')' or a '}' while reading PtrList, etc..... help please, is there any better solution by drawing in gmsh and to get these defaultFaces after conversion by gmshToFoam? thanks a lot |
|
|
|
|
|
|
|
|
#8 |
|
Senior Member
|
In that same file, before the list of faces there is a number, lower that number by one.
Something like Code:
6 ( face1 face2 ... face6 ) -Louis |
|
|
|
|
|
|
|
|
#9 |
|
New Member
Ben Connell
Join Date: Apr 2009
Location: Groton, CT, USA
Posts: 6
Rep Power: 6 ![]() |
I think I had originally misspoke in the above thread, but corrected myself. I meant to reduce the indicated number of surfaces by one in the boundary file (as Louis describes), so that the number listed after removing defaultFaces corresponds to the number at top.
I believe someone posted the instructions on how to set up your GMSH file properly so you don't get defaultFaces, but the method described above works for me and is pretty easy so I haven't changed my ways. Sorry for the late reply (long weekend in the US), and thanks to Louis for picking this up. -Ben |
|
|
|
|
|
|
|
|
#10 |
|
Senior Member
Join Date: Sep 2010
Location: Nice (Fr)
Posts: 156
Rep Power: 4 ![]() |
Hi
thanks a lot it worked thanks T.D. |
|
|
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| DecomposePar unequal number of shared faces | maka | OpenFOAM Pre-Processing | 6 | August 12, 2010 09:01 |
| Error with Wmake | skabilan | OpenFOAM Installation | 3 | July 28, 2009 00:35 |
| OpenFOAM on MinGW crosscompiler hosted on Linux | allenzhao | OpenFOAM Installation | 127 | January 30, 2009 19:08 |
| G95 + CGNS | Bruno | Main CFD Forum | 1 | January 30, 2007 00:34 |
| Building OpenFoAm on SGI Altix 64bits | anne | OpenFOAM Installation | 8 | June 15, 2006 09:27 |