|
[Sponsors] |
Volume weighted average species mass fraction |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
May 25, 2020, 22:57 |
Volume weighted average species mass fraction
|
#1 |
Member
Join Date: Oct 2019
Posts: 35
Rep Power: 7 |
Hey guys,
I have been unable to find the right syntax to use in calculating the volume-weighted average species mass fraction as tavg is used in the calculation of the volume-weighted average of temperature. Using s0 gives a compiling error C2086: 'real S0avg' redefinition. Calculation of volume-weighted average of temperature is as the code. Thank you, much appreciated. Last edited by Morice; May 31, 2020 at 23:19. Reason: Improper Code and used in a wrong number |
|
May 26, 2020, 06:31 |
Volume Averaged Species
|
#2 |
Senior Member
|
The code that you attached is improper and used in wrong manner. DEFINE_PROFILE is hooked to a zone, therefore, Domain is not required. It always returns the Thread of the zone it is hooked to. So, no need to compare against anything. However, it is supposed to assign the values to the zone, which is not being done in the code. In a way, the code is serving its purpose.
So, if the objective is to determine volume averaged temperature for a zone, DEFINE_ADJUST or DEFINE_EXECUTE_AT_END makes more sense. For species, you have to use C_YI instead of C_T.
__________________
Regards, Vinerm PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority. |
|
May 26, 2020, 21:23 |
Volume Averaged Species
|
#3 | |
Member
Join Date: Oct 2019
Posts: 35
Rep Power: 7 |
Quote:
|
||
May 27, 2020, 04:58 |
UDF Issue
|
#4 |
Senior Member
|
Then, what is the current issue? Does the UDF not compile or does it give run-time error?
__________________
Regards, Vinerm PM to be used if and only if you do not want something to be shared publicly. PM is considered to be of the least priority. |
|
May 28, 2020, 11:28 |
UDF Compiled and the simulation ran
|
#5 | |
Member
Join Date: Oct 2019
Posts: 35
Rep Power: 7 |
Quote:
Thank you for your assistance, much appreciated. |
||
Tags |
species mass fraction |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Mass fraction of species (Y) in reacting solvers | mike.franky | OpenFOAM Running, Solving & CFD | 9 | February 9, 2023 07:49 |
mass fraction of species | Lilly | FLUENT | 5 | March 13, 2022 18:52 |
alphaEqn.H in twoPhaseEulerFoam | cheng1988sjtu | OpenFOAM Bugs | 15 | May 1, 2016 17:12 |
Difference between Volume Fraction and Mass Fraction in CEL | foo7 | CFX | 0 | September 21, 2011 09:45 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 12:55 |