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

Mean Age of Air

Register Blogs Community New Posts Updated Threads Search

Like Tree24Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 25, 2013, 14:56
Default
  #41
Senior Member
 
immortality's Avatar
 
Ehsan
Join Date: Oct 2012
Location: Iran
Posts: 2,208
Rep Power: 27
immortality is on a distinguished road
i'm confused too!
then what is wrong in settings i have done?
Could you tell me to know?
__________________
Injustice Anywhere is a Threat for Justice Everywhere.Martin Luther King.
To Be or Not To Be,Thats the Question!
The Only Stupid Question Is the One that Goes Unasked.
immortality is offline   Reply With Quote

Old   April 25, 2013, 16:18
Default
  #42
Senior Member
 
immortality's Avatar
 
Ehsan
Join Date: Oct 2012
Location: Iran
Posts: 2,208
Rep Power: 27
immortality is on a distinguished road
I'm waiting and wondering what is wrong?
please help.I'm in a hurry.
__________________
Injustice Anywhere is a Threat for Justice Everywhere.Martin Luther King.
To Be or Not To Be,Thats the Question!
The Only Stupid Question Is the One that Goes Unasked.
immortality is offline   Reply With Quote

Old   April 26, 2013, 23:12
Default
  #43
Senior Member
 
immortality's Avatar
 
Ehsan
Join Date: Oct 2012
Location: Iran
Posts: 2,208
Rep Power: 27
immortality is on a distinguished road
is there any help?
__________________
Injustice Anywhere is a Threat for Justice Everywhere.Martin Luther King.
To Be or Not To Be,Thats the Question!
The Only Stupid Question Is the One that Goes Unasked.
immortality is offline   Reply With Quote

Old   April 28, 2013, 02:58
Default
  #44
Senior Member
 
immortality's Avatar
 
Ehsan
Join Date: Oct 2012
Location: Iran
Posts: 2,208
Rep Power: 27
immortality is on a distinguished road
its very important to me.
My case is unsteady and compressible.
Why scalar transport(gas) isn't between 0 and 1?
__________________
Injustice Anywhere is a Threat for Justice Everywhere.Martin Luther King.
To Be or Not To Be,Thats the Question!
The Only Stupid Question Is the One that Goes Unasked.
immortality is offline   Reply With Quote

Old   May 3, 2013, 17:05
Default
  #45
Senior Member
 
immortality's Avatar
 
Ehsan
Join Date: Oct 2012
Location: Iran
Posts: 2,208
Rep Power: 27
immortality is on a distinguished road
what do you mean by conserved equation?
how can make the scalar transport conservative?
__________________
Injustice Anywhere is a Threat for Justice Everywhere.Martin Luther King.
To Be or Not To Be,Thats the Question!
The Only Stupid Question Is the One that Goes Unasked.
immortality is offline   Reply With Quote

Old   January 28, 2014, 05:33
Default Age of Air
  #46
Senior Member
 
tian's Avatar
 
Tian
Join Date: Mar 2009
Location: Berlin, germany
Posts: 122
Rep Power: 17
tian is on a distinguished road
Dear all,

my question is about Duration. I whould like that OpenFOAM calculated Age of Air every time step but my equation only work for one duration = 1. So, it seems I do not really understand the function of Duration. Can somebody help me? Thank you

Code:
functions
(
	AoA
	{
		type scalarTransport;
		functionObjectLibs ( "libutilityFunctionObjects.dll" );
		
		resetOnStartUp true;
		autoSchemes true;

		fvOptions
		{
		
			AoA_Source
			{
				type            scalarExplicitSetValue;
				active          on;
				timeStart       0.0;
				duration        1000;
				selectionMode   all;
				
				scalarExplicitSetValueCoeffs
				{
					volumeMode        specific;
					injectionRate
					{
						AoA            1;
					}
				}
			}
		};
		
	}
	
	AoA_MinMax
    {

        type            fieldMinMax;
        functionObjectLibs ("libfieldFunctionObjects.so");
        enabled         true;
        log             true;
        write           false;

        fields
        (
            AoA
        );
    }

);
__________________
BIM HVACTool, The Green Building Simulation Tool for OpenFOAM, Energy Plus and Radiance.
tian is offline   Reply With Quote

Old   September 14, 2015, 22:57
Default
  #47
New Member
 
Dasein
Join Date: Mar 2015
Posts: 21
Rep Power: 11
Tellur is on a distinguished road
Hello everyone,

Sorry for reviving this old thread.

I want to perform some ACE simulations and this post has been the closest I have found of something like this in Openfoam.

However, I have some issues trying to compile this solver for OpenFoam 2.4. At first I had some issues concerning IOliboptions file which in the new version seems to be substituted by MRF options and porosityoptions.

After changing that in ageScalarFoam.C I now get some errors in the reference of sources in the p, h, q, files. I believe the issue is that the CreateFields.H dictionary has a line including IOliboptions sources (mesh); at the end. I am not so sure what to substitute it with in order for the solver to compile.

Anyone has any pointers? Or perhaps a running version of the solver for 2.4?

