3D parabolic inflow profile
Dear OpenFOAM users,
I am simulating the growth, pinchoff, detachment and free rise of a single air bubble in water that is created by the steadyrate injection of air into a tank with water at rest from a small circular inlet at the middle of the bottom boundary (interFoam). The inflow is along the positive direction of the zaxis of the domain. So far I have used the mean inflow velocity value with a constant value at inlet and I have noticed that this causes some oscillations in my results. Therefore I want to use a parabolic inflow profile imposed at the circular inlet. Can anyone help me? Thank you very much in advance ageorg 
search for
1 code stream 2 groovyBC you will find how to do it ;) 
groovyBC
Thanks for the advise I will search for the things you suggest!

Quote:
I almost have the same issue. I want to impose a parabolic B.C for a 3D case with interFoam solver OF 2.1.1. So have you manged to sort out case? If you did, what kind of B.C you used? could you please advice or direct me if there is any direct tool to get it with out codding for a 3D case? Best Wishes, Sandy13, 
Yes I managed it using groovyBC in Swak4Foam
But i remember that i had to follow many forums in order to compile swak4Foam in OF 2.2.1 that i am working on. If you are able to compile this in your OF version get back to me through this forum and I will tel you how to use it for a 3D parabolic Inflow. ;) 
Dear ageorg,
Thank in advance for your help, I appreciate it very much. Yes please, I will try to compile it today, but If you have any hints how to do it with OF2.1.1 I would be very grateful.. Best wishes, Sandy13, 
This was quite long ago so the only thing I remember is that I followed instructions suggested in this forum and others and I finally managed to compile it. Just Google it and you will find the solution....then get back to me for the 3D parabolic inflow.

Quote:
I installed swak4foam and did all the downloading and compiling and I added the necessary libraries to my control dictionary as written in the instruction. What I need now is the type of groovy B.C for my case, I checked the groovy wiki web site and there are few types, so could you please direct me... My case is a liquid jet starts from above of my domain to downstream, so my flow in zdirection perpendicular on the xy plain. I have to tell you that I am not any good with c++.. best wishes, Sandy13, 
Dear ageorg,
I installed swak4foam and did all the downloading and compiling, I added the necessary libraries to my control dictionary as written in the instruction. Could you please help me out with the 3D parabolic profile B.C for velocity. Thank you in advance... Sandy13, 
3D parabolic Inlet Profile
inlet
{ type groovyBCFixedValue; variables ( "velIn=0.03822;" //velIn is the normal mean inlet velocity "c=sum(pos()*mag(Sf()))/sum(mag(Sf()));" //c is the centre of the patch "n=sum(normal())/mag(sum(normal()));" //n is the averaged patch normal "pp=pos()c;" "r=mag(pp)+1.0e10;" "R=max(r);" ); valueExpression "velIn*normal()*(1pow(r/R,2))"; value uniform (0 0 0.03822); } This is an example of the expression that I used for a 3D parabolic inflow profile This is a fully developed laminal profile for a circular inlet Maximum value at the center of the patch and reduces parabolically to zero at the edge of the patch Dont forget to add the libraries at the ControlDict According to version of OpenFoam you might get a few warnings when applying it but despite that it works fine PS: Dont expect to see it in paraview after initialization it starts after the first iteration Hope that this helps All the Best:) T. 
Dear ageorg,
Thanks so much for passing your code over, but I have only on question more.. The mean inlet velocity(velIn), is not the same value of velocity we get from solving Re number equation? or we have to impose the maximum one(which double the mean value) in the same position?. lat us assume I got u=20 m/s from solving the Re number equation... which is the mean value, so shall I impose one in as a parameter for the normal mean inlet velocity? Thanks in advance... Sandy13, 
The mean value of U is simply U=Q/A
Q: flow rate m3/sec A: area of inlet m2 Hope it is clear now Don't hesitate to ask me anything else... 
Dear ageorg,
Thanks for your replay. I know what you explained but what I have is a specific parameters and Re no, so I extracted the velocity value from solving the Re equation. Now I have this parameter in the B.C you gave to me. I am confused to put this value I got from Re as a mean or not? because solving Re gives us the mean value...am I wrong?? Sandy13, 
Average velocity in circular pipes is half the maximum
So use your half value of the one you calculated with your Re number..... 
1 Attachment(s)
Quote:
As you see from the attached picture, I imposed u mean =20 m/s which I got from solving Re equation but from the velocity variation It gives me varying between 020. So I did not get the max one I need which is should be about 40 m/s. Is this correct? Sandy13, 
Please send me a description or a paper of what you try to simulate I need more info in order to give you a correct answer... The info I gave you so far is in order to apply a parabolic inflow profile if you know your flow rate at the inlet following the theory for fully developed 3D laminal flow profile.
Send me some more details about your case and then I can advise you what to do T. 
Dear ageorg,
I am trying to simulate a liquid jet for water and make a comparison for this with another work. So i specification for geometry liquid, gas and specific Re and We numbers. So I have diamter of my case with the solving of Re and We I got the a velocity=10 m/s. So know when I use the parabolic B.C code you gave to me, If I put u=10 as an entry, i get max velocity value=10 as I done yesterday with picture I sent, but this is not correct because we know that Re works with the mean value and maximum one should be around double this one, i.e. u=20. Best Wishes, Sandy13, 
Dear ageorg,
Sorry, the value I imposed for mean u was 20 m/s, not 10 as I said, so I should get maximum around u=40 Snady13 
If your flow is turbulent then try to put 2 times the mean velocity in the code I send you and it should work....

Dear ageorg,
Thanks a gain for your help. My flow is laminar for my case, so, do I have to put the mean value in the code in this case?.. Best Wishes, Sandy13 
All times are GMT 4. The time now is 17:45. 