|
[Sponsors] |
rhoCentralFoam not reflecting shock in Shock Tube? |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
October 23, 2011, 18:02 |
rhoCentralFoam not reflecting shock in Shock Tube?
|
#1 |
New Member
Sean
Join Date: Oct 2011
Posts: 3
Rep Power: 15 |
Disclaimer: I am brand new to OpenFoam and a fairly poor Ubuntu user.
I've been playing around with OpenFoam while taking a class in compressible flow theory. I've been taking a look at the shock tube tutorials because we covered that topic in class and they seemed rather simple to set up. When I ran the shock tube found in the sonicFoam folder, everything looked good qualitatively. A shock formed, proceeded down the tube, reflected off of the wall. An expansion wave did the same in the other direction. HOWEVER, when I looked at the velocity profile, I saw that the velocity behind the reflected shock was not zero (like our textbook says it should be). Looking into this further, I saw several posts describing sonicFoam as unreliable for subsonic flows. So then I tried rhoCentralFoam in the rhoCentralFoam folder. I get the shock and expansion waves, but they don't reflect off of the walls at the end of the tube. It's almost as if there are no walls there? Unfortunately I still haven't learned how to read most of the setup files. I know only enough to be dangerous and screw things up . If anyone has the patience to deal with a beginner such as myself, I would be incredibly grateful as this looks like an awesome tool, and I look forward to using it in my mischief making ways. |
|
October 24, 2011, 10:47 |
|
#2 |
Senior Member
|
Hi Sean,
I don't know the shockTube-tutorial by heart, but sometime ago I did some simulations which reflected nicely. So I guess it really is the setup of the tutorial case. Let's analyse it for the basic conditions: - Check the output of your blockMesh: Does it tell anything about undefined patches being added to an "empty" patch? If these are your tube-ends among these undefined patches? If yes, go to the next step. - Look into the constant/polyMesh/blockMeshDict: Are the ends contained in a patch that is called walls or something similar? If this is not the case, try to find the definitions of these patches within the blockMeshDict and add them to the walls-patch that is there. - If the endings are contained in the walls-patch, check the files in the 0-folder. See if they are described with a wall-condition or if they are something like inlet, outlet, zeroGradient,... I guess, these should be the steps that most probably cause the problem - and moreover are correctable even without too nerdy knowledge about the intestines of OpenFOAM. ;-) Let us know if it works or where the problems are situated! PS: If there is a correct way to start OpenFOAM, I guess you chose one of them! ;-) |
|
October 27, 2011, 02:12 |
|
#3 |
New Member
Sean
Join Date: Oct 2011
Posts: 3
Rep Power: 15 |
Well I've checked the blockMeshDict files in both of the shock tube cases...nothing different that I can tell. Since I've last posted, I tried moving ALL of the sonicFoam files into the rhoCentralFoam/shockTube folder...with the result that I've now destroyed my rhoCentral/shockTube case . I'll try to rebuild it from another case, but so far things aren't looking good for my shock tube.
|
|
October 27, 2011, 05:21 |
|
#4 |
Senior Member
|
Well, there should be a shocktube-case in the tutorials for rhoCentralFoam. Unfortunately it did not work out of the box the last time I tried, but surely it is a good starting point...
But how strong was the shock? Are the reflections strong enough to be seen via the used postprocessing? How about trying a stronger shock? In case problems stay, maybe you could post your basic case within a .tar.gz-archive here? Then people here could check for problems as well. Don't forget to remove all but the blockMeshDict from constant/polyMesh before uploading it. The other files are big but easily produced by a simple blockMesh-run. (As you are new to linux: "tar czf newfilename.tar.gz file-to-be-compressed" is the command for getting the socalled tarball, which you can attach via the attachment-menu in this forum.) |
|
March 3, 2012, 22:13 |
Solved!
|
#5 |
New Member
Sean
Join Date: Oct 2011
Posts: 3
Rep Power: 15 |
Ok,
I solved my problem and I'm resurrecting this thread so others can fix their tutorials as well. The problem lies in the velocity boundary conditions at the walls. The shocktube tutorials for both sonicFoam and rhoCentralFoam have zeroGradient as the velocity (U) boundary condition at the walls. THIS IS WRONG! The boundary condition should be set to fixedValue with the value being "uniform (0 0 0)" The boundary condition for magU needs to be set the same as U (uniform 0, since it's a scalar) Making these changes should result in a shocktube result that looks closer to the analytical solutions. I've only looked at the results qualitatively. Regards, Astaria |
|
March 4, 2012, 04:07 |
|
#6 |
Senior Member
Alberto Passalacqua
Join Date: Mar 2009
Location: Ames, Iowa, United States
Posts: 1,912
Rep Power: 36 |
There is no error in the tutorial, which is a case of Sod's shock tube, in which there are no walls.
__________________
Alberto Passalacqua GeekoCFD - A free distribution based on openSUSE 64 bit with CFD tools, including OpenFOAM. Available as in both physical and virtual formats (current status: http://albertopassalacqua.com/?p=1541) OpenQBMM - An open-source implementation of quadrature-based moment methods. To obtain more accurate answers, please specify the version of OpenFOAM you are using. |
|
Tags |
openfoam 2.0.1, reflection, rhocentralfoam, shock tube |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
HLL Riemann Shock Tube Matlab Problem | Luke F | Main CFD Forum | 2 | May 20, 2016 03:10 |
Shock tube simulation | harish | FLUENT | 5 | January 25, 2014 03:20 |
shock tube validation | AB | Main CFD Forum | 3 | December 10, 2004 08:31 |
shock tube validation | AB | Siemens | 0 | November 21, 2004 19:43 |
Shock tube problem | AB | Siemens | 1 | November 9, 2004 01:25 |