The Root Mean Square (RMS) Roughness parameter, Sq, is the root mean square of the surface departures from the mean plane within the sampling area. The digital equation that represents this algorithm is displayed below.
where M is the number of columns in the surface and N is the number of rows in the surface.
Sq is very general and is an often used parameter. In the field of statistics, it is the sample standard deviation.