Undulation of the geoid is the mathematical process of determining the height in meters above the geoid (relative to the mean sea level) from the height provided by the GPS system which uses the (WGS84) ellipsoid as reference. In maps and common use the height over the mean sea level is used to indicate the height of elevations while the ellipsoidal height results from the restrictions that apply for the GPS system.
The process of the undulation it is not standardised, as different countries use different mean sea levels as reference but mostly refers to the EGM96 geoid. Calculating the undulation factor is mathematically challenging. This is why many handheld GPS receivers have built in undulation lookup tables to determine the height above sea level.
The deviation between the ellipsodidal height and the normal height can be calculated by