Very thin boundary layers and y+ on complex geometry

Darn, I just took a look for the first time and I do not think we will have any EVR results to plot. I was hoping that we had the numerator (nut) and denominator (nu) already available but I guess everyone needs to vote on this Turbulent Viscosity Ratio Calculations since we only have nut in the results… .

@jousefm how do we get this feature quickly, I think it will substantially reduce all the speculation about whether we have adequately resolved our boundary layers.

@DaleKramer the nu value is taken directly from the fluid properties. It is the Kinematic Viscosity. You’ve got everything you need to make a nut/nu field using Paraview. I would love to see custom calculations in the post processing available in SimScale though. Also, it would be great if they would add a Line Interval Convolution (LIC) option to the slices.

Ahhhh! thanks, makes sense, should have realized that, dah, you know forest for the trees etc…

I see you have a new image :+1:

I wasn’t expecting this, at least it is low where we expect the most separation (sorta):

Yes somewhat disappointing. I have new results from my meshing experiments though and am rebuilding an even thinner mesh on the Thrush with 12 layers. It may fail though, as it ends up being a LOT of cells, but the results are very good. The smallest cells below are refinement level 8 and you can see the entire BL has been generated. The BL inflation algorithm really seems to like small cells whenever there is any curvature to the surface. Having a variable surface refinement and absolute BL sizing lets you do this without having an insanely large mesh.

Interestingly, I have found that the BL cells are best retained when you use an FLT ratio somewhat lower… if the small cells are too small it pukes too. I did a couple trials varying the max refinement level with absolute BL sizing enabled. I found good results if I went to one surface refinement level LOWER than your typical ratio, which IIRC was .30-.40. Here I’m .22 with surface refinement from 4-8.


Sorry, its late and I am a little confused. The absolute BL testing ended up being not as good so you went back to using lower FLT ratio ???

If so, I think that 0.3-0.4 FLT ratio range was simply my own derived range. It is good that you may be optimizing that… Although it is hard to stay too tight to it because FLT ratio changes so much from level to level. Intuitively a lower FLT ratio (larger size gradient) would seem to be expect worse sim results but perhaps a better layering (that is a way out there thought from a tired mind) ??

I am glad you are becoming such an expert at this :wink: Isn’t this frustrating but fun :slight_smile:

Yeah maybe a bit confusing. I found that while the layering algo liked smaller cells, that getting too small tended to disrupt their formation almost as much as being too coarse. The variable surface refinement lets it add detail where necessary, but I found that limiting the max surface refinement level to the next step below your 0.3-0.4 range gave the best results. In the above case we’re kind of in the middle, but your range would have recommended surface level 9 so I went with level 8.

I’m just about complete on the best mesh yet at about 15MM cells. Interestingly, I’m finding the more quality checks I just turn off the better it is and it still doesn’t fail the SimScale quality checks. Just now I took face twist from 0.0005 to -1 (turning it off) and my retained cells jumped by 7%.

1 Like

Very interesting, I did not much research on that, I just warned people that they were on their own with quality after you start changing the defaults :wink:

Check this baby out. Face twist off.

As I understand it 114 illegal faces is getting up where we should be concerned. I just try for 0 illegals (like Trump :wink: )

I have never figured out this newish and sometimes missing ‘Mesh Quality Metrics’ at the end…

Mesh quality metrics:
volumeRatio
min: 1
max: 2543.5148081883954
average: 1.9350681767938023
standard deviation 2.330299409787477
median: 1.1802326178923026
0-th percentile: 1
20-th percentile: 1.0036717141371905
40-th percentile: 1.0476639184279137
60-th percentile: 1.4999964640160461
80-th percentile: 1.74773126868174
100-th percentile: 2543.5148081883954

EDIT: At least I eventually just found this with a Google openfoam “volumeratio” search:

‘- VolumeRatio is a new metric, which computes the relative volume change between two adjacent cells’

AND further searching says it is from SnappyHexMesh.
aha…

1 Like

Which means that overall the mesh transition is good(looking at the 80th percentile) but at some places there is a big transition between big elements and small elements.

To shed some light on the percentile issue…

