CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [Other] dynamicRefinefvMesh (https://www.cfd-online.com/Forums/openfoam-meshing/200975-dynamicrefinefvmesh.html)

interDyFoam April 18, 2018 09:52

dynamicRefinefvMesh
 
1 Attachment(s)
Hi,

I am using Adaptive Mesh Refinement on simulations of rain drop.But the problem is it is not working on the sphere.Does anyone know why? Below are my dynamicMeshDict and setFieldsDict.

Thanks in advance,
Pete


FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object dynamicMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dynamicFvMesh dynamicRefineFvMesh;

dynamicRefineFvMeshCoeffs
{
refineInterval 1;
field alpha1;
lowerRefineLevel 0.0000001;
upperRefineLevel 0.999;
unrefineLevel 10;
nBufferLayers 1;
maxRefinement 2;
maxCells 500000;
correctFluxes
(
(
phi
U
)
);
dumpLevel true;
}

// ************************************************** *********************** //



/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.2.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object setFieldsDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

defaultFieldValues
(
volScalarFieldValue alpha1 0
);

regions
(
sphereToCell
{
centre (0.035 0.01 0.09);
radius 0.001;
fieldValues
(
volScalarFieldValue alpha1 1
volVectorFieldValue U (0 0 -8)
);
}

boxToCell
{
box (0 0 0.005) (0.07 0.02 0.01);
fieldValues
(
volScalarFieldValue alpha1 1
);
}


);


// ************************************************** *********************** //

Elham April 29, 2018 05:25

Quote:

Originally Posted by interDyFoam (Post 689344)
Hi,

I am using Adaptive Mesh Refinement on simulations of rain drop.But the problem is it is not working on the sphere.Does anyone know why? Below are my dynamicMeshDict and setFieldsDict.

Thanks in advance,
Pete


FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object dynamicMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dynamicFvMesh dynamicRefineFvMesh;

dynamicRefineFvMeshCoeffs
{
refineInterval 1;
field alpha1;
lowerRefineLevel 0.0000001;
upperRefineLevel 0.999;
unrefineLevel 10;
nBufferLayers 1;
maxRefinement 2;
maxCells 500000;
correctFluxes
(
(
phi
U
)
);
dumpLevel true;
}

// ************************************************** *********************** //



/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.2.1 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object setFieldsDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

defaultFieldValues
(
volScalarFieldValue alpha1 0
);

regions
(
sphereToCell
{
centre (0.035 0.01 0.09);
radius 0.001;
fieldValues
(
volScalarFieldValue alpha1 1
volVectorFieldValue U (0 0 -8)
);
}

boxToCell
{
box (0 0 0.005) (0.07 0.02 0.01);
fieldValues
(
volScalarFieldValue alpha1 1
);
}


);


// ************************************************** *********************** //


How many cells do you have before refinement. You can find out by execution of the following command:

checkMesh

If it is higher than the number maxCells you should increase it.

Cheers,

Elham

interDyFoam April 30, 2018 06:51

2 Attachment(s)
Thanks for your reply, but the number is good. I used paraview to get a look of the result. i do not know why it shows like below.

Elham April 30, 2018 10:22

Quote:

Originally Posted by interDyFoam (Post 690734)
Thanks for your reply, but the number is good. I used paraview to get a look of the result. i do not know why it shows like below.

It seems that it is refined in the interface.


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