CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Programming & Development (https://www.cfd-online.com/Forums/openfoam-programming-development/)
-   -   Velocity BC (https://www.cfd-online.com/Forums/openfoam-programming-development/118198-velocity-bc.html)

felicemastronzo May 22, 2013 12:31

Velocity BC
 
Hi all,
I have this problem: basically I have a rotating mesh that is a cylinder with a hexahedric hole inside. I have to apply a rotation to the whole mesh in order to rotate the hex. Now the boundaries of the cylinder have a velocity due to the rotation of the mesh. What I want to do is to impose an opposite velocity BC on the walls of the cylinder in order to compensate the velocity that was applied by the mesh rotation.
Actually in OF there is a fixedValue velocity BC but it is not possible to impose a different direction for each point of the cylinder. The magnitude is also in my case constant v=r*omega but the direction should be tangent the the wall (cylinder external surface) and the normal to that surface changes for each element.
Can someone help me writing such BC?
I'm quite new in with OF and I'm actually not able to do that.

Regards
F.

felicemastronzo May 24, 2013 12:55

Nobody can help me?

F.

felicemastronzo May 27, 2013 07:56

Please guys, I really need help!

F.

eysteinn May 27, 2013 10:47

Hi,

So. . . I haven't done this myself but this hopefully gets you in the right direction.

There is a library called groovyBC that allow you to set arbitrary BC using expressions.
This libary is now included in swak4Foam. (So that is what you should install )

Check out these pages. It should be simple to implement the rotating BC that you want, there are some examples on those pages
( even though I'm not sure about how stable this will be. )

/Eysteinn

felicemastronzo May 31, 2013 14:36

Quote:

Originally Posted by eysteinn (Post 430291)
Hi,

So. . . I haven't done this myself but this hopefully gets you in the right direction.

There is a library called groovyBC that allow you to set arbitrary BC using expressions.
This libary is now included in swak4Foam. (So that is what you should install )

Check out these pages. It should be simple to implement the rotating BC that you want, there are some examples on those pages
( even though I'm not sure about how stable this will be. )

/Eysteinn

Tanks a lot!


All times are GMT -4. The time now is 21:39.