My thesis is on developing numerical methods for model reduction in combustion. I run my methods purely on the chemistry part of combustion simulations, and I have plenty of case studies for 0-D simulations (no flow). What I would like is to run simulations that do have flow in them, preferably 2-D or 3-D simulations.

These simulations would need to be in parallel, due to the high computational requirements. I'd also need something that can interface with chemistry solvers like Chemkin or Cantera, for which I have the source code. (Chemkin is in Fortran 77, and Cantera is in C++.)

In the ideal case, I could specify a flow pattern using the basic knowledge of fluid mechanics I have from my grad program and some CFD package, add the chemistry, and run it. If I have to, I can set up the equations governing the fluid motion and chemistry for a simple case study based on an experimental setup used by a former collaborator, but I'd very much prefer not to roll my own CFD code unless there were a package or packages that made it extremely easy to do it. I'd be willing to spend 2-3 weeks on it; I don't know if this requirement rules out PETSc or Trilinos. If I have to spend any longer on it, I'd rather put it off until later, because I have a collaborator supplying a CFD code for case studies as well.

Does anyone have any experience using a CFD package or writing CFD code, and if so, can you recommend one? One thing I know I'd like to use is Strang splitting, but I'm not a CFD or PDE expert; I study the chemistry and the numerical methods for the model reduction. Also, please comment on how long it took you to get up to speed using the software you recommend.

@FrenchKheldar makes a good point that I should mention the characteristics of problems I'd like to solve:

  • Ideal (perfect) gas, single-phase
  • Compressible
  • Laminar flow is essential; turbulent flow is a plus. (I know a little bit about turbulence from previous work in numerical methods in CFD, but I haven't worked on CFD solvers; I just know a little about physics.)
  • Zero-Mach-number formulation is okay (I don't care about shocks or supersonic flow)
  • Combustion chemistry, ignoring Soret and Dufour fluxes, and treating diffusion as Fickian
  • Geometry can be something simple

I can write interfacing code, though the less I have to write, the better; @FrenchKheldar also points out that Cantera has Fortran and Python bindings. I use the Cantera Python bindings right now for rapid prototyping, so I'm comfortable with those also.

  • $\begingroup$ Cantera has wrappers for python and Fortran, so that widens the search a bit. $\endgroup$ Dec 15, 2011 at 4:31
  • $\begingroup$ Do you want to model laminar flows or turbulent flows? Compressible or incompressible? Perfect gas? Single-phase? The more details you can give us, the more precise the answer. $\endgroup$ Dec 15, 2011 at 4:34
  • $\begingroup$ @FrenchKheldar: Thanks for pointing that out. I've added some specifics. $\endgroup$ Dec 15, 2011 at 5:06
  • 2
    $\begingroup$ One more comment: if you don't care about acoustics or waves, shouldn't you be able to use an incompressible solver? That will widen your possibilities... $\endgroup$ Dec 15, 2011 at 6:07
  • $\begingroup$ Let me rephrase: I don't care about shocks. Since the phase is an ideal gas, and ideal gases change in density when the pressure changes, the flow should be compressible. $\endgroup$ Dec 15, 2011 at 19:36

5 Answers 5


I'm a heavy user of OpenFOAM, so naturally I'd recommend it. It has a large amount of features including combustion models (though not necessarily precisely what you need) and has been used together with Canterra by other people. If you need a solver for a specific equation that hasn't been implemented yet, you can pretty much literally write your equations. I don't know what strang-splitting is (I don't work on combustion myself), but other people have used it in OpenFOAM.

There is a limited amount of tutorials. The ones documented in the user guide do not include chemistry. There are some sample cases for the reaction solvers you can have a look at. Your best bet is to check out the OS-CFD grad course website at Chalmers (link is for 2011, but it contains a link to the pages of previous years). The students there often document the solvers they are working on, e.g. here.

About the effort to learn it: If you get by using one of the pre-defined models, it's fairly straightforward to use and you should be able to have results within weeks. If you have to descend beneath the top level (e.g. to add a new ODE solver), things can get more difficult quite fast and you'll appreciate to know C++.

  • $\begingroup$ Thank you for the recommendation! I've heard good things about OpenFOAM, and I would like to use it in the future. In your experience, was it easy to learn the API? Are there any good tutorials or examples that use OpenFOAM, preferably with chemistry? $\endgroup$ Dec 15, 2011 at 23:16
  • $\begingroup$ I updated my answer $\endgroup$
    – akid
    Dec 16, 2011 at 8:18
  • 1
    $\begingroup$ Start learning C++ soon. :) Godspeed. $\endgroup$
    – tmaric
    Dec 22, 2011 at 8:54

You could use PyClaw, a parallel extension of Clawpack (note: I am one of PyClaw's main developers). It includes 2D and 3D solvers for the inviscid Euler equations (compressible flow) of an ideal gas. It also has Strang splitting built in, but you need to add the evaluation of viscous terms and chemistry yourself. It should be straightforward to interface with Chemkin and Cantera, since PyClaw is written in Python and already includes both Fortran 77 and C code.

PyClaw is relatively new (though the underlying Clawpack code is fairly old) and thus not as established as something like OpenFOAM.

  • $\begingroup$ Thanks! I'll have to check it out, though it may take me a while to get to it. When I get around to using it, I will let you know how it goes. $\endgroup$ Dec 15, 2011 at 23:19

NIST's Fire Dynamics Simulator (FDS) sounds like what you want. FDS is a low Mach number flow solver. The density can change, but acoustic effects and shocks are neglected.

FDS is fairly well documented, though, I admit I have not looked in the main flow solver routines. I also do not know much about how FDS handles combustion chemistry.

I suggest downloading the latest code from FDS's Google Code site.


There are plenty over there!

OpenFOAM is the best, IMHO, but others are at this link,

  • $\begingroup$ Please do not give 'link only' answers, as links may get broken. $\endgroup$
    – Jan
    Nov 7, 2013 at 8:30
  • $\begingroup$ I did not want to present all the options mentioned in there as "mine". Technically, I could copy and paste all the contents, but I am not that person. So, I put the link straight to give credits to the original author(s) $\endgroup$
    – T3rmInAt0r
    Nov 7, 2013 at 11:16
  • 1
    $\begingroup$ Alright. But, you could, e.g., say that the chair for Computational Fluid Dynamics and Turbulence Mechanics at the university of Manchester has compiled a list of open source software for engineers. If you do so, fellow visitors can still search the internet in the case that the link is broken. $\endgroup$
    – Jan
    Nov 7, 2013 at 13:01

You can use the open source Advanced Simulation Library which is hardware accelerated (in the case high performance computation is important). It has both laminar and turbulent flows and chemical reactions. It is also easy to use, see the source code of the Aerodynamics of a locomotive in a tunnel benchmark.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.