import math


def calc_slew_time(d_az, d_el, rate_az=0.5, rate_el=0.5):
    """Calculate slew time given a delta in azimuth aand elevation.
    """
    time_sec = max(math.fabs(d_el) / rate_el,
                   math.fabs(d_az) / rate_az)
    return time_sec