CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   NO Moving Probes for Moving Mesh in Foam Extend 4.0 (https://www.cfd-online.com/Forums/openfoam-solving/185966-no-moving-probes-moving-mesh-foam-extend-4-0-a.html)

alia April 6, 2017 13:08

NO Moving Probes for Moving Mesh in Foam Extend 4.0
 
Dear Foamers,

In OpenFOAM we are able to define probes that are moving with a moving mesh which is very useful for example in pressure probing of moving objects. this capability unfortunately I think is not available in Foam-Extend versions, which is a very big flaw especially for FSI applications.

the following lines which are in probes.H files of OpenFOAM are missing in Foam Extend versions:
Code:

//- Fixed locations, default = yes
//  Note: set to false for moving mesh calculations where locations
//        should move with the mesh
   
//- Interpolation scheme name
//  Note: only possible when fixedLocations_ is true
word interpolationScheme_;      bool fixedLocations_;

anyone knows how to resolve this issue? or can we fix it in probes.H and probes.C files?

Thank you

Ali

alia September 19, 2017 04:59

Solved
 
I did solve this problem a while ago and I want to share it here.
it is quite simple to have probes moving with mesh. you just need to comment out the following lines from the probes.C file

Code:

    if (mesh.moving() || mesh.changing())
    {
        cellList_.clear();
        findCells(mesh);
    }

cheers

Bazinga June 7, 2018 05:15

Is there anything else I need to do? I commented out the part of the code but the probes are still not moving with the mesh although I added "fixedLocations false" in the controlDict.

alia June 7, 2018 05:36

1 Attachment(s)
Quote:

Originally Posted by Bazinga (Post 695013)
Is there anything else I need to do? I commented out the part of the code but the probes are still not moving with the mesh although I added "fixedLocations false" in the controlDict.

Dear Bazinga, you need to copy the probes directory in your FOAM_USER directory and rename the class to create a new class like myProbe. after compiling it should work. make sure you type the name of the new probe in the probe definition in controlDict.
I just put my adjusted probe code here. I hope it helps.
Cheers
Ali

Bazinga June 7, 2018 06:10

Thanks for the fast reply. I will try it, but I am not too familiar with this. If possible, to make things a bit easier, can you share your code?
edit: Thank you so much :)

alia June 7, 2018 06:23

I just edited my last reply and attached the code
Cheers

gigliagarf June 25, 2018 09:24

I also am having trouble with this exact issue, I tried your approach with commenting out the section and duplicating the probes folder to make myprobes, however it didn't compile correctly. I also tried just downloading your folder to my $WM_PROJECT_USER_DIR and typing wmake within it, without success. Do you have any suggestions as to what I might be doing wrong? I have fsi foam and waves2foam installed as well, do you think they have broken the functionality or your fix?


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