|
[Sponsors] |
July 15, 2010, 16:06 |
So back to my original question...
|
#21 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
Sounds like a lot of good discussion came from this thread, which I'm glad about.
However, I'm still needing to calculate the reaction rates without solving the ODE. Any hints? Pretty please? |
|
July 15, 2010, 16:14 |
|
#22 |
Senior Member
Hassan Kassem
Join Date: May 2010
Location: Germany
Posts: 242
Rep Power: 18 |
Which model do you want to use to calculate the reaction rates?
|
|
July 15, 2010, 19:08 |
|
#23 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
I'm using chemistry:
psiChemistryModel ODEChemistryModel<gasThermoPhysics>; and thermo: thermoType hPsiMixtureThermo<reactingMixture<gasThermoPhysics >> I can access the chemistry.solve() function, which acts very much like chemistry.calculate (for ODE chemistry). I was temporarily using a really ugly fix by just replacing the contents of the solve() function with calculate(), and it works. But I have to remember to make changes when I use other solvers that require chemistry.solve(). I'm sure it has something to do with the way things are templatized, but I'm at a loss as to how to deal with it. Thanks for the help |
|
July 15, 2010, 19:33 |
|
#24 |
Senior Member
Hassan Kassem
Join Date: May 2010
Location: Germany
Posts: 242
Rep Power: 18 |
I find chemistry models and thermophysical very complicated specially I am trying to understand it myself. I attended openfoam foundation course but these models were not in the scope of the course.
I feel that everyone know something I totally missed. I hope someone will explain soon on wiki or here how these models work. I am implementing EDM model and it starts to work good but I still need to access the enthalpy of formation of each specie to calculate energy equation source term. Can anyone tell me what is the chemical enthalpy hc()? |
|
July 15, 2010, 20:26 |
|
#25 |
Senior Member
Marco A. Turcios
Join Date: Mar 2009
Location: Vancouver, BC, Canada
Posts: 740
Rep Power: 28 |
Ditto brother. I'm sure its just an inheritance thing. I was able to sort of gain access by ensuring that a pure virtual function existed for calculate (I think it was in the psiChemistry.H file), which allowed the scope to be resolved, but then complained that ther function wasn't implemented...
I guess I'll use the ugly hack for the time being... Last edited by mturcios777; July 15, 2010 at 20:27. Reason: Error in post |
|
August 19, 2010, 17:56 |
Diffusion problem.
|
#26 | |
Senior Member
Seyyed Ali H.M.
Join Date: Nov 2009
Location: Utah
Posts: 107
Rep Power: 17 |
Quote:
But I have another problem. In this hEqn code, there should be one more term that should compensate enthalpy diffusion due to mass diffusion. I openFoam 1.7 this problem is fixed, because h is hs (sensible enthalpy ) which doesn't need that term. Compare this to equation 1.75 in "Turbulence Combustion" book by Nurbert Peters. Actually I did one pure diffusion case, that proves reactingFoam in 1.6 has a problem.
__________________
SAHM |
||
August 19, 2010, 18:28 |
|
#27 | |
Senior Member
Hassan Kassem
Join Date: May 2010
Location: Germany
Posts: 242
Rep Power: 18 |
Quote:
I checked equation 1.75 in Peter's book, but I am not sure if alphaEff() conceder the mass diffusion or not. As I noticed the hs and h equations are identical except the source term. |
||
August 19, 2010, 18:40 |
Trying to figure them out.
|
#28 | |
Senior Member
Seyyed Ali H.M.
Join Date: Nov 2009
Location: Utah
Posts: 107
Rep Power: 17 |
Actually I was trying to see if I could find how I can have access to Hc like other people. Since I want to use cantera in OpenFoam and that works with OF1.5 ( thanks to Markus Rheim) I had to change the code of reactingFoam to get rid of that problem. So I`m still trying to find out about different parts of this code.
Quote:
About AlphaEff, I don't know. That alphaEff has to do with turbulence, but my cases are mostly laminar, so I don't know if that works for turbulent properly or not, but in my cases its giving me errors. Also you should notice that this aplha is not temperature diffusivity, it is alpha*cp or k/rho. I have one more question about YEqn File, but that doesn't go with thread. If YEqn.H we have muEff which acts simmilar to this alphaEff, the code is: solve ( fvm::ddt(rho, Yi) + mvConvection->fvmDiv(phi, Yi) - fvm::laplacian(turbulence->muEff(), Yi) == kappa*chemistry.RR(i), mesh.solver("Yi") ); I don't know why it is muEff(), I mean it should be effective mass concentration coefficient D or DEff. Do you anything about this? I have some cases, If you would like to see, I can send them to you, just send me your email.
__________________
SAHM |
||
August 19, 2010, 18:50 |
|
#29 |
Senior Member
Hassan Kassem
Join Date: May 2010
Location: Germany
Posts: 242
Rep Power: 18 |
sure my email is hassan.kassem@gmail.com
http://jeacfm.cse.polyu.edu.hk/downl..._MarzoukOA.pdf I think this paper is useful. They used reactingFoam. you can check the governing equations. |
|
August 19, 2010, 19:07 |
|
#30 | |
New Member
Silvano
Join Date: Aug 2010
Location: Chicago /Torino Us/Italy
Posts: 11
Rep Power: 16 |
Quote:
can you please help me to understand what "thermo->correct()" do in hEqn.H ? thanks Silvano |
||
July 13, 2011, 03:16 |
|
#31 |
New Member
Join Date: Nov 2010
Posts: 17
Rep Power: 16 |
Hi
I am just starting to explore openfoam. I have a quick question in the following. autoPtr<basicThermo> pThermo I understand that in above line pThermo is an object of the template class autoptr. basicThermo& thermo = pThermo(); But I don't understand is that how the object pThermo is used as pThermo(). I understand that thermo is a reference variable of type basicThermo. Please explain the use of pThermo(). Regards |
|
April 6, 2012, 11:53 |
|
#32 |
New Member
Mostafa Moghaddami
Join Date: Oct 2009
Posts: 13
Rep Power: 17 |
Dear All
I am going to run a case includes some liquid species that react with each other. I am going to use the reactingFoam as a solver. All species have constant proprties and I want to use the following thermo type: thermoType hsPsiThermo<reactingMixture<constTransport<specieT hermo<eConstThermo<icoPolynomial>>>>>> but when I set it in the constat/thermophysicalProperties file and run the case, I get this error: ------------------------------------------------------------------------------------ --> FOAM FATAL ERROR: Inconsistent thermo package selected: hsPsiThermo<reactingMixture<constTransport<specieT hermo<eConstThermo<icoPolynomial>>>>>> Please select a thermo package based on gasThermoPhysics. Valid options include: 3 ( hsPsiMixtureThermo<singleStepReactingMixture<gasTh ermoPhysics>> hsPsiMixtureThermo<multiComponentMixture<gasThermo Physics>> hsPsiMixtureThermo<reactingMixture<gasThermoPhysic s>> ) From function autoPtr<hsCombustionThermo> hsCombustionThermo::NewType(const fvMesh&, const word&) in file combustionThermo/hsCombustionThermo/hsCombustionThermoNew.C at line 116. FOAM exiting ------------------------------------------------------------------------------------- What should I do to use the reactingFoam for constant propertie species? Thanks in advance for your help. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Equilibrium Reaction Rates/Gas Chemistry | Greg Perkins | FLUENT | 6 | January 6, 2017 03:59 |