warnig about mesh

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Filippo Monari

warnig about mesh

Post by Filippo Monari »

Often I get this error:
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @                                                           
@
@@ WARNING: MESH TOO REFINED AT THE WALL                  
@    ========                                               
@    PHASE          1
@    The mesh seems to be too refined at the wall to use    
@      a high-Reynolds turbulence model.                     @                                                           
@    The last time step at which too small values for the   
@      dimensionless distance to the wall (yplus) have been 
@      observed is the time step         12
@                                                           
@    The minimum value for yplus must be greater than the   
@      limit value YPLULI =    0.23810E+01
@                                                           
@    Have a look at the distribution of yplus at the wall   
@      (with EnSight for example) to conclude on the way    
@      the results quality might be affected.                @                                                           
@    This warning is only printed at the first two          
@      occurences of the problem and at the last time step  
@      of the calculation. The vanishing of the message does
@      not necessarily mean the vanishing of the problem.    @                                                            @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
and few time steps after I have an error about the convergence of the turb energy in some cells near the corner of the domain.

Now I have a large domain with a little building in the middle and where I get the error is not the most refined part of my mesh.

I was thinking to decrease the precision of the solver (I think for my study 1e-4/e-5, would be fine) or change the value of the Uref (I think to have a bit higher value than 1 in the cells), but I don't know if these are a right thing to do.

I post my xml file and the listing as well
Attachments
case1-1.xml
(7.86 KiB) Downloaded 167 times
listing.txt
(100.34 KiB) Downloaded 171 times
César Vecchio

Re: warnig about mesh

Post by César Vecchio »

Filippo, the message you're getting is saying that the cells immediately adjacent to the walls (in your case, the building walls) are too small. This is a limitation of the turbulence model you are using, K-Epsilon. This turbulence model "asumes" how the laminar sublayer is, and if you have very small elements on the walls, then you're inside the laminar sublayer, thus making the formulation erroneous. You have to check the value called Y+, also known as Y Plus, which for the K-Epsilon model has to be between 30 and 100. If Y+ <= 1, then you're inside the laminar sublayer.
If you want to keep using K-Epsilon, you have no other choice than making a new mesh. You can find online calculators which will help you estimate the height of the adjacent cells based on the Re number and the desired Y+ (they just make rough estimations, but it's better than nothing). If you want to keep your mesh, you will need to change the turbulence model or use no turbulence model at all (laminar flow).
Yvan Fournier

Re: warnig about mesh

Post by Yvan Fournier »

Hello,
In any case, I really recommend checking the y+ values with a visualization tool such as ParaView (don't forget to use the "extract blocks" filter first to access boundary parts) or EnSight: with a complex (or even not-so complex) geometry, the flow may have a very low velocity at a few faces (such as behind an obstacle), leading to the warning you observe even though the mesh is mostly well adapte to the flow. On the other hand, if y+ is too low everywhere, then you should either coarsen the mesh near the walls, or use another turbulence model.
Best regards,
Filippo Monari

Re: warnig about mesh

Post by Filippo Monari »

well thank you for the advices and help.
Anyway I've made another trial with reducing time step and precision of the solution and now the system converge.
I've choose a time step of 0.0001 s and a precision of 1e-4 because I don't need the high precision of 1e-8. Is that a correct way to lead the simulation or my data will be corrupted?  
Yvan Fournier

Re: warnig about mesh

Post by Yvan Fournier »

Note that as the algorithm is segregated (solving variables separately and computing corrective increments), the precision is a "per linear system" precision, not a global precision. You may also adjust the gradient reconstruction precision.
1e-8 for linear systems is the default, but we often also use 1e-5 (I believe it is actually the default for LES).
1e-4 seems a bit low, so it might be is risky. You may want to run a computation (or a significant part thereof) using 1e-4 and 1e-5, and compare the 2 (when comparing if the results are even just slightly oscillating, compare probes over a significant time, or visualize time averages of fields in addition to instant values, to avoid risky interpretation).
It is always hard to estimate a priori the final precision of a calculation, and other factors (such as choice of time step or turbulence model) may have just as much influence as moving from 1e-8 to 1e-5, so running a few sensibility tests with different parameters on a specific case rather than interpreting it based on a single calculation is always a safe practice.
Filippo Monari

Re: warnig about mesh

Post by Filippo Monari »

Hi, I'm trying to check with paraview the y+ value of my mesh.
What file I hve to load in paraview? the mesh file, the quality file or the preprocessor file produced by saturne?
And wich is the value to check? loading the quality mesh I found a lot of values but anyone tell me something about y+.
Thank you in advance.
Mickael Hassanaly

Re: warnig about mesh

Post by Mickael Hassanaly »

Hi Filippo,
 
i think you have made a check_mesh but this won't help you to get Y+ value. When you run your simulation, stop it just before you got a crash and visualize the content of your CHR.ENSIGHT.*** directory. You have to open your CHR.case file in paraview then follow the advices of Yvan. Take note that you need to ask through the interface the post-processing of boundary in output control menu (otherwise Y+ value won't be available under paraview. I hope this will help you. Let me know if it's ok or not.
 
Best regards
 
Mickaël
Filippo Monari

Re: warnig about mesh

Post by Filippo Monari »

thx Mickael for the advice.
Well I load the file chr.case, then in order to find the boundary i choose extract block from the filter menu but i can choose just fluid volume.
Now I'm meshing with salome and I have defined my boundary through groups of faces. Can this be a problem for paraview.
Excuse me but it's the first time i facing the problem....maybe some question could be stupid...if someone can tell me some tutorial to get the y+ value with paraview...I would be glad.
Thank you and see you
Yvan Fournier

Re: warnig about mesh

Post by Yvan Fournier »

Hello,
Defining groups of faces in SALOME will make no difference to the output of Y+: you need to activate the output of boundary values in the postprocessing options, then re-run the calculation (or a restart on a few time steps). Then, the boundary mesh will be available when you use ParaView's "extract blocks" filter.
Best regards,
  Yvan
Filippo Monari

Re: warnig about mesh

Post by Filippo Monari »

Hi thank to you all, I finally was able to get the y+ value. I post the image of my domain.

I'm running a steady flow simulation with an inlet velocity of  2m/s.

My inlet is on the right side and the outlet on the left. It seems that all the part on the right has a y+ value under 1! Am I so far form standard value of 30<y+<100 (as Cèsar said to me)?

My problem is that I've already coarsen my mesh without any good result. I think that the problem could be the little dimension of my ventilated facade in the building (5cm) compared against the entire domain, so I think I should simplify the model...but I'm afraid to get too much approximated data in that way.

I'll try to explain better...I'm making this analysis in order to find the pressure coefficients induced by given wind conditions, for the air entering in the ventilated facade and, being the fort time i facing such a problem, I don't know if considering the ventilated facade as a unique body instead as group of separated elements, rather than taking the flow laminar could affect in an important manner my results.

If anyone has experience of such analysis could give advices about to overcome the problem?

Thank you for your help.
Attachments
y.png
Post Reply