Simplex noise

Ken Perlin designed the algorithm in 2001[1] to address the limitations of his classic noise function, especially in higher dimensions.

For higher dimensions, n-spheres around n-simplex corners are not densely enough packed, reducing the support of the function and making it zero in large portions of space.

Simplex noise is most commonly implemented as a two-, three-, or four-dimensional function, but can be defined for any number of dimensions.

An implementation typically involves four steps: coordinate skewing, simplicial subdivision, gradient selection, and kernel summation.

The resulting coordinate (x', y', ...) is then used in order to determine which skewed unit hypercube cell the input point lies in, (xb' = floor(x'), yb' = floor(y'), ...), and its internal coordinates (xi' = x' − xb', yi' = y' − yb', ...).

Each simplex vertex is added back to the skewed hypercube's base coordinate and hashed into a pseudo-random gradient direction.

The contribution from each of the n + 1 vertices of the simplex is factored in by a summation of radially symmetric kernels centered around each vertex.

This unskewed displacement vector is used for two purposes: From there, each vertex's summed kernel contribution is determined using the expression where r2 is usually set to either 0.5 or 0.6: the value 0.5 ensures no discontinuities, whereas 0.6 may increase visual quality in applications for which the discontinuities are not noticeable; 0.6 was used in Ken Perlin's original reference implementation.

Simplex noise