ST_Simplify(g, max_distance)

Simplifies a geometry using the Douglas-Peucker algorithm and returns a
simplified value of the same type, or NULL if any argument is NULL.

The geometry may be any geometry type, although the Douglas-Peucker
algorithm may not actually process every type. A geometry collection is
processed by giving its components one by one to the simplification
algorithm, and the returned geometries are put into a geometry
collection as result.

The max_distance argument is the distance (in units of the input
coordinates) of a vertex to other segments to be removed. Vertices
within this distance of the simplified linestring are removed. An
ER_WRONG_ARGUMENTS error occurs if the max_distance argument is not
positive, or is NaN.

According to Boost.Geometry, geometries might become invalid as a
result of the simplification process, and the process might create
self-intersections. If you want to check the validity of the result,
pass it to ST_IsValid().

An ER_GIS_INVALID_DATA error occurs if the geometry argument is not a
valid geometry byte string.

URL: http://dev.mysql.com/doc/refman/5.7/en/spatial-convenience-functions.html

