CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Pre-Processing

How can I get velocities(U) near a boundary?

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 27, 2016, 06:18
Default How can I get velocities(U) near a boundary?
  #1
Member
 
Lee Jung Hoo
Join Date: Dec 2015
Posts: 37
Rep Power: 10
Jung hoo is on a distinguished road
Hi, I need to get velocities near the bottom(boundary), and the values of velocities at the bottom(boundary) are zero due to non-slip condition.

So, I want to make a new boundary(surface) near the bottom(boundary), and extract velocities on the new boundary.

Then, I want to arrange those values to certain file(e.g. alpha.water).

Any comments regarding this will help me a lot.

Additionally, Is it possible to set a volume(not surface) to a boundary?

Thank you in advance..!
Jung hoo is offline   Reply With Quote

Old   July 27, 2016, 10:16
Default
  #2
Member
 
Join Date: Feb 2015
Posts: 39
Rep Power: 11
HenningW is on a distinguished road
I am not sure if i get your problem, but how about using a plane in sample or probing a plane while running the calculations? You have several options in which way your data on that sample surface could be saved (e.g. openFoam file format)
HenningW is offline   Reply With Quote

Old   July 28, 2016, 10:43
Default
  #3
Member
 
Lee Jung Hoo
Join Date: Dec 2015
Posts: 37
Rep Power: 10
Jung hoo is on a distinguished road
Thank you for your reply, Henning.

Can I ask you a little bit more detailed question?

I want to extract velocities at intervals of 10cm above the bottom(boundary) after one-time step, and then the morphology of bottom(boundary) is changed due to some calculation using the velocities over the bottom(boundary). Then velocities over the bottom are needed again in the next time step.

This process is repeated during the whole calculations, and accordingly the morphology of bottom is changed on and on.

Is it possible to get velocities and bring them to my solver at each time step using 'sampleDict' or other utilities??

Any ideas will help me a lot! Thanks!!
Jung hoo is offline   Reply With Quote

Old   July 29, 2016, 04:54
Default
  #4
Member
 
Join Date: Feb 2015
Posts: 39
Rep Power: 11
HenningW is on a distinguished road
You can try append this to your system/controlDict file to get the values (basically its like sampleDict but run during calculations - in this case at each time step):

Code:
functions
{
    cuttingPlane
    {
        type            surfaces;
        functionObjectLibs
        (
            "libsampling.so"
        );
        outputControl   timeStep;
        outputInterval     1;
        surfaceFormat   foamFile; // Select the format you want you data saved as
        fields          
        ( 
            p U k epsilon // values you want to extract
        );
        interpolationScheme cellPoint;
        surfaces
            (
                SurfaceName //Any name you want to give it
                {
                type cuttingPlane;
                planeType pointAndNormal; //Different options possible
                pointAndNormalDict
                {
                    basePoint (0.5 0 0); //Point the plane should cut through
                    normalVector (1 0 0); //Vector normal to plane
                }
                interpolate true;
                }
            );
}
This way you should be able to get values for each time step (saved somewhere in the postProcessing folder). I have no clue how to go on from here to be honest. It sounds to me as if you need to rewrite a solver to include the data in further process steps. Also keep in mind that what you describe might require a deformed or new mesh, if i get you right.
HenningW is offline   Reply With Quote

Old   July 30, 2016, 00:03
Default
  #5
Member
 
Lee Jung Hoo
Join Date: Dec 2015
Posts: 37
Rep Power: 10
Jung hoo is on a distinguished road
Oh, that is what I want almost exactly! Thank you so much.

I would better check the libraries for sampling to know more about it.

I'm sorry but.. I have some last questions.

Can I extract velocities in certain volume as well as surface using the sampling in the whole domain? (e.g. from x=0, y=0, z=0 to x=3, y=3, z=3)

And do you know an example or have any idea related to interaction between 'a solver' and 'result of post processing' at every time steps? It's because the extracted velocities have to be sent to 'my solver' at every time steps for mesh deformation.

I'm very appreciative of your kind reply.
Thanks a lot!
Jung hoo is offline   Reply With Quote

Old   August 1, 2016, 09:07
Default
  #6
Member
 
Join Date: Feb 2015
Posts: 39
Rep Power: 11
HenningW is on a distinguished road
Sorry, I haven't done that. Try to find out more about sampleDict settings. I would assume that it is the best bet for a volume, if its possible. Usually the Settings in control dict are more or less the same.

Regarding the interaction, you might want to look for Fluid-Structure-Interaction(FSI) examples. This is something i have not used as well, but as far as i know i requires a constant communication between solver and results. So that might be worth looking into.

What are you trying to simulate anyway?
HenningW is offline   Reply With Quote

Old   August 3, 2016, 09:20
Default
  #7
Member
 
Lee Jung Hoo
Join Date: Dec 2015
Posts: 37
Rep Power: 10
Jung hoo is on a distinguished road
Thank you! I think your recommendations will really be helpful for my study.

I'v been trying to simulate bottom-current interaction and resulting scour on the bottom in a fluid.

So, the mesh at the bottom must change slightly at every time steps.

But I'm beginner in compiling, so I have had difficulty with building a solver for the simulation.

I'm planning to learn how to compile a solver and how to modify functions(I'm beginner in c++ as well) in more detail.

Thank you for your help.
Jung hoo is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
3D Windturbine simulation in SU2 k.vimalakanthan SU2 15 October 12, 2023 05:53
Centrifugal fan j0hnny CFX 13 October 1, 2019 13:55
Low torque values on Screw Turbine Shaun Waters CFX 34 July 23, 2015 08:16
Implementation of boundary conditions for FVM Tom Main CFD Forum 7 August 26, 2014 05:58
GETVAR Error in Multiband Monte Carlo Radiation Simulation with Directional Source silvan CFX 3 June 16, 2014 09:49


All times are GMT -4. The time now is 20:10.