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/)
-   -   Problem with Dynamic Mesh Refinement (Bug) (https://www.cfd-online.com/Forums/openfoam-solving/231899-problem-dynamic-mesh-refinement-bug.html)

mostanad November 23, 2020 02:50

Problem with Dynamic Mesh Refinement (Bug)
 
3 Attachment(s)
Hello my friends,
I have found an issue in my refined grid, specifically when I restart my case from a non-zero time. The solver in InterDyMFOAM. Here you can see the details in my dynamicMeshDict
Code:

dynamicFvMesh    dynamicRefineFvMesh;//staticFvMesh;

dynamicRefineFvMeshCoeffs
{
    refineInterval  1;//refine every refineInterval timesteps
    field          interFace;
    lowerRefineLevel 0.0001;
    upperRefineLevel 0.99;
    unrefineLevel  10;
    nBufferLayers  1;
    maxRefinement  2;//maximum refinement level (starts from 0)
    maxCells        20000000;
    correctFluxes
    (
        (phi    U)
        (phi_0  U)
    );
    dumpLevel      true;
}

As you see, the refinement is done based on interface field, which is the interface between my object and fluid. I have 4 processors in my case, and I know that the cellLevel history is saved for each writing interval. BTW, As I restart my case, the mesh does not coarsen when my moving object pass from processors. Indeed, the processor interface location maintains its level 1 value even if the moving object passes from that region. It seems that something is wrong with decomposition of reconstruction of the latest Time.



Code:

reconstructParMesh -mergeTol 1e-06
reconstructPar -noLagrangian

Please,Please, just take a look at the images in the attachment to see what I am exactly talking about? The images depict the motion of my object and the cellLevel field.

Thank you for you help, in advance, Foamers!

mostanad November 23, 2020 06:55

No idea from anyone?

guin November 23, 2020 07:18

Take a look at the actual values you have at "interFace" field. You must zoom in the scale of values in order to detect remaining traces approximately in the order of lowerRefineLevel (0.0001) behind your bubble/droplet.

mostanad November 23, 2020 07:31

Quote:

Originally Posted by guin (Post 788560)
Take a look at the actual values you have at "interFace" field. You must zoom in the scale of values in order to detect remaining traces approximately in the order of lowerRefineLevel (0.0001) behind your bubble/droplet.

Thanks Rodrigo for your reply.
I look at the interface field but the extra refined cells have exactly 1 value. So it is not in the range of 0.001 to 0.99. It has confused me! You can see the filed in the attachment.




https://i.ibb.co/0yDqGNS/latest-Time-interface.jpg

mostanad November 23, 2020 08:28

Why I have this extra refinement?! :mad::(
If any one can help me, please ask me the details.

mostanad November 24, 2020 04:04

Fixed.
Don't use decomposePar in your restart run again. This will remove the processor directories of the latest Time, so by doing the new decomposePar, all the things for the new decomposed latest time is messed up.


All times are GMT -4. The time now is 19:41.