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

Mass Weighted Average

Register Blogs Community New Posts Updated Threads Search

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   December 11, 2012, 13:40
Default Mass Weighted Average
  #1
Member
 
Brock Lee
Join Date: Sep 2012
Location: Midwest
Posts: 40
Rep Power: 13
GRAUPS is on a distinguished road
Hey guys, I'm looking to calculate a mass weighted average over a faceZone for pressure using swak4foam. Specifically, this is the equation I'm trying to implement...

Capture.PNG

My question comes when trying to implement. Is it possible in swak4foam to divide a sum by a sum within one expression? Can I do two sums separately and divide them? So far I've only seen expressions that can do one accumulation, such as the one below for mass flow rate...

Code:
mass-in
    {
        type swakExpression;
        valueType faceZone;
        zoneName interior-inlet-1;
        expression "phi*flip()";
        accumulations (
            sum
        );
        verbose true;
	autoInterpolate	true;
    }
Also, (if possible) what is the syntax for getting the absolute value and dot product within a swakExpression? Thanks in advance!
Attached Images
File Type: jpg Capture.jpg (10.7 KB, 50 views)
GRAUPS is offline   Reply With Quote

 

Tags
mass weighted average, swak4foam, swakexpression


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
Area weighted or mass weighted average SAM Main CFD Forum 31 April 30, 2018 04:12
Diffference between mass weighted average and Area giogio FLUENT 9 March 6, 2018 08:24
mass weighted average calculation m&s FLUENT 0 April 6, 2010 11:52
Mass Weighted Average Maryam FLUENT 0 November 12, 2008 07:06
Mass Weighted Average Maryam CFX 0 November 12, 2008 07:03


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