A generalized reflector/array surface compensation algorithm for gain and sidelobe control