|
[Sponsors] |
February 16, 2010, 04:16 |
error in calculating mole fractions
|
#1 |
New Member
Emanuele Leoni
Join Date: Apr 2009
Posts: 13
Rep Power: 17 |
Hi, I have a problem: I would like to change the radiation model in openfoam 1.5-dev using a species-weighted absorption coefficient (wggs) to compare my results with fluent and experimental data. The point is that in the equation of wggs I have the mole fraction and not the mass fraction. I tried in the simplest way, using the equation to change mass fraction in mole fraction trough the total molecular weight. I wrote a code like this:
Code:
volScalarField unosuMWtot ( IOobject ( "unosuMWtot", mesh_.time().timeName(), mesh_, IOobject::NO_READ, IOobject::NO_WRITE ), mesh_, dimensionedScalar("zero", dimensionSet(-1,0,0,0,1,0,0), 0.0) ); for (label i=0;i<Y.size();i++) { unosuMWtot=unosuMWtot+Y[i]/chemistry->specieThermo()[i].W(); } So, anyway can find me a way to solve the problem, or maybe there is a direct function of chemistry model or hcomustionthermo where i can find the mole fraction without calculate it? Thank you Bye Emanuele |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Problems in calculating the fluid traction on the current structure frame in 3D models | fw407 | OpenFOAM Running, Solving & CFD | 0 | August 6, 2008 12:04 |
Calculating time | thuy | FLUENT | 5 | April 10, 2008 04:23 |
Diffusion-coefficient based on mole fraction | Fady | FLUENT | 1 | November 11, 2006 09:00 |
How to update polyPatchbs localPoints | liu | OpenFOAM Running, Solving & CFD | 6 | December 30, 2005 17:27 |
Mole fractions from mass fractions? | Keith | Siemens | 5 | September 27, 2002 05:39 |