![]() |
non reflective boundary conditions for incompresible flow
Hi all,
I'm simulating incompressible wake vortices in ground effect and I need non reflective boundary conditions to minimize the deformation of my wake vortices when they come close to the boundary. (right now I'm using zero normal gradient for U and P) 1 - Does OF 1.6.x has any existing boundary conditions that could do this? I looked in : /OpenFoam-1.6.x/src/finiteVolume/fields/fvPatchFields but found nothing. 2 - If I need to implement new boundary conditions which one should I use as starting point? i.e. which boundary conditions is the most similar to non reflective boundary conditions (I did not try all of them, but some of them) 3 - What the boundary conditions should do is something like this : dU/dt + Un*dU/dn = 0 where U is the velocity vector t is the time Un is the velocity normal to the boundary n is the normal vector to the boundary Any ideas? Thank you, Pascal |
Hi all,
Here's what I tried to implement user's define boundary conditions in OF 1.6.x. I started by creating the following folder: mkdir -p $WM_PROJECT_USER_DIR/src/finiteVolume/fields/fvPatchFields/derived Then I tried to compile my boundary condition as a new dynamic library. My first try was using the existing BC `zeroGradient` found in : $FOAM_SRC/finiteVolume/fields/fvPatchFields/ (I copied it in my $WM_PROJECT_USER_DIR/src/finiteVolume/fields/fvPatchFields/derived) Then I created the 'make' folder containing: the 'files' file: Code:
zeroGradientFvPatchField.CCode:
EXE_INC = \Code:
ag74290@mec036470:~/OpenFOAM/ag74290-1.6.x/src/finiteVolume/fields/fvPatchFields/derived/zeroGradient$ wmake libsoPascal |
Hi, I'm currently looking for a solution to a similar problem. I want a non-reflecting boundary condition for an incompressible flow field without any temperature specification.
Have you made any progress with your search? Thanks. |
Hi steph79,
Look at advective BC in : /home/ag74290/OpenFOAM/OpenFOAM-1.6.x/src/finiteVolume/fields/fvPatchFields/derived/advective It solves D(psi)/Dt = 0 where psi could be U, p, etc. (and probably T) regards, Pascal |
Thanks for your reply!
I seen one of your follow-up posts where you explicitly wrote out the code you specified your boundary conditions through, notably the following; Code:
outlet |
Hi,
I didn't have good result using advective BC, so I change the definition of parameter f which is called valueFraction in the source code (and needed by mixed BC). With f=0.75 I have very good result! (I'm using backward time scheme with Co=1.0) So I use a modified version of advection (which I called : myAdvection) for U and p and I used f=0.75. Code:
outletPascal |
Ok, I can see the valueFraction parameter several times in the advectiveFvPatchField.C source code but I lack the experience in coding and compiling to replicate your success. I might ask for some more help but can I ask first what physical argument is this 0.75 value (or any value fraction) based on or is it just of case that it gives what you want, if you know what I mean?
I too would be using backward time-stepping to minimise numerical dissipation. Fluctuations in the flow field are what I'm ultimately interested in, hence the need for a pressure outlet which doesn't simultaneously act like a wall! |
Quote:
Code:
|
Hi Stephanie,
Quote:
http://www.cfd-online.com/Forums/ope...tml#post185688 The valueFraction is define differently depending on the time scheme you use and if you use linf = 0 or linf > 0 Quote:
/home/ag74290/OpenFOAM/ag74290-1.6.x/src/finiteVolume/fields/fvPatchFields/derived/myAdvective modify the source code everywhere : advective become myAdvective In your Make/files : Code:
myAdvectiveFvPatchFields.CCode:
EXE_INC = \Code:
wmake libso/home/ag74290/OpenFOAM/ag74290-1.6.x/lib/linux64GccDPOpt Now to use your new BC add this line at the end in your controlDic: libs ("libOpenFOAM.so" "libmyAdvective.so"); Regards, Pascal |
That's a great help again and a detailed answer, thanks!
I *think* (subject to change) that the advection boundary condition specified in u and p does the trick because I can't see the reflections anymore and the remaining 'wiggles' can be attributed to the use of higher order spatial and temporal schemes. Is it correct to say that the advection BC is the equivalent of a pressure outlet with a target mass/volume flow rate? Just wondering, have you been using probes to capture fluctuating velocities in your flow field? I can resolve the u,v and w components of the velocity vector at points using probes but that's more information than required, I would rather just have the magnitude alone. The output files are messy enough to handle! I guess that's another question, what's the best tool to post-process output files from probes? I'm not familiar with gnuplot but I've heard it mentioned in that context before. Thanks. |
Quote:
Quote:
/home/ag74290/OpenFOAM/OpenFOAM-1.6.x/applications/utilities/postProcessing You could find a good starting point for creating your own utility. Regards, Pascal |
Hi Pascal,
When you used the (my)advective boundary condition, did you use it for both p and U? I am struggling to establish a compressible flow from a plenum through an orifice into a long duct. All my simulations blew up after keeping fluctuating for a long time. I set up the conventional total p and total T at the plenum and fixed p at the outlet of the duct. I am not comfortable with the zero gradient outlet boundary for U. Do you think I should use the advective boundary just for U or for both U and p and set the 'value' to the pressure I want for p? Could you give me some advice on this? Thank you in advance. :o |
| All times are GMT -4. The time now is 07:27. |