|
[Sponsors] |
September 14, 2009, 15:15 |
Mean Age of Air
|
#1 |
New Member
Francois M Joubert
Join Date: Sep 2009
Posts: 1
Rep Power: 0 |
Hi all,
I am a new member and may be asking an old, already answered question. If so I apologise. I notice that quite some time ago (~2007) Vincent enquired about determining mean age of air predictions with OpenFOAM but I could not find any response to that. It seems that relatively simple techniques exist to do this post-processing with many commercial CFD software packages. My requirement is to use Mean Age of Air data to measure Air Change Effectiveness in buildings according to the ASHRAE 129-1977 std. Your help will be appreciated! Thanks in advance, Francois |
|
March 15, 2010, 09:42 |
|
#2 |
Member
Join Date: Mar 2010
Posts: 42
Rep Power: 16 |
I have almost the same problem, I want to output a custom variable "maa" (mean age air) to measure Air Change Effectiveness. I have the function from articles, i just want to see this variable on paraview. Should i create a new solver? I just need the velocity fields like scalarTransportFoam, so modifying this solver will be enough? If yes what file contains the function from scalarTransportFoam to modify?
thanks for the patience reading =) |
|
March 16, 2010, 06:00 |
|
#3 |
Senior Member
matej forman
Join Date: Mar 2009
Location: Brno, Czech Republic
Posts: 182
Rep Power: 17 |
Hi,
as far as I remember, the mean age of air is a scalar with a density as a source term. scalarTransportFoam is a good choice. Just be aware it is written for incompressible flow with no density variation. You have to do few small changes to work with your solution which I assume is not isothermal. Other possibility would be to add your maa scalar to your solver of course. good luck matej |
|
March 18, 2010, 23:56 |
|
#4 |
Member
Andrew King
Join Date: Mar 2009
Location: Perth, Western Australia, Australia
Posts: 82
Rep Power: 17 |
I have attached a solver that can do this.
To get air change effectiveness, you'll have to do some postprocessing on the age field. (which could probably be moved into the solver). It can use an existing flow field, or solve it as part of the calculation. Also it's written to live with the main OF solvers, you may want to change Make/files to use FOAM_USER_APPBIN for stand-alone use. Feedback welcome. (Attribution appreciated as well - since that is what they measured by the powers that be) Regards, Andrew
__________________
Dr Andrew King Fluid Dynamics Research Group Curtin University |
|
March 19, 2010, 04:24 |
|
#5 |
Member
Join Date: Mar 2010
Posts: 42
Rep Power: 16 |
Thanks matejf and Andrew!
I will test the solver now and will post the results. Thanks for the attention, Guilherme |
|
March 22, 2010, 08:17 |
|
#6 |
Member
Join Date: Mar 2010
Posts: 42
Rep Power: 16 |
uuuuuuuuuu
Last edited by lindner; March 22, 2010 at 08:20. Reason: delete |
|
March 22, 2010, 08:18 |
|
#7 |
Member
Join Date: Mar 2010
Posts: 42
Rep Power: 16 |
Hi andersking,
The solver worked and i got results close to the literature, thank you! But i have a question, the equation you are using to calculate the age is the same as the one from this article or is it another one? www.ibpsa.org/proceedings/BS2001/BS01_0773_780.pdf And another question (my lack of programming knowledge), the sentence in the scalar part of the code dimensionedScalar("ageSource", age.dimensions()*dimensionSet(0,0,-1,0,0), 1) means what? I did a test changing to the value 1 and it gave the same result. Thanks for the help, Guilherme |
|
March 22, 2010, 21:30 |
|
#8 |
Member
Andrew King
Join Date: Mar 2009
Location: Perth, Western Australia, Australia
Posts: 82
Rep Power: 17 |
It is essentially the same as that equation. (Assuming a schmidt no of 1 - this should probably be changeable though).
the Code:
dimensionedScalar("ageSource", age.dimensions()*dimensionSet(0,0,-1,0,0), 1) Regards, Andrew
__________________
Dr Andrew King Fluid Dynamics Research Group Curtin University |
|
March 23, 2010, 04:26 |
|
#9 |
Member
Join Date: Mar 2010
Posts: 42
Rep Power: 16 |
Ok, now I understand. Im studying the code to be able to create my own solvers later on.
Thanks for everything, the Local Mean Age problem is solved. Guilherme |
|
March 23, 2010, 14:09 |
|
#10 |
Senior Member
Fabian Braennstroem
Join Date: Mar 2009
Posts: 407
Rep Power: 19 |
Hello,
maybe, this is another option or add-on: http://sourceforge.net/projects/openfoamadd-ons/ Fabian |
|
November 30, 2011, 14:55 |
|
#11 | |
New Member
Ramy hamdy
Join Date: May 2011
Posts: 5
Rep Power: 15 |
Quote:
|
||
May 14, 2012, 14:19 |
|
#12 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
hi to all,
there is a discussion in our office of the mean time of a fluid in two geometrys. So i just wanna analyse what mean time is bigger. Therefor I implemented a new scalar in my solver Code:
solve ( fvm::ddt(S) + fvm::div(phi, S) - laplacian(nuEff, S) ) I read your repost for the last line but i do not understand it! Tobi |
|
June 26, 2012, 06:40 |
|
#13 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hi its me again,
my solver can`t handle the Code:
laplacian(nuEff(),age) Code:
laplacian(turbulent->mut()/sigmat,age) Can someone give me an advice? Tobi |
|
July 2, 2012, 09:41 |
|
#14 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Well okay that`s wrong i think couse
Code:
nuEff = nu + nut Code:
nu = mu * rho Code:
laplacian(turbulence->mut()*rho+mu*rho,age) maybe its just "DnuTildaEff" ??? Tobi |
|
July 2, 2012, 10:13 |
|
#15 | |
Member
Andrew King
Join Date: Mar 2009
Location: Perth, Western Australia, Australia
Posts: 82
Rep Power: 17 |
Quote:
If you are using a solver with density (which is likely if you have mu available), then you probably should be using turbulence->muEff(), which is the effective viscosity. also , nu = mu / rho. The source term of "1", grows with time, so for stagnant areas age = t, whereas for areas with "fresh" fluid inlet, age = 0 (which should be the boundary conditions on inlet). (you can normalise it versus t to get values from 0 to 1). Regards, Andrew
__________________
Dr Andrew King Fluid Dynamics Research Group Curtin University |
||
July 3, 2012, 05:22 |
|
#16 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hi andrew,
thanks for your replay! Well is mu = dynamic viscosity, nu = kinematic viskosity, or? There was a problem in my head with the litrature. Okay. Now its clear. But I have problems in my calculations with the dimensions Code:
incompatible dimensions for operation [age[0 0 -2 0 0 0 0] ] + [age[1 -3 -2 0 0 0 0] ] Code:
fvScalarMatrix ageEqn ( fvm::ddt(age) + fvm::div(phi, age) - fvm::laplacian(turbulence->muEff(), age) == dimensionedScalar("ageSource", age.dimensions()*dimensionSet(0,0,-1,0,0), 1) ); |
|
July 3, 2012, 05:36 |
|
#17 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hi again,
I made a mistake Now I changed the code for the ddt() and the source... 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) ); |
|
July 19, 2012, 04:40 |
|
#18 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hi again,
is there a way to validate the solved age time? I am not sure about my results. Using combustion and in the flame zone I have age values to 5 (like 5s) and that should be something like 0.3 sec ... did I do sth. wrong? |
|
July 20, 2012, 12:14 |
|
#19 |
Member
Tibor Nyers
Join Date: Jul 2010
Location: Hungary
Posts: 91
Rep Power: 17 |
Hi Tobias,
I got the same result. I compared the method that you used with a new solution to calculate the residence time with field sources (OF2.1). If anyone interested, I attached the solver and a pitzDaily demo. I have used it successfully before, but I tried to recompile it this morning and it failed ... Any ideas are appreciated! |
|
July 20, 2012, 16:25 |
|
#20 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Hey Tibor,
I changed some lines in your solver and now it works again Is there a reason why you set DT - its zero or not ? Hmmm ... I ll try it with the simpleFoam again and compare it. At least a question. If I analyse a flow structure with a long inlet (time = 0) and get to a diffusor. How can I get the time which the fluid need to flow through the diffusor when the fluid needs 5 seconds to get to the diffusor!? Do you know what I mean? Tobi |
|
|
|
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 |