The volumeRatio measures ratio of volumes between each neighboring cells. (So for each mesh face, it measures the volume ratio between the two mesh cells that are adjacent to the face.)

So then each mesh has a lot of volume ratios. For each neighboring cells we get one ratio.

Since we have a set of volume ratios, we can compute some statistics. The min, max, average, standard deviation and median are the general statistics.

The percentiles are another way of representing the distribution of the volume ratios, also see:

Examples:

0th percentile: 1.00000018 - it means that 0% of all volume ratios is lower than 1.00000018 - so this is the same as the minimum - because no value is lower than minimum

80th percentile: 1.068 - it means that 80% of all volume ratios is lower than 1.068

Hope that makes sense. :slight_smile:

Jousef

1 Like

Thanks Jousef.

That statement relates the most to the issue I have with volumeRatio.

I am not sure of how each cell face has only two mesh cells adjacent to it, or of the definition of CFD adjacent cells, or of the definition or CFD neighboring cells

Maybe I have to get my head around the definition of adjacent cells in CFD terms.

In CFD terms, I believe that our cells have faces, edges and corner points that define them in our mind (3 items).

So, the combination of items that cells can share would be, pick 1, 2 or 3 from a group of 3 (7 permutations I think).

What permutation would CFD consider adjacent cells to be?

My simple brain relates the concept only to the most common use of adjacent, as in adjacent rooms. Which is the simple permutation of faces only, described as follows :wink: :

In adjacent room terms, I think that they are most commonly thought of as rooms that have a common wall (this common wall could have different dimensions for each room).

Although rooms that are on different floors would not commonly be considered adjacent, likely they would be if they had an access door in the ceiling or floor.

I also do not think that rooms that only share a common edge or point of a wall, would be considered adjacent, since even though there is some point/points in common, there would be no way to have a door in a common face large enough to have that secret rendezvous (without creating some sort of private additional room/hallway type structure :wink: ).

Wow, so much gymnastics to explain my issue… :slight_smile:

If I get all the above straight then maybe I can ‘see’ volumeRatio.

After all I think we need to ‘see’ things in our mind before we can describe them, use the concept wisely or even truly understand them… :wink:

I am pretty much a robot right now with my SimScaling but I am trying…

My interpretation of this for hexahedron meshes below. By this definition, each 3D cell will have six volume ratios.

@jousefm, I’m confused why volume ratio is a measure of quality. How does a high VR affect the solver? It is not surprising that there are some very high volume ratios in this mesh because undoubtedly there are some areas with my very tiny boundary layer inflated on level 4 surface refinement. Recall that I’m using a variable surface refinement which has resulted in a much more efficient mesh (~50% smaller than using only the highest level of refinement) while still maintaining good BL coverage.
Because I like pictures, here’s an example. Is this a bad thing?

The bigger question that keeps coming up for me is what fundamentally makes a good mesh? Lack of certain types of cells? Volume ratios? I keep eliminating quality checks and the BL gets better and it still passes. As in the last case, increasing numbers of “illegal” faces exist but for instance on the last mesh that’s 114 faces out of millions.

Are we sure that our meshes only create cells of 6 faces? (I thought I saw some that might be 4… maybe even 5)

Good point, looks like it allows a few others. Wikipedia has a good set of diagrams.

I think that Wikipedia is a little general, I was referring to our SnappHexMesh (with the parameters we use)

Naively I would expect a hexahedral mesh generator to stay within the space of legal hexahedrons as there would be a set of complete mathematics to describe each of them… but naivete is what got me to 1800 core hours and this CFD crash course for a “simple” project, so I’ll shut up now.

Again, that is general image in that it is just a single refinement level grid, if you add a grid of the next refinement level in it, there will be faces with 4 cells adjacent to them (and even weirder when there are cells with 5 and 4 faces :wink: )

My ‘logical’ mind does agree with that interpretation of ‘adjacent cells to a face’…

1 Like

No not naively… it is just that I have noticed that strict adherence to definitions is not always seen here (I think) :wink:

It is better to question than make wrong assumptions, even if it appears to be a stupid question (as you can see from my many stupid questions :wink: )