# What does 'Distortion' in the 'Mesh Analysis' panel do?

I have a few questions in regards to some of the options in the Mesh Analysis panel in the Properties panel in the 3D View. I pretty much understand all the different categories except for "Distortion". Can someone explain in detail the reason behind distortion and the varying "degrees" you can set the two options to right above "Samples (sample per face)? What do 'Minimum angle to display' and 'Maximum angle to display' do?

From Blender's Manual: Distortion

Distorted geometry can cause problems since the triangulation of a distorted n-gon is undefined.

Distortion is measured by faces which are not flat, with parts of the face pointing in different directions.

Let's examine simple four sided n-gon

Before 3d printing each n-gon is being converted to triangles. Our four sided n-gon can be triangulated in two ways marked with yellow and purple line:

On a complex model leaving non-planar (not flat) polygons can lead to triangulation in a way that is not desirable for the final product. 'Distortion' option can detect all n-gons which vertices don't lie on a plane (flat surface)

The color of those n-gons is defined by the minimum and maximum angle that the resulting triangles may form - blue for minimum angle and red for maximum angle with color transition in between.

If the polygon is flat the color will remain gray.

Here is an example of the same n-gon but with one vertex rotated at 5 degrees (minimum angle for detection) around polygons center:

Here the vertex is rotated at 30 degrees:

Here the vertex is rotated at 45 degrees (maximum angle for detection):

Any angle above maximum will color the n-gon red.

Now by looking at Monkey mesh, can you tell which polygons are not planar and which are most distorted?