def savirre(b4, b5, b8, a=0.4, L=0.5):
    """
    Soil-Adjusted Vegetation Index with red and red-edge \
    (Vincent, Kumar, and Upadhyay, 2020).

    .. math:: top = (1 + L) * (b8 - (a * b4 + (1 - a) * b5))
    bottom = b5 + L + (a * b4 + (1 - a) * b5)

    SAVIRRE = top / bottom

    :param b4: Red.
    :type b4: numpy.ndarray or float
    :param b5: Red-edge 1.
    :type b5: numpy.ndarray or float
    :param b8: NIR.
    :type b8: numpy.ndarray or float

    :returns SAVIRRE: Index value

    .. Tip::
        L is a variable. Its values range within -1 to 1, depending on the \
        amount of green vegetation present in the area. To run the remote \
        sensing analysis of areas with high green vegetation, L is set to \
        zero (in which case SAVI index data will be equal to NDVI); whereas \
        low green vegetation regions require L=1.
        The value of L varies by the amount or cover of green vegetation: in \
        very high vegetation regions, L=0; and in areas with no green \
        vegetation, L=1. Generally, an L=0.5 works well in most situations \
        and is the default value used.

    .. Tip::

       Vincent, A., Kumar, A., Upadhyay, P. 2020. Effect of Red-Edge \
       Region in Fuzzy Classification: A Case Study of Sunflower Crop. \
       Journal of the Indian Society of Remote Sensing 1-13. \
       doi:10.1007/s12524-020-01109-4.

    """

    top = (1 + L) * (b8 - (a * b4 + (1 - a) * b5))
    bottom = b5 + L + (a * b4 + (1 - a) * b5)

    SAVIRRE = top / bottom
    return SAVIRRE