Thanks so much in advance!

Kind regards,
Theodore.
Tellur is offline   Reply With Quote

Old   September 15, 2015, 06:17
Default
  #48
Senior Member
 
tian's Avatar
 
Tian
Join Date: Mar 2009
Location: Berlin, germany
Posts: 122
Rep Power: 17
tian is on a distinguished road
Hi,

if you need AoA in your CFD run, I think, you can add a function in your controlDict. No need to adjust the solver:

Code:
functions
{
       AoA
    {
        type    scalarTransport;
        functionObjectLibs ("libutilityFunctionObjects.dll");
        outputControl outputTime;
        active          true;
        autoSchemes     true;
        nCorr           0;
        resetOnStartUp false;
        //DT              1e-5;

        fvOptions
        {
            IncrementTime
            {
            type            scalarSemiImplicitSource;
            active          true;
            selectionMode   all;//cellZone;
            cellZone        Layers;
                scalarSemiImplicitSourceCoeffs
                {
                    volumeMode  specific;//absolute;
                    injectionRateSuSp
                    {
                        AoA       (1 0);
                    }
                }
            }
        }
    }


	MinMax
  {
        type            fieldMinMax;
        functionObjectLibs ("libfieldFunctionObjects.dll");
        enabled         true;
        log             true;
        write           false;
        fields
        (
	    p
            U
            T
            AoA
            
                    );
    }
  
}
Bye
Thomas
Mojtaba.a likes this.
__________________
BIM HVACTool, The Green Building Simulation Tool for OpenFOAM, Energy Plus and Radiance.
tian is offline   Reply With Quote

Old   September 21, 2015, 02:50
Default
  #49
New Member
 
Dasein
Join Date: Mar 2015
Posts: 21
Rep Power: 11
Tellur is on a distinguished road
Hi Tian,

Thank you so much for the information, I will try the code and see what I get.

Just a small clarification, if I want to calculate it in the breathing zone, would I have to indicate it in these lines? Or is it just a post-processing from my side to calculate it?

selectionMode ....
cellZone ....

Thanks in advance!
Tellur is offline   Reply With Quote

Old   September 21, 2015, 07:52
Default
  #50
New Member
 
Dasein
Join Date: Mar 2015
Posts: 21
Rep Power: 11
Tellur is on a distinguished road
Thanks it works!

Now I need to just play around with it and see what the output looks like and how I can transform this into ACE calculations.

Kind regards,
Theodore.
Tellur is offline   Reply With Quote

Old   September 21, 2015, 08:12
Default
  #51
Senior Member
 
tian's Avatar
 
Tian
Join Date: Mar 2009
Location: Berlin, germany
Posts: 122
Rep Power: 17
tian is on a distinguished road
Hi,

yeah, I used OpenFOAM under Windows. So you need to change:

functionObjectLibs ("libfieldFunctionObjects.dll");

to

functionObjectLibs ("libfieldFunctionObjects.so");

@breathing zone: You can use ParaView:

* Create your breathing zone as STL
* Use TopoSet to create your cellSet from your last time step.
* Use "foamToVTK -ASCII -cellSet ****" to create VTK
* Import your VTK

Bye
Thomas
__________________
BIM HVACTool, The Green Building Simulation Tool for OpenFOAM, Energy Plus and Radiance.
tian is offline   Reply With Quote

Old   October 1, 2015, 22:54
Default
  #52
New Member
 
Dasein
Join Date: Mar 2015
Posts: 21
Rep Power: 11
Tellur is on a distinguished road
Hello Thomas and forum,

I have been testing with success your code, thank you so much for providing it.

I was wondering if I can ask a couple of clarifications.

The first one is probably a silly question but bare with me. Can we actually use this code on a steady-state simulation? I understand it is using the time to calculate results, does this mean that the calculated AoA will just keep increasing at every timestep of a steadystate simulation or will it be an accurate number?

The second is concerning the calculation of Air Change Effectiveness (ACE) from Age of Air. I have found a few different formulas. I have settled down on dividing the nominal time constant to the AoA to calculate ACE. The nominal time constant seems to be the inverse of the ACH of the room. Is that a proper way to calculate ACE or do you have a different suggestion from your experience?

Again thank you so much for helping!

Kind regards,
Theodore.
Tellur is offline   Reply With Quote

Old   October 3, 2015, 07:01
Default
  #53
Senior Member
 
tian's Avatar
 
Tian
Join Date: Mar 2009
Location: Berlin, germany
Posts: 122
Rep Power: 17
tian is on a distinguished road
Hi,

@steady-state simulation: Yes, possible. In the end you will get your Room mean age of air as accurate number.

@Air Change Efficiency:

Epsilon = Mean Age of air in the exhaust / (2 x Room mean age of air)

Should be between 0 to 100%

Bye
Thomas
__________________
BIM HVACTool, The Green Building Simulation Tool for OpenFOAM, Energy Plus and Radiance.
tian is offline   Reply With Quote

Old   November 30, 2015, 19:30
Default
  #54
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by tian View Post
Hi,

