|
[Sponsors] |
June 13, 2017, 09:41 |
Alpha
|
#521 |
New Member
Join Date: Jan 2016
Posts: 5
Rep Power: 10 |
Hi Tobi,
I have a question about the implementation of alpha (thermal conductivity) in the solver. The general units of alpha in OpenFOAM are [kg/m/s], whereas in your solver they are [m²/s], which is a factor rho different (favre averaging). However, as far as I can see, in the pdfFlameletThermo.C file, you overwrite the alpha_ field from heThermo [kg/m/s] with the lookup alpha_favre [m²/s]. Relevant lines: pdfFlameletThermo.C Code:
const scalarField& alphaFavre = this->alpha_favre_.internalField(); scalarField& alphaCells = this->alpha_.internalField(); alphaCells[celli] = alphaFavre[celli]; const fvPatchScalarField& palphaFavre = this->alpha_favre_.boundaryField()[patchi]; fvPatchScalarField& palpha = this->alpha_.boundaryField()[patchi]; palpha[facei] = palphaFavre[facei]; Code:
// alpha for(j=1;j<=_n_variance;j++) for(i=1;i<=_n_csi;i++) _alpha_f[j][i] = _lambda_f[j][i]/_density_r[j][i]/_cp_f[j][i]; In my application I use alpha and kappa values for heat transfer through walls, which should make it easier to change the final overwriting of alpha to [kg/m/s] to make it compatible with the other calculations of heThermo and the turbulence models. However, I think it is strange OpenFOAM is able to overwrite the alpha_ with the alpha_favre without checking the dimensions. So finally my questions are: Is the alpha used for something other than reporting? In the solver you use muEff()/sigmat, resulting in the absence of alphaEff as generally applied in most solvers. And a question related to this muEff()/sigmat implementation: why do you use muEff()/sigmat = (mu+mut)/sigmat and not mu/sigma+mut/sigmat, which is mostly used (being alphaEff in RANS turbulence models) ? Is is because you assume mu_eff =~ mu_turbulent like you said on page 7? I would assume if you overwrite alpha_ with (which I assume are) the right units, you could just use alphaEff? |
|
March 3, 2019, 22:53 |
The result shows that psi*p is not equal to rho?
|
#522 | |
Senior Member
Ruiyan Chen
Join Date: Jul 2016
Location: Hangzhou, China
Posts: 162
Rep Power: 10 |
Quote:
I do have one question, although I'm not sure if it's related to the libOpenSMOKE solver or OpenFOAM. I tried the Sandia_COH2N2 tutorial case that comes with the solver, everything seems to be fine. (I'm using OpenFOAM-4.x btw, and this is the only tutorial case provided) Since I'm interested in learning some programming in OpenFOAM, I changed the NO_WRITE option to AUTO_WRITE for both psi_ and mu_ in the flameletThermo class constructor. The code is in thermophysicalModels/basic/flameletThermo/flameletThermo.C line 37 to 70. So basically I want psi_ and mu_ to be printed out, and their names are "thermosi" and "thermo:mu" (these names come from OpenFOAM. I don't understand why they can't just be "psi" and "mu", like other variable names). Then I recompiled the flameletThermo class, and did the tutorial case. I also set the propertyUpdate label in constant/flameletsProperties to 1, so thermophysical properties should be updated in every iteration. In the result, now "thermosi" and "thermo:mu" are printed out (as expected). However, it seems like rho is not equal to thermosi times the pressure. Please see the attached figure, where I plot (thermosi*p-rho)/rho. As you can see, the difference is actually quite large! For the most part the difference is almost 0 (red contour in my figure), but there's no flame there. In the flame region the difference between psi*p and rho is very large, as large as 60% of the density. This seems very strange, because in the pdfFlameletThermo class it is specified, as Tobi mentioned, rho should be equal to psi*p, for internal cells and for boundary patches. At first I thought this may be caused by the fact that thermo.correct() is called before pressure is solved (in HEqn.H) and rho = thermo.rho() is called after the pressure is solved (pEqn.H). So I tried to change where I put the thermo.correct() and rho = thermo.rho(). for example, I tried to put them in this order: UEqn.H, ZEqn.H, HEqn.H (without thermo.correct(), pEqn.H(without rho = thermo.rho()), turbulence->correct(), then thermo.correct(), then rho = thermo.rho()). But I always get something like what's in the figure, i.e., rho is not equal to thermosi * p. I feel like I'm missing some important points here but can't figure out what it is. Any ideas is welcome! Ruiyan |
||
March 16, 2019, 03:29 |
|
#523 |
Senior Member
Ruiyan Chen
Join Date: Jul 2016
Location: Hangzhou, China
Posts: 162
Rep Power: 10 |
Dear Yashar,
I noticed it has been a few years since you posted your comparison between the numerical and experimental results. I'm encountering the exact same problem as yours (that the flame lengths are quite different), have you resolved your problem? Also, you mentioned that turning to another version helps, can you talk more about it? Thanks, Ruiyan |
|
August 21, 2019, 00:13 |
Setting Mixture fraction at Inlet that is neither fuel nor oxidiser
|
#524 |
New Member
Thalhah
Join Date: May 2016
Posts: 15
Rep Power: 10 |
Hi all,
I am using flameletSimpleFoam to simulate a diffusion flame from a cylindrical burner that has three inlets/gas streams. 1) Fuel (methane) flow from the centre tube of the burner 2) Oxidiser (air) flow from the outer tube 3) Pure nitrogen gas flow from the outermost tube In the 0/ folder, there is the mixture fraction Z boundary condition that needs to be specified. I know that for the fuel and oxidiser inlet, the values of Z are 1 and 0 respectively. However, what value do I set for the nitrogen gas stream? Should I just specify zeroGradient? Any help is appreciated. Best regards, Thalhah |
|
August 21, 2019, 10:41 |
|
#525 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Dear Thalahl,
it is not possible to define a pure nitrogen inlet while using the flamelet library. As you already know, Z = 1 is equal to pure fuel, Z = 0 is equal to pure air/oxigen or whatever mixture you specified. If an inlet is 100 % Nitrogen, you cannot specify that as it is not specified within your flamelet tables. So far, without changing the library, you cannot simulate your specific problem. Kind regards, Tobi
__________________
Keep foaming, Tobias Holzmann |
|
October 21, 2019, 11:18 |
|
#526 | |
New Member
Bah.Mah
Join Date: Jun 2016
Posts: 18
Rep Power: 10 |
Quote:
Would you please tell me how did you calculate the mole fraction from mass fraction in Paraview? And another question please ? Did you build a new function helping on converting mass fraction to mole fraction? I know that the post above is 9 years old now but I would appreciate your help a lot. thanks |
||
October 21, 2019, 14:09 |
|
#528 |
New Member
Bah.Mah
Join Date: Jun 2016
Posts: 18
Rep Power: 10 |
||
October 21, 2019, 16:18 |
|
#529 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Sure, you can calculate the mole fraction out of the mass fraction. You should be aware of the formulation. So you can use the calculator to do that.
__________________
Keep foaming, Tobias Holzmann |
|
January 27, 2020, 15:53 |
|
#530 |
Senior Member
Freedom
Join Date: May 2014
Posts: 209
Rep Power: 13 |
Is there anyone here using libOpenSMOKE to predict soot formation?
|
|
January 28, 2020, 04:17 |
|
#532 |
Senior Member
Freedom
Join Date: May 2014
Posts: 209
Rep Power: 13 |
Please give me a shout if you (anyone in this thread) are also using LibOpenSMOKE to predict soot. We can have further discussions.
|
|
February 3, 2020, 10:55 |
About scalar dissipation rates ...
|
#533 |
New Member
Join Date: Nov 2019
Posts: 3
Rep Power: 7 |
Greetings,
how do I choose the scalar dissipation rates for my flamelet library? If I understand it correctly, I have to create flamelets corresponding to scalar dissipation rates ranging from zero to extinction to create an accurate representation of the flame. The wikipage for Hagen Müller's flameletFoam ist the most thorough explanation I found but it describes the process using Cantera. What I took from there is the insight that the process seems to be of iterative nature. I presume there is no way to calculate the quenching scalar dissipation rate directly, is there? So how do I create a fitting library with flameletSimpleFoam? Any insights would be highly appreciated. Best regards, azu037 Edit: In the end I used a range of scalar dissipation rates loosely based on the rates in the tutorial. It works but I don't know if this is a sensible way of doing it ... I also have another question: has anyone used the flameletSimpleFoam solver in conjunction with cyclicAMI boundaries? My goal is to simulate only a quarter of my geometry but with this setup the mixture fraction Z takes on values larger than 1; this wasn't a problem with the full geometry. On a side note: the divergence scheme limitedLimitedLinear 1 0 1 shouldn't allow such values or am I mistaken? I'm also unsure about the order of the values; is limitedLimitedLinear 1 0 1 or limitedLimitedLinear 0 1 1 correct if I want to limit the value between 0 and 1 with the limiter set to 100 percent? I already tried confining the two cyclicAMI boundaries on one CPU core with the singleProcessorFaceSets option but this didn't fix the problem. Any hint would be appreciated! Another edit: After investigating the problem more thoroughly using Paraview's Threshold filter I noticed that only a few cells have values for Z and Zvar larger than the specified bounds. These cells are located in a highly problematic area of the mesh. I am going to remesh my geometry with altered settings and see if the problem persists. I'll report back. Last edited by azu037; February 27, 2020 at 10:43. |
|
April 19, 2020, 16:06 |
Simulation of Ethylene diffusion flame
|
#534 |
New Member
Thalhah
Join Date: May 2016
Posts: 15
Rep Power: 10 |
I am trying to simulate an ethylene C2H4 diffusion flame using flameletSimpleFOAM. The given tutorial for this solver uses methane as fuel. I simply replaced methane fuel with C2H4 in Data.inp file during flamelet generation stage. At post-processing stage, C2H4 contour shows no flow, though there exists CH4 flow. Can anybody suggest what could have been wrong? Files for Data.inp and resulting C2H4 and CH4 contours are attached.
Any help is much appreciated. Regards, Thalhah |
|
April 19, 2020, 16:13 |
|
#535 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
Did you create the flamelet? Just changing the Data.inp will not change anything regarding the cfd calculation.
__________________
Keep foaming, Tobias Holzmann |
|
April 19, 2020, 16:30 |
|
#536 | |
New Member
Thalhah
Join Date: May 2016
Posts: 15
Rep Power: 10 |
Quote:
Thanks for the prompt response. Yes, I have generated the flamelet. After changing the Data.inp, I ran the script for flamelet generation (runFlameletGeneration.sh), copied the PDF file to the case folder and ran the simulation. Please advise. Regards, Thalhah |
||
April 19, 2020, 18:20 |
|
#537 |
Super Moderator
Tobias Holzmann
Join Date: Oct 2010
Location: Bad Wörishofen
Posts: 2,711
Blog Entries: 6
Rep Power: 52 |
You should get txt files during the flamelet generation. Please check if you do have your fuel there too. Please share the Data.inp file.
__________________
Keep foaming, Tobias Holzmann |
|
April 20, 2020, 04:49 |
|
#538 | |
New Member
Thalhah
Join Date: May 2016
Posts: 15
Rep Power: 10 |
Quote:
Please find attached Data.inp file. The log file from the flamelet generation shows the fuel is C2H4-also attached, should it be of any help. Thank you. Regards, Thalhah |
||
April 25, 2020, 05:29 |
|
#540 |
New Member
Thalhah
Join Date: May 2016
Posts: 15
Rep Power: 10 |
After reading this thread from the early years, I realized that H in 0/ folder should be specified based on the following; run flamelet generation, abort, obtain H values for fuel and oxidiser from the log file, and insert in 0/H. Seems like after doing that, there appears to be some flow of C2H4 in the domain (fig. attached). Anyhow, I think because the fuel flow rate in my case is very low (U_fuel=0.002m/s), the C2H4 flow does not go too further downstream. (I did tested using higher flow rates of 1-2 order magnitude higher (fig. attached) and C2H4 can be clearly seen flowing downstream).
Thank you Tobi for inputs. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Numerical treatment of the source term in combustion equations | Tobi | Main CFD Forum | 37 | September 15, 2020 14:42 |
[openSmoke] flameletSmoke + new ODESolver (by Alberto Cuoci) | Tobi | OpenFOAM Community Contributions | 1 | November 21, 2017 19:24 |
Unsteady solver with Flamelet Model (libOpenSMOKE) | francesco_capuano | OpenFOAM Running, Solving & CFD | 11 | November 26, 2013 05:50 |
LibOpenSmoke, getting the species in ParaFoam | Christoph_84 | OpenFOAM | 1 | May 31, 2012 15:42 |