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

[OpenFOAM] Plotting average Temperatures over line

Register Blogs Community New Posts Updated Threads Search

Like Tree3Likes
  • 3 Post By gschaider

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 28, 2016, 12:40
Default Plotting average Temperatures over line
  #1
New Member
 
Join Date: Jun 2016
Posts: 6
Rep Power: 9
astronauti is on a distinguished road
Hello,

i have a cooler where the exhaust and the water flow is in the same directory (z directory). Now I want to plot the average Temperature in the xy-plane over the z Axis, to see how the Average-Temperature changes over the z-axis. Is this possible with paraFoam.
astronauti is offline   Reply With Quote

Old   October 30, 2016, 12:26
Default
  #2
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by astronauti View Post
Hello,

i have a cooler where the exhaust and the water flow is in the same directory (z directory). Now I want to plot the average Temperature in the xy-plane over the z Axis, to see how the Average-Temperature changes over the z-axis. Is this possible with paraFoam.
The way I would do it (but I'm extremely biased) is with a swak4Foam-function object (this would be in controlDict):
Code:
libs (
    "libsimpleSwakFunctionObjects.so"
);
functions {
    temperatureLine {
        type swakExpressionAverageDistribution;
        outputControlMode outputTime;
        valueType internalField;
        expression "T";
        weight "vol()";
        mask "true";
        abscissa "pos().z";
        binNumber 100;
        valueIfZero -666;
    }
}
This would generate files with the data every time the regular field data gets written (averages are calculated volume-weighted)

Disadvantage is that you will have to install swak4Foam
Bana, Luttappy and astronauti like this.
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request
gschaider is offline   Reply With Quote

Old   October 30, 2016, 15:40
Default
  #3
New Member
 
Join Date: Jun 2016
Posts: 6
Rep Power: 9
astronauti is on a distinguished road
Thank you very much. Swak4foam was already installed, so thats no problem. Managed to get it working for a multiRegion simulation. Whats the difference between the value in key and raw?
astronauti is offline   Reply With Quote

Old   October 30, 2016, 16:28
Default
  #4
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by astronauti View Post
Thank you very much. Swak4foam was already installed, so thats no problem. Managed to get it working for a multiRegion simulation. Whats the difference between the value in key and raw?
You have already been tempted by the Dark Side? Good for you.

"Key" should be the value of the abscissa (in your case z). "Raw" is the weighted average (long story. The name was inherited and I never bothered to change it). "Min" and "Max" should be obvious. "nSamples" is the number of cells that fell into the bin defined by "key" (the sad truth is that it doesn't really "cut" through the simulation but just looks at the cells. But that is much faster and "good enough")
__________________
Note: I don't use "Friend"-feature on this forum out of principle. Ah. And by the way: I'm not on Facebook either. So don't be offended if I don't accept your invitation/friend request
gschaider 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
problem during mpi in server: expected Scalar, found on line 0 the word 'nan' muth OpenFOAM Running, Solving & CFD 3 August 27, 2018 04:18
[OpenFOAM] Take derivative of mean velocity in paraFoam hiuluom ParaView 13 April 26, 2016 06:44
8x icoFoam speed up with Cufflink CUDA solver library kmooney OpenFOAM Running, Solving & CFD 42 November 6, 2012 11:37
1.7.x Environment Variables on Linux 10.04 rasma OpenFOAM Installation 9 July 30, 2010 04:43
Problems of Duns Codes! Martin J Main CFD Forum 8 August 14, 2003 23:19


All times are GMT -4. The time now is 06:52.