def rect_radius(ellipsoid):
    """
    Computes the Rectifying Radius of an Ellipsoid with specified Inverse
    Flattening (See Ref 2 Equation 3)
    :param ellipsoid: Ellipsoid Object
    :return: Ellipsoid Rectifying Radius
    """
    nval = 1 / float(ellipsoid.inversef) / (2 - 1 / float(ellipsoid.inversef))
    nval2 = nval ** 2
    return ellipsoid.semimaj / (1 + nval) * ((nval2 * (nval2 * (nval2 * (25 *
        nval2 + 64) + 256) + 4096) + 16384) / 16384.0)
