|
[Sponsors] |
March 24, 2018, 15:04 |
Writing reaction.R in reactingFoam
|
#1 |
Senior Member
Lasse Brams Vinther
Join Date: Oct 2015
Posts: 118
Rep Power: 11 |
Hello Foamers,
I am trying to make a chemical reactor solver, with both catalyst temperature and the thermal properties of the reacting fluid. The issue is with the reaction.R(Yi) in YiEqn, as its solved as a function of the fluid temperature, however, it should be based upon the catalyst temperature and I'm unable to alter the reaction.R in the solver. Therefore, I'm trying to define a new fvMatrix based upon the reaction.R(Yi) which I then may alter to depend on catalyst temperature and remove its dependence on the reacting fluid temperature. I tried to do this be adding the following code to the following directories. Createfields: Code:
PtrList<fvScalarMatrix> RrateReactor(reactorRegions.size()); Info<< " Adding to RrateReactor\n" << endl; RrateReactor.set ( i, new fvScalarMatrix ( IOobject ( "Rrate", runTime.timeName(), reactorRegions[i], IOobject::NO_READ, IOobject::AUTO_WRITE ), reactorRegions[i], fvMatrix<>("Rrate", dimEnergy/dimVolume/dimTime,0) ) ); Code:
fvMatrix& Rrate = reaction.R(Y[i]); Code:
fvScalarMatrix& Rrate=RrateReactor[i]; Here is a link to the solver which I'm trying to add the above in the reactor domain for OpenFOAM v4: https://www.dropbox.com/s/affha5r5ht...am.tar.gz?dl=0 Regards Lasse. |
|
October 20, 2018, 06:16 |
|
#2 |
New Member
Faezeh
Join Date: Oct 2011
Posts: 6
Rep Power: 15 |
||
October 22, 2018, 16:11 |
reactingRateFoam
|
#3 |
Senior Member
Lasse Brams Vinther
Join Date: Oct 2015
Posts: 118
Rep Power: 11 |
Hi Faezeh,
Thank you for the link that helped a lot I have attached a reactingRateFoam solver to this post for others to look at (for ofv6). https://www.dropbox.com/s/6si5ecxjzm...am.tar.xz?dl=0 Going to implement it in a multi region solver as well. |
|
Tags |
reaction rate, temperature dependence |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[Other] Contribution a new utility: refine wall layer mesh based on yPlus field | lakeat | OpenFOAM Community Contributions | 58 | December 23, 2021 03:36 |
[Other] refineWallLayer Error | Yuby | OpenFOAM Meshing & Mesh Conversion | 2 | November 11, 2021 12:04 |
decomposePar problem: Cell 0contains face labels out of range | vaina74 | OpenFOAM Pre-Processing | 37 | July 20, 2020 06:38 |
[mesh manipulation] Importing Multiple Meshes | thomasnwalshiii | OpenFOAM Meshing & Mesh Conversion | 18 | December 19, 2015 19:57 |
[snappyHexMesh] crash sHM | H25E | OpenFOAM Meshing & Mesh Conversion | 11 | November 10, 2014 12:27 |