boundary condition of an internal surface
Dear all,
I would like to calculate mass flow rate of a small surface put in flow. The surface is put just for calculating flow rate so it should not affect the flow. The solver I use is interFoam. I wonder if I have to define the small surface as a patch and pose boundary condition of gradient zero for pressure, velocity, and volume fraction or there is other better ways. I’d be glad if you give me advice. Thank you in advance for your help. Yu |
Dear Yu,
Sampling data is explained in paragraph 6.5 of the OF user guide. You can take samples anywhere in your domain without defining a surface, just create a file called sampleDict. Regards, Kevin |
Dear Kevin,
Thank you for your advice. It’s great that if I don’t have to specify patch for my purpose since I don’t have to think about boundary condition that doesn’t affect the flow. I have a question about the sampleDict. According to the paragraph 6.5 of the OF user guide, it seems that I could choose keyword "surfaces" in the sampleDict. http://www.openfoam.com/docs/user/sa...hp#x34-2001106 The shape of a surface where I want to calculate flow rate is an ellipse so I want to know how to calculate flow rate on surface with any shape. I think it can be specified by the STL file. I am wondering if that is possible in sampleDict. Or if there is any other way to solve my problem and teach me it would be appreciated. Best regards, Yu |
You could create a surface/patch to take samples. This is certainly possible for boundary patches but I'm not sure how it works with patches in the middle of a domain.
Another way is to use the 'cloud' option in the sampleDict and specify the coordinates of the points (on your ellipse) you want to sample. Regards, Kevin |
Hello Kevin,
Thank you for your reply. It is very helpful. About the first way you mentioned I’m not sure but it seems that I have to define boundary patches so I need to think about proper boundary conditions that don’t affect flow around the patch. The second way seems to work. For example, I may need a STL file for the shape such as an ellipse, then get the area and the coordinates of a triangle consisting of the STL, then get velocity for the coordinate by sampleDict with ‘cloud’ option, then calculate flow rate by multiplying the velocity by the area for a triangle and summing up them. I may need to make a program to calculate it. Yu |
hi ynsudo,
I have the same problem: I want to have the flow rate throug a given surface. The surface is already defined in my mesh so it would be a boundary patch or a cyclic patch. What I do not uynderstand when I look at the SampleDict example in the Userguide is how to find the syntaxe for programming the flow rate through each face of the patch surface and then sum it over all the faces of the surface patch. surface Any help would be welcomed. Thanks |
Hello Miles
I am trying to use a routine named calcMassFlow to calculate the mass flow rate. http://openfoamwiki.net/index.php/Contrib_calcMassFlow There would be a program for higher versions. This routine could calculate the mass flow rate for one-phase flow. If you would like to calculate the mass flow rate for two-phase flow you would need to modify the program. Best, Yu |
Thanks you
I am gonna check this... as soon as I have found a good programming tuto on openfoam. |
All times are GMT -4. The time now is 12:38. |