@steady-state simulation: Yes, possible. In the end you will get your Room mean age of air as accurate number.

@Air Change Efficiency:

Epsilon = Mean Age of air in the exhaust / (2 x Room mean age of air)

Should be between 0 to 100%

Bye
Thomas
Hi Thomas, I see you are quite experienced in AoA.

I was wondering if you could suggest an approach for a naturally ventilated rooml especially as I am also modelling the external airflow too. I'm guessing it's not quite the same right to find the air change rate or air change effectiveness as in a mechanically ventilated room? What do you think?

Any help would be much appreciated.
kingjewel1 is offline   Reply With Quote

Old   December 1, 2015, 04:29
Default
  #55
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Dear kingjewel1,

i suggest you to use a simple passive scalar equation that has a source term that grow with time by 1. Thats it. After that you are able to Calculate the time the air is staying at a special location. It does not matter if you have naturally or mechanical ventilation. The mathematic behind are the same.

Good luck,
__________________
Keep foaming,
Tobias Holzmann
Tobi is offline   Reply With Quote

Old   December 1, 2015, 06:03
Default
  #56
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Tobi View Post
Dear kingjewel1,

i suggest you to use a simple passive scalar equation that has a source term that grow with time by 1. Thats it. After that you are able to Calculate the time the air is staying at a special location. It does not matter if you have naturally or mechanical ventilation. The mathematic behind are the same.

Good luck,
Hi Tobi,

Many thanks for your help. OK, so I've set this up and have results for a test case.By the way I think we met in Leeds at the OF users conference if I am not mistaken.

http://1drv.ms/1lVcZSZ

So to convert these contours into air changes per hour? 1/Age of Air? I'm not quite convinced.... What do you think?
kingjewel1 is offline   Reply With Quote

Old   December 1, 2015, 08:18
Default
  #57
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi,

did you mean the PFAU11 last week in Leoben? If yes, I was there. But not in Leeds or whatever it is (:

What is Tracer in the Plot? The additional variable with the suggested equation? This is at least the mean time of air in s. If you want to know how long the air will stay at a region within hours, just divide by 3600.
__________________
Keep foaming,
Tobias Holzmann
Tobi is offline   Reply With Quote

Old   December 1, 2015, 14:21
Default
  #58
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Quote:
Originally Posted by Tobi View Post
Hi,

did you mean the PFAU11 last week in Leoben? If yes, I was there. But not in Leeds or whatever it is (:

What is Tracer in the Plot? The additional variable with the suggested equation? This is at least the mean time of air in s. If you want to know how long the air will stay at a region within hours, just divide by 3600.
Hi Tobi,

Sorry, perhaps I was mistaken, I was sure you gave a talk on functions.

Anyway, yes the plot is the Age of Air based on the
Code:
scalarTransportFoam
run through
Code:
controlDict
with a source value of 1 in each cell. This seems to work nicely. But for calculating air change rate. Air change rate is then: Age of air/3600? Surely that would make the values very very small? Perhaps it's 3600/Age of Air?
kingjewel1 is offline   Reply With Quote

Old   December 1, 2015, 14:31
Default
  #59
Super Moderator
 
Tobi's Avatar
 
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52
Tobi has a spectacular aura aboutTobi has a spectacular aura aboutTobi has a spectacular aura about
Send a message via ICQ to Tobi Send a message via Skype™ to Tobi
Hi,

if you implement an equation like
Code:
fvScalarMatrix ageEqn        
(
             fvm::ddt(rho, age)
          + fvm::div(phi, age)
          - fvm::laplacian(turbulence->muEff(), age)
       ==
            dimensionedScalar("ageSource", age.dimensions()*dimensionSet(1,-3,-1,0,0), 1)         
);
you have to define the inlet with fixedValue = 0. Then the value of the scalar will increase within one second to the value 1. That means that everywhere you will have the value 1 after the calculation the air took 1s from inlet to that place. If you have regions with the value of 103 it means that the air stays in your domain for 103s.

Hope it is clear (:
__________________
Keep foaming,
Tobias Holzmann
Tobi is offline   Reply With Quote

Old   December 7, 2015, 08:06
Default
  #60
Senior Member
 
Join Date: Jul 2009
Posts: 260
Rep Power: 18
kingjewel1 is on a distinguished road
Hi Tobi,

This is working nicely now, thank you. Just a question about solving it. Imagine my building has a very high air change rate (200 times per hour), then my simulation will be very long (72 seconds at least). Which takes a long time on the server. Can I run the scalar on a frozen flow field to get a rough idea, if not exact?

Cheers,
kingjewel1 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
air bubble is disappear increasing time using vof xujjun CFX 9 June 9, 2009 08:59
local age of air in starccm+ Mike23 Siemens 3 September 20, 2008 12:16
[Indoor Air Quality]How do I calcauate "Age of Air Young CFX 6 April 29, 2008 00:14
age of air teddy Siemens 3 February 9, 2007 10:41
Age of Air In Star-CD Ted Crilly Siemens 1 February 19, 2005 20:50


All times are GMT -4. The time now is 03:46.