CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Running, Solving & CFD (
-   -   shockTube simulation different solvers (

feijooos November 18, 2009 21:30

shockTube simulation different solvers
Hi All,

I am working on simulating a shockTube in OF. I noticed that there are several shockTube tutorials available. I ran some of these, but I am confused what solver to pick. Do sonicFoam and rhoCentralFoam etc. give the same results?

Besides that, I noticed that the shocktube velocity in sonicFoam becomes sub-sonic. Isn't sonicFoam only for sonic flow?

In general, I am wondering what solver to use for this kind of problem?
I want to simulate the driver section with 2000 kPa and the driven section under atmospheric pressure (101.3 kPa). Temperature on both sides will be 300 K.

Thanks for you help!

KrisT November 19, 2009 05:33

I tried the shock tube tutorials in OpenFOAM before rhoCentralFoam. They give the wrong results (shock speed and states are wrong). You should use rhoCentralFoam (or maybe the new AeroFOAM -

If you wish you could test the solution against an analytical one, check the code in this link

feijooos November 19, 2009 11:49

thanks for the help, comparing against an analytical solution is a great idea!



feijooos November 19, 2009 12:14

btw, do you have any idea why sonicFoam gives the wrong solution? This gets me thinking why the tutorial is given in the first place....

KrisT November 19, 2009 16:09

No, but maybe scheme is not conservative?

feijooos November 19, 2009 16:22

hmm I was more thinking in the line of this: sonicFoam is only for sonic flow and a shocktube will always have sub-sonic flow.

jploz November 20, 2009 05:10


have a look at the following Master thesis by B. Wuethrich: 'Simulation and validation of compressible flow in nozzle geometries and validation of OpenFOAM for this application'. This work deals with shock tube problems and the solvers in OF ( Nice work.

Good luck.

feijooos November 20, 2009 11:44

Very nice documentation on this project indeed. This will be very helpful.



feijooos November 20, 2009 18:20

Jean-Peer, I read through the document and verified several OF solver. They seem to line up very well against the analytical solution, especially rhoCentralFoam and rhopSonicFoam. Others are not so good, such as sonicFoam, which makes sense.

This was very helpful. Thanks

All times are GMT -4. The time now is 18:33.