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

Orientation of faceZone, mass flow sign convention

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 28, 2016, 00:53
Angry Orientation of faceZone, mass flow sign convention
  #1
New Member
 
Florian Nguyen
Join Date: Oct 2015
Location: Tokyo, Japan
Posts: 19
Rep Power: 11
Awak is on a distinguished road
Hi,

I am going to ask a question which is going to seem very basic, but you will understand my doubt when I explain.

I am modelling two tanks with 1.0 atm / 0.2 atm connected to each other by a reed valve. I want to measure the mass flow pouring from the high pressure tank to the low pressure tank. For this I use rhoCentralFoam (OF3.0+).

I defined my mesh using blockMesh and SNM, and a faceZone that I use for mass flow estimation. The "faceSet" picture shows the aspect of the faceZone. I checked visually that this face does not have any defects, like unwanted faces. Here is how I defined this face.

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

// * * * * * * * * * * * * * * * * * * * ** * * * * * * * * * * * * * //

actions
(
// Creation of faceSet

{
name inletFaceSet;
type faceSet;
action new;
source boxToFace;
sourceInfo
{
box (0.010 -0.010 0.00099) (0.1 0.010 0.00101);
}
}

// Creation of faceZone from previous faceSet
{
name inletFace;
type faceZoneSet;
action new;
source setAndNormalToFaceZone;
sourceInfo
{
faceSet inletFaceSet;
normal (0 0 1);
}
}

);


// ************************************************** **************** //
I did not detect any anomaly in the pressure or velocity fields during the simuation, especially regarding the direction of velocity.

HOWEVER...

For some reason, when I gradually refine my mesh to check for mass flow convergence, the outputed mass flow's sign, especially the stationary value, is changing sign! It does not make sense to me, because I don't see any such "change" in the velocity and pressure fields. The "velocityAtFace" picture shows the global trend for the velocity field (face is coloured with pressure, arrows according to velocity). This trend is the same for any other refinement level.

My face is defined with a normal (0 0 1). According to the initial pressure difference existing between the tanks, I am expecting a velocity in -Z direction, so a negative mass flow through my face? In that case, I would like to understand why I have positive mass flow values for lower refinement levels and negative values for higher refinement, even if the velocity field appears not to be altered.

My case is available temporarily at: https://drive.google.com/file/d/0B0k...ew?usp=sharing

If you want to see for yourself, just change the refinement levels of regions from 5 to 2 or 0.

Any help would be greatly appreciated, thanks to you all,

Florian
Attached Images
File Type: jpg faceSet.jpg (79.7 KB, 19 views)
File Type: png velocityAtFace.png (193.1 KB, 24 views)

Last edited by Awak; June 28, 2016 at 10:40.
Awak is offline   Reply With Quote

Old   June 28, 2016, 10:40
Default EDIT: Found something rather strange
  #2
New Member
 
Florian Nguyen
Join Date: Oct 2015
Location: Tokyo, Japan
Posts: 19
Rep Power: 11
Awak is on a distinguished road
EDIT:

I cut a 2D slice at the location of the faceSet used for mass flow calculation, and plotted the velocity glyph. The velocity field looks perfectly fine:

Screenshot from 2016-06-28 22:04:34.jpg

Looking from above to this slice, the velocity field looks like this:

Screenshot from 2016-06-28 22:10:27.jpg

Now here comes the funny stuff... I put "valueOutput true;" to export the mass flow field in a VTK file at was looks to be steady state judging from the velocity field, and here is what mass flow distribution looks like on my faceZone:

Screenshot from 2016-06-28 22:14:13.jpg

This is rather confusing... I checked my faceZone before running the solver, so I really don't see what I am doing wrong. Could I have your lights please?
Awak is offline   Reply With Quote

Old   August 1, 2016, 22:28
Default
  #3
New Member
 
Florian Nguyen
Join Date: Oct 2015
Location: Tokyo, Japan
Posts: 19
Rep Power: 11
Awak is on a distinguished road
Solved by constraining the cells by means of an AMI... Hope this will be useful to some of you.

Florian
Awak 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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mass flow discrepancy BenMUC CFX 3 May 2, 2014 04:29
Discrete Phase & Mass Flow Rate MagnusZeus FLUENT 0 December 2, 2011 18:57
Mass flow rate through each cell Babakjingo Main CFD Forum 0 August 21, 2011 04:18
mass flow Wenbin Song FLUENT 0 September 27, 2005 14:00
Target mass flow rate Saturn FLUENT 0 December 10, 2004 05:18


All times are GMT -4. The time now is 09:53.