CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM

need help

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 21, 2011, 09:30
Default need help
  #1
New Member
 
gaofeng
Join Date: Jun 2011
Posts: 19
Rep Power: 14
windwin is on a distinguished road
hi guys
i just begin to use openfoam for some simulition, and some problems that i cannot understand made me so crazy ,unfortunately the tutoriel didnt help too much so i rly need your help , thank you

the following is my blockmeshdict:



/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.6 |
| \\ / A nd | Web: http://www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
object blockMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

convertToMeters 0.01;



vertices // definition des points
(
(0 0 0) //0
(235 0 0) //1
(265 0 0) //2
(500 0 0) //3
(0 20 0) //4
(235 20 0) //5
(0 180 0 ) //6
(235 180 0) //7
(265 180 0) //8
(500 180 0)//9
(0 200 0) //10
(500 200 0) //11
(0 0 200) //12
(235 0 200) //13
(265 0 200) //14
(500 0 200) //15
(0 20 200) //16
(235 20 200) //17
(0 180 200) //18
(235 180 200) //19
(265 180 200) //20
(500 180 200) //21
(0 200 200) //22
(500 200 200) //23
);
blocks
(
hex (0 1 5 4 12 13 17 16) (235 20 1) simpleGrading (1 1 1)
hex (4 5 7 6 16 17 19 18) (235 160 1) simpleGrading (1 1 1)
hex (1 2 8 7 13 14 20 19) (30 180 1) simpleGrading (1 1 1)
hex (2 3 9 8 14 15 21 20) (235 180 1) simpleGrading (1 1 1)
hex (6 9 11 10 18 21 23 22) (500 20 1) simpleGrading (1 1 1)
);
patches
(

patch fixedWalls
(
(10 22 23 11)
(22 10 6 18)
(18 6 4 16)
(21 15 3 9)
(0 1 13 12)
(2 3 15 14)
)

patch entree
(
(1 2 14 13)
)

patch sortie
(
(16 4 0 12)
(11 23 21 9)
)

empty front
(
(16 12 13 17)
(18 16 17 19)
(13 14 20 19)
(20 14 15 21)
(22 18 21 23)
)

empty back
(
(0 4 5 1)
(4 6 7 5)
(1 7 8 2)
(2 8 9 3)
(10 11 9 6)
)

);




i run blockMesh and every thing is ok, but when i run icoFoam ,i get the following error message:

--> FOAM FATAL ERROR:
This mesh contains patches of type empty but is not 1D or 2D
by virtue of the fact that the number of faces of this
empty patch is not divisible by the number of cells.

From function emptyFvPatchField<Type>::updateCoeffs()
in file fields/fvPatchFields/constraint/empty/emptyFvPatchField.C at line 150.



so can somebody tell me what problem it is and how i can fix it

thank you very much
windwin is offline   Reply With Quote

Old   June 21, 2011, 10:34
Default
  #2
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,266
Blog Entries: 1
Rep Power: 24
nimasam is on a distinguished road
you have several regions not just one region so the internal patches should have the same number of common faces if not u should merge them together as a slave and master in user guide you can find more
nimasam is offline   Reply With Quote

Old   June 21, 2011, 11:09
Default
  #3
New Member
 
gaofeng
Join Date: Jun 2011
Posts: 19
Rep Power: 14
windwin is on a distinguished road
Quote:
Originally Posted by nimasam View Post
you have several regions not just one region so the internal patches should have the same number of common faces if not u should merge them together as a slave and master in user guide you can find more

hi nimasam
thank you for your help, but i think i didnt get your point , internal patches and common faces are the same things, am i right ? so their numbers are the same , i dont understand exactely what do you mean by this in my mesh , excuse me but im a rly beginner

best
windwin is offline   Reply With Quote

Old   June 21, 2011, 12:51
Default
  #4
Senior Member
 
mturcios777's Avatar
 
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28
mturcios777 will become famous soon enough
If you look at your mesh in paraFoam, you will notice that you have 3 faces that have no boundary condition, and by default are set to empty. Since it appears you are trying to do a 2D simulation, you only need the empty faces on the front and back of the domain. There is a face on the top and a face between two regions.

Run blockMesh again with the option -blockTopology, then run objToVTK and check the converted VTK file to determine that your geometry is sound, as it seems there are some problems that prevent blockMesh from recognizing internal faces. Good luck
mturcios777 is offline   Reply With Quote

Old   June 21, 2011, 14:08
Default
  #5
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,266
Blog Entries: 1
Rep Power: 24
nimasam is on a distinguished road
becareful! i didnot look at ur blockMesh file: i just review two more common mistakes that cuase such a error!
for every hex blocks , you have 6 patches, some of these patches are internal pateches, now imagine two hex blocks are set beside each other! so they share a patch , when two hex blocks share a patch together! this patch should have the same number of cell division in both side! did you get ?
another situation happens when a patch share among more than two hex blocks! then you should names these internal patches and use master and slave configuration to merge the internal patches! (look user guide for merge patch)

be lucky
nimasam is offline   Reply With Quote

Old   June 22, 2011, 09:13
Default
  #6
New Member
 
gaofeng
Join Date: Jun 2011
Posts: 19
Rep Power: 14
windwin is on a distinguished road
Quote:
Originally Posted by mturcios777 View Post
If you look at your mesh in paraFoam, you will notice that you have 3 faces that have no boundary condition, and by default are set to empty. Since it appears you are trying to do a 2D simulation, you only need the empty faces on the front and back of the domain. There is a face on the top and a face between two regions.

Run blockMesh again with the option -blockTopology, then run objToVTK and check the converted VTK file to determine that your geometry is sound, as it seems there are some problems that prevent blockMesh from recognizing internal faces. Good luck
hi mturcios777 !

thank you so much for your help, i agree with you on the fact that there are some problems that prevent blockMesh from recognizing internal faces,
the geometry i've got from parafoam is not what it is supposed to be ,in fact in my mesh there are 4 defaut faces, but after running parafoam there are only 2, i just can not understand how it comes !!!

and as you said i run blockMesh with the option -blockTopology,then objToVTK, but i got the following error message :



cendre:~/maquettei> objToVTK

Usage: objToVTK <OBJ file> <output VTK file> [-case dir] [-help] [-doc] [-srcDoc]



--> FOAM FATAL ERROR:
Wrong number of arguments, expected 2 found 0



thank you for your help again

best
windwin is offline   Reply With Quote

Old   June 22, 2011, 11:53
Default
  #7
Senior Member
 
mturcios777's Avatar
 
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28
mturcios777 will become famous soon enough
Glad to be of help. The message you are getting tells you that you need to supply more parameters. In this case, the .obj file, the name of the vtk file you want to write to (including .vtk extension) and the case if it is not in the present working directory.

Now you can visualize just the points from your mesh in ParaView, as well as their connectivity. They should be numbered the same as from your blockMesh file, and help you figure our where the connectivity is messed up.
mturcios777 is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 23:22.