CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[OpenFOAM] How to calculate mass flow rate through arbitrary rectangle plane in paraview

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By tomf

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 10, 2016, 02:16
Default How to calculate mass flow rate through arbitrary rectangle plane in paraview
  #1
Member
 
Manoj
Join Date: Jun 2013
Posts: 38
Rep Power: 12
manoj_nav is on a distinguished road
Hi All,

I am trying to calculate mass flow rate at 12 HVAC vents opening. These openings are not defined as patch or face. They are interior of the domain. I want to define plane/rectangle of a give size at these opening locations to calculate the mass flow rate through them. But when I create a plane in paraview using sources > plane, the plane doesn't have nay data field - U or p.
Please help me to calculate mass flow rate at arbitrary plane in the domain. When I use slice or cut plane, it cuts through the whole domain, which I don't want.

Regards,

Manoj
manoj_nav is offline   Reply With Quote

Old   March 11, 2016, 05:04
Default
  #2
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 634
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Hi,

If you want to use the plane from sources, you need to do resampleWithDataSet.

I typically use the following sequence of filters: Slice>Connectivity>threshold on the "regionID" (see example images)

Regards,
Tom
Attached Images
File Type: png Pipeline.png (7.4 KB, 191 views)
File Type: png RegionId.png (6.4 KB, 107 views)
manoj_nav likes this.
tomf is offline   Reply With Quote

Old   March 11, 2016, 06:28
Default
  #3
Senior Member
 
Thomas Oliveira
Join Date: Apr 2015
Posts: 114
Rep Power: 12
t.oliveira is on a distinguished road
Quote:
Originally Posted by manoj_nav View Post
Hi All,
when I create a plane in paraview using sources > plane, the plane doesn't have nay data field - U or p.
Dear Manoj,

Does the solution have to involve paraview? Can't it be using a functionObject?

Thomas Oliveira
t.oliveira is offline   Reply With Quote

Old   March 14, 2016, 10:39
Default
  #4
Member
 
Manoj
Join Date: Jun 2013
Posts: 38
Rep Power: 12
manoj_nav is on a distinguished road
Quote:
Originally Posted by tomf View Post
Hi,

If you want to use the plane from sources, you need to do resampleWithDataSet.

I typically use the following sequence of filters: Slice>Connectivity>threshold on the "regionID" (see example images)

Regards,
Tom
Thanks Tom. After using resampleWithDataSet, it works.

When I use sequence of filters: Slice>Connectivity .. I get just one region ID - 0, as in the attached snapshot. How to use the threshold then. Sorry for my ignorance..

Regards,

Manoj
Attached Images
File Type: jpg 3.jpg (6.0 KB, 91 views)
manoj_nav is offline   Reply With Quote

Old   March 14, 2016, 10:41
Default
  #5
Member
 
Manoj
Join Date: Jun 2013
Posts: 38
Rep Power: 12
manoj_nav is on a distinguished road
Quote:
Originally Posted by t.oliveira View Post
Dear Manoj,

Does the solution have to involve paraview? Can't it be using a functionObject?

Thomas Oliveira
Thanks Thomas for the reply. How to use functionObject to calculate mass flow rate through an arbitrary plane?

Regards,

Manoj
manoj_nav is offline   Reply With Quote

Old   March 17, 2016, 02:51
Default
  #6
Member
 
Manoj
Join Date: Jun 2013
Posts: 38
Rep Power: 12
manoj_nav is on a distinguished road
Quote:
Originally Posted by t.oliveira View Post
Dear Manoj,

Does the solution have to involve paraview? Can't it be using a functionObject?

Thomas Oliveira
I tried using functionObject. But I am getting following error ,

keyword sourceName is undefined in dictionary "/home/manoj/trial/vent/system/controlDict.functions.new_plane"

Code:
functions
{


    new_plane
    {
        type            faceSource;
        functionObjectLibs ("libfieldFunctionObjects.so");
        enabled         true;
        outputControl   outputTime;
        log             true;
        valueOutput     true;
        source          sampledSurface;

        sampledSurfaceDict
        {
         type        sampledTriSurfaceMesh;
         surface     opening.stl;
         source      cells;  // What to sample: cells (nearest cell)
                                    // insideCells (only triangles inside cell)
                                    // boundaryFaces (nearest boundary face)
         interpolate true;
        }

        operation       areaAverage;

        fields
        (
            U
        );
    }
}
I get the same error, when I use packaged function objects

Code:
functions
{
  #include "volFlowRateSurface"

}
Please help.

Regards,

Manoj
manoj_nav is offline   Reply With Quote

Old   March 18, 2016, 12:27
Default
  #7
Senior Member
 
Tom Fahner
Join Date: Mar 2009
Location: Breda, Netherlands
Posts: 634
Rep Power: 32
tomf will become famous soon enoughtomf will become famous soon enough
Send a message via MSN to tomf Send a message via Skype™ to tomf
Quote:
Originally Posted by manoj_nav View Post
Thanks Tom. After using resampleWithDataSet, it works.

When I use sequence of filters: Slice>Connectivity .. I get just one region ID - 0, as in the attached snapshot. How to use the threshold then. Sorry for my ignorance..

Regards,

Manoj
Hi,

In that case there is no possibility for the threshold filter. I had assumed you would have some distinct regions for each opening, maybe you could make a clear sketch of what you are trying to do.

Regards,
Tom
tomf is offline   Reply With Quote

Old   April 1, 2016, 07:14
Default
  #8
Senior Member
 
Thomas Oliveira
Join Date: Apr 2015
Posts: 114
Rep Power: 12
t.oliveira is on a distinguished road
Quote:
Originally Posted by manoj_nav View Post
I tried using functionObject. But I am getting following error:
keyword sourceName is undefined in dictionary "/home/manoj/trial/vent/system/controlDict.functions.new_plane
I am sorry Manoj I haven't seen your message before.

Check this post, which offers another way of defining a (infinite) plane that may be useful to you : http://www.cfd-online.com/Forums/ope...tml#post581774


Regarding the error your received, have you tried inserting the keyword sourceName inside the new_plane dictionary, like below? That is what the error message says.

Code:
functions
{


    new_plane
    {
        type            faceSource;
        functionObjectLibs ("libfieldFunctionObjects.so");
        enabled         true;
        outputControl   outputTime;
        log             true;
        valueOutput     true;
        source          sampledSurface;
        sourceName      anyNameYouLike;
        ...
Best wishes,
Thomas
t.oliveira 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
Specify mass flow rate for periodic boundary conditions in channel flow lion1990 OpenFOAM Running, Solving & CFD 1 July 9, 2018 17:46
Pressure Outlet Targeted Mass Flow Rate LuckyTran FLUENT 1 November 23, 2016 10:40
Periodic channel flow with time dependent mass flow rate QBeast FLUENT 3 May 10, 2013 13:14
Discrete Phase & Mass Flow Rate MagnusZeus FLUENT 0 December 2, 2011 17:57
particle, parcel and mass flow rate balance flybird FLUENT 0 May 24, 2007 10:44


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