CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Cantera

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 7, 2013, 11:58
Default
  #101
TBO
Member
 
Join Date: May 2013
Location: Netherlands
Posts: 30
Rep Power: 13
TBO is on a distinguished road
Quote:
Originally Posted by gschaider View Post
Which SVN is not available? I tried the cantera-link and the two in section 2 ("Install ...") work too ... just not in the browser. Remove the svn:// and they will too

Thank you for the answer. Some people mention that is is also possible to modify the solver of later openfoam versions to run steady state chemistry. For me this is the preferred solution, since we are already running two different OpenFOAM versions (1.6 and 2.1.1), so we like to avoid using a third one. Can anyone tell me which steps are required to change reactingFoam into steadyreactingFoam (or even better, does anyone already have this solver).

I already had a quite extensive look on different fora, but I didn't find a clear answer yet ...
TBO is offline   Reply With Quote

Old   June 6, 2014, 07:53
Default reactingFoam to steadyState
  #102
Member
 
James
Join Date: Jul 2013
Posts: 38
Rep Power: 13
ni-openfoam-user is on a distinguished road
Hi,

Did you ever get an answer to your question: "Can anyone tell me which steps are required to change reactingFoam into steadyreactingFoam (or even better, does anyone already have this solver)?. "

I am also looking to run reactingFOAM in steady state. I am concerned at the moment with a high pressure release, I have switched off combustion and chemistry. What else do I need to modify to run in steady state.

Many thanks,

James
ni-openfoam-user is offline   Reply With Quote

Old   June 6, 2014, 11:50
Default
  #103
TBO
Member
 
Join Date: May 2013
Location: Netherlands
Posts: 30
Rep Power: 13
TBO is on a distinguished road
Dear James,

I never got a reply to this question, I did some tries with changing to pseudo-steady state solvers by changing the ddt schemes, however I was not succesfull with that (see also steady state combustion posts). Later I moved to the FGM based solver libOpenSmoke. This one works very well as steady state combustion solver.

Regards
TBO is offline   Reply With Quote

Old   March 18, 2015, 07:10
Default
  #104
Member
 
Join Date: Feb 2015
Posts: 31
Rep Power: 11
Stefano Puggelli is on a distinguished road
Hi TBO,
I am working on the FGM combustion modeling in OpenFOAM and I find the only one already available by Kroger. I am testing it and I having some problems with the flamelet generator based on Cantera.
You say that you moved to the FGM model based on the libOpenSmoke and I also had this idea, but is there an FGM model already available with libOpenSmoke (because I see that it can be used only for non premixed combustion with only the equations for mixture fraction) or did you build on your own?
Stefano Puggelli is offline   Reply With Quote

Old   March 18, 2015, 10:11
Default
  #105
TBO
Member
 
Join Date: May 2013
Location: Netherlands
Posts: 30
Rep Power: 13
TBO is on a distinguished road
Hi Stefano,
I used this model for non premixed combustion, so the libOpenSmoke based solver was suitable for my simulations. Maybe repost the question on the libOpenSmoke forum to see if someone else has experience with using this solver for premixed combustion.

Regards,
TBO
TBO is offline   Reply With Quote

Old   March 18, 2015, 10:36
Default
  #106
Member
 
Join Date: Feb 2015
Posts: 31
Rep Power: 11
Stefano Puggelli is on a distinguished road
Ok,
maybe I will ask on the libOpenSmoke forum.
Thank you,
Stefano
Stefano Puggelli is offline   Reply With Quote

Old   April 15, 2015, 12:51
Default
  #107
New Member
 
Ali Kadar
Join Date: Oct 2014
Location: Delft
Posts: 25
Rep Power: 12
flowAlways is on a distinguished road
Hello everyone,

has there been any new development on alternateSteadyReactingFoam which is now compatible only with old versions of OpenFOAM.
The transient solver reactingFoam is good but is not very appropriate considering the computational costs.
Is there any new development for a steady state combustion solver in OpenFOAM. ?

These are the related thread
http://www.cfd-online.com/Forums/ope...te-solver.html
http://www.cfd-online.com/Forums/ope...chemistry.html
https://github.com/Unofficial-Extend...rnateChemistry
__________________
A good solution is one which does justice to the inner nature of the problem- Cornelius Lanczos in a letter to Albert Einstein on March 9, 1947
flowAlways is offline   Reply With Quote

Old   April 16, 2015, 03:29
Default
  #108
TBO
Member
 
Join Date: May 2013
Location: Netherlands
Posts: 30
Rep Power: 13
TBO is on a distinguished road
Quote:
Originally Posted by flowAlways View Post
Is there any new development for a steady state combustion solver in OpenFOAM. ?
Hi Ali,

Yes, there are some developments. By default OpenFoam has now the solver LTSReactingFoam, which is a steady state version of reactingFoam (available in OF 2.3).

Besides that, also e.g. the solvers based on libOpenSmoke might be worth considering

