This article describes a fast method to identify asphere which surfaces in a design will best benefit from aspherization.
The example file shows a derivative of the Cooke triplet, optimized for best RMS wavefront error. All radii and thicknesses are variable, except the last radius of curvature which is controlled by an F/# solve and maintains the lens as f/5 during optimization.
The tool allows us to choose start and stop surfaces, and the maximum order of the selected polynomial. Each surface within the range is evaluated to see if it is a candidate asphere. To be considered, the surface must be of type Standard, have no conic value, define a boundary between air and glass (cemented surfaces usually make poor aspheres), and have a curvature that is either variable or controlled by a marginal ray angle or F/# solve. Surfaces that do not meet this test are ignored.
Reference Source: https://www.zemax.com/