CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Pre-Processing (https://www.cfd-online.com/Forums/openfoam-pre-processing/)
-   -   Internal Baffle Dynamic Boundary Condition (https://www.cfd-online.com/Forums/openfoam-pre-processing/127253-internal-baffle-dynamic-boundary-condition.html)

schuyler December 6, 2013 23:10

Internal Baffle Dynamic Boundary Condition
 
Hi Everyone,

I am working on a simulation where I essentially want a shock tube with a driver and a driven section (high pressure low pressure). But instead of like in the shock tube tutorial, I want to have the two sections separated by an interior baffle (inf thin) face that will open with time, given a function of time that I will define. Has anybody attempted to do something like this? The simulation would be 2dimensional, x and y and frontandback would be empty.

Making the internal face using toposet and createBaffles seems straight forward enough... but I don't know how to approach the time varying aspect. Can I have two baffles that shorten with time? Or is there a way I could code a boundary condition in the middle that has some sort of No flux->flux varying with time etc?

I have been using OpenFoam for just over a year and this is my first problem that has stepped outside the "standard" type of boundary condition. Any wise tips to save any fools errands would be greatly appreciated.

Thanks

S.

mturcios777 December 9, 2013 17:19

The attachDetach mesh modifier sounds like it could do the trick. Note that you would need to create your own mesh class for it. Its working in OpenFOAM 2.1.x-2.2.x, you can look at my bug reports getting it to work here:

http://www.openfoam.org/mantisbt/view.php?id=572

Good luck!

schuyler December 13, 2013 12:17

Thanks a lot Marco,

You are right the attachDetach utility is what I am looking for I think. So if I were to approach the problem by making a large number of internal faces in my tube that by using trigger times would subsequently attach to simulate the valve opening would this work?

S.

mturcios777 December 13, 2013 12:30

Attach detach would definitely do what you are asking as far as mesh topology changes. If you are at high pressure or velocity you may have to work a little harder to keep the simulation stable. There is a case included in the bug report that works once the fixes described in the thread are implemented. Please let me know if you have any questions.


All times are GMT -4. The time now is 19:13.