Regards,
TBO
TBO is offline   Reply With Quote

Old   April 17, 2015, 03:47
Default
  #109
New Member
 
Ali Kadar
Join Date: Oct 2014
Location: Delft
Posts: 25
Rep Power: 12
flowAlways is on a distinguished road
Thank you for pointing that. I did test runs using the LTSreactingFoam, but unfortunately it fails(after 27 time iterations) with the following error(attached).
It runs perfectly ok with reactingFoam and I get good results.
I could not understand the parameters in the PIMPLE Algorithm too.
What are alphaTemp, rDeltaTSmoothingCoeff, rDeltaTDampingCoeff.
and why there is no relaxation ?

I think I will have to look at the code to understand what they are doing and what is the idea of local time stepping(LTS). I know that if you want to go fast in time you have to solve more pressure-velocity couplings per iteration i.e. nOuterCorrectors > 1 with under-relaxation(idea behind SIMPLE). But they are not doing that!!. Whats the idea behind LTS ?

Any ideas would be really helpful !!

Code:
PIMPLE
{
    momentumPredictor no;
    nOuterCorrectors  1;
    nCorrectors     1;
    nNonOrthogonalCorrectors 0;

    maxDeltaT       1e-2;
    maxCo           1;
    alphaTemp       0.05;
    rDeltaTSmoothingCoeff 1;
    rDeltaTDampingCoeff 1;
}

relaxationFactors
{
    fields
    {
    }
    equations
    {
        ".*" 1;
    }
}
Code:
Time = 26

Time scales min/max:
    Flow        = 1.28808e-05, 0.01
    Temperature = 6.78274e-06, 1e+300
    Overall     = 6.78274e-06, 0.01
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
DILUPBiCG:  Solving for O2, Initial residual = 0.075075, Final residual = 0.00549963, No Iterations 4
DILUPBiCG:  Solving for H2O, Initial residual = 0.963064, Final residual = 0.075786, No Iterations 3
DILUPBiCG:  Solving for CH4, Initial residual = 0.978202, Final residual = 0.0737773, No Iterations 3
DILUPBiCG:  Solving for CO2, Initial residual = 0.962777, Final residual = 0.0756163, No Iterations 3
DILUPBiCG:  Solving for h, Initial residual = 0.996642, Final residual = 0.0833314, No Iterations 2
min/max(T) = 297.502, 2074.17
DICPCG:  Solving for p, Initial residual = 0.846321, Final residual = 9.13219e-07, No Iterations 226
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
time step continuity errors : sum local = 1.14244e-05, global = -5.85091e-08, cumulative = 1.33362e-08
DILUPBiCG:  Solving for epsilon, Initial residual = 0.000435871, Final residual = 2.96746e-07, No Iterations 1
bounding epsilon, min: -45699 max: 4.85026e+08 average: 332153
DILUPBiCG:  Solving for k, Initial residual = 8.21421e-09, Final residual = 8.21421e-09, No Iterations 0
ExecutionTime = 32.79 s  ClockTime = 34 s

cellSource volumeTemperature output:
    average(sampledSurface) for T = 1285.89

faceSource faceTemperature output:
    average(outlet) for T = 1113.5

Time = 27

Time scales min/max:
    Flow        = 6.88187e-06, 0.01
    Temperature = -6.73481e+07, 1e+300
    Overall     = 6.88187e-06, 0.01
diagonal:  Solving for rho, Initial residual = 0, Final residual = 0, No Iterations 0
#0  Foam::error::printStack(Foam::Ostream&) in "/opt/openfoam230/platforms/linux64GccDPOpt/lib/libOpenFOAM.so"
#1  Foam::sigFpe::sigHandler(int) in "/opt/openfoam230/platforms/linux64GccDPOpt/lib/libOpenFOAM.so"
#2   in "/lib/x86_64-linux-gnu/libc.so.6"
#3  Foam::EulerImplicit<Foam::chemistryModel<Foam::psiChemistryModel, Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleEnthalpy> > > >::solve(Foam::Field<double>&, double&, double&, double&, double&) const in "/opt/openfoam230/platforms/linux64GccDPOpt/lib/libchemistryModel.so"
#4  double Foam::chemistryModel<Foam::psiChemistryModel, Foam::sutherlandTransport<Foam::species::thermo<Foam::janafThermo<Foam::perfectGas<Foam::specie> >, Foam::sensibleEnthalpy> > >::solve<Foam::Field<double> >(Foam::Field<double> const&) in "/opt/openfoam230/platforms/linux64GccDPOpt/lib/libchemistryModel.so"
#5  Foam::combustionModels::laminar<Foam::combustionModels::psiChemistryCombustion>::correct() in "/opt/openfoam230/platforms/linux64GccDPOpt/lib/libcombustionModels.so"
#6  Foam::combustionModels::PaSR<Foam::combustionModels::psiChemistryCombustion>::correct() in "/opt/openfoam230/platforms/linux64GccDPOpt/lib/libcombustionModels.so"
#7  
 at /home/opencfd/OpenFOAM/OpenFOAM-2.3.0/src/OpenFOAM/lnInclude/autoPtrI.H:174
#8  __libc_start_main in "/lib/x86_64-linux-gnu/libc.so.6"
#9  
 in "/opt/openfoam230/platforms/linux64GccDPOpt/bin/LTSReactingFoam"
Floating point exception (core dumped)
__________________
A good solution is one which does justice to the inner nature of the problem- Cornelius Lanczos in a letter to Albert Einstein on March 9, 1947
flowAlways is offline   Reply With Quote

Old   September 20, 2015, 16:13
Default
  #110
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings to all!

@Ali:
Quote:
Originally Posted by flowAlways View Post
What are alphaTemp, rDeltaTSmoothingCoeff, rDeltaTDampingCoeff.
and why there is no relaxation ?

I think I will have to look at the code to understand what they are doing and what is the idea of local time stepping(LTS). I know that if you want to go fast in time you have to solve more pressure-velocity couplings per iteration i.e. nOuterCorrectors > 1 with under-relaxation(idea behind SIMPLE). But they are not doing that!!. Whats the idea behind LTS ?
The original release of the LTS feature is described in the following pages:
"Relaxation" is mostly used with the SIMPLE loop, even when included in PIMPLE:


As far as I can understand (I am not an expert on this), the LTS modelling strategy uses an adaptive time step depending on the Courant Number in each cell (or small region of cells) and then uses a smoothing/damping strategy for making the flow compatible between regions that have different time steps. That's why the parameters "rDeltaTSmoothingCoeff, rDeltaTDampingCoeff" are needed, so that it can sort-of have a fast-forward feature for the regions that require a small local time step, when compared with other regions.

This strategy is sometimes preferable to using explicit steady-state modelling, because this method still preserves some time accuracy, which usually is not preserved in steady-state modelling... and time accuracy is important for certain simulations, such as chemical reactions, heat transfer and multiphase flows.

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   May 14, 2016, 09:56
Default
  #111
New Member
 
milad
Join Date: Oct 2015
Location: iran
Posts: 3
Rep Power: 11
freeman_68 is on a distinguished road
Quote:
Originally Posted by markusrehm View Post
Hi Rishi,

the presentation is the only documentation up to now. We need to add something to the Wiki, too.

So there are 2 parts:
1.) alternateChemistryModel A Library that allows the inclusion of alternate chemistry engines in solvers (allowing still to use OF chemistryModel)
2.) canteraThermosChemistry A Library that makes it possible to use Cantera in OpenFOAM

The libraries can be used by the solvers alternateSteadyReactingFoam and alternateReactingFoam. There are also examples included.

We had some issues to get Cantera running properly. I used the 1.7-CVS version. If you encounter problems with the standard version we can put a tarball of a running Cantera version onto the SVN, too. But Cantera 2.0 was announced and so we try to avoid unnecessary work

The main reasons for using Cantera are:
-easy access to thermochemical data and functions
-cantera has an excellent lexer for Chemkin-input
-you can use all transport data (viscosity, diffsion, heat transfer) from transport data which is often available with reaction mechanisms (e.g GRI-3.0)
-ideal reactor networks can be constructed and solved efficiently and stable with the CVODE stiff ODE solver package

I hope that helps and you find the tools valuable.

Regards, Markus.


Related Links:
Cantera:
http://sourceforge.net/projects/cantera

alternateChemistryModel:
https://openfoam-extend.svn.sourcefo...emistryModels/

canteraThermosChemistry:
https://openfoam-extend.svn.sourcefo...ermosChemistry

Solvers and examples:
https://openfoam-extend.svn.sourcefo...nateChemistry/
hi bodies
there are tutarial and or learning about cantera!?
freeman_68 is offline   Reply With Quote

Old   May 14, 2016, 10:00
Default cantera
  #112
New Member
 
milad
Join Date: Oct 2015
Location: iran
Posts: 3
Rep Power: 11
freeman_68 is on a distinguished road
hi bodies
are there any tutarial and or teaching about cantera!?
freeman_68 is offline   Reply With Quote

Old   September 28, 2016, 09:57
Default Cantera linking with OpenFOAM 3.0
  #113
New Member
 
Laurien Vandewalle
Join Date: Jun 2013
Location: Ghent, Belgium
Posts: 29
Rep Power: 13
lavdwall is on a distinguished road
Hi everybody,

I was wondering if anyone did the effort to link Cantera to OpenFOAM-3.0 (or OpenFOAM-2.x would be OK as well). The original libraries alternateChemistryModel and canteraThermosChemistry look very interesting, but it's quite hard to translate them into something compatible with later OpenFOAM versions. Any help would be appreciated

Kind regards,
Laurien
lavdwall is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 03:17.