def calculate_far(delta, it_algorithm):
    """
    Calculate the optimal False Acceptance Rate for a given indeterminacy.

    Parameters
    ----------
    delta : float
        The indeterminacy, m / n, of a system of equations of size m x n.
    it_algorithm : {IHT, ITS}
        The iterative thresholding algorithm to calculate the FAR for.

    Returns
    -------
    FAR : float
        The optimal False Acceptance Rate for the given indeterminacy.

    Notes
    -----
    The optimal False Acceptance Rate to be used in connection with the
    interference heuristic presented in the paper "Optimally Tuned Iterative
    Reconstruction Algorithms for Compressed Sensing" [1]_ is calculated from
    a set of optimal values presented in the same paper. The calculated value
    is found from a linear interpolation or extrapolation on the known set of
    optimal values.

    References
    ----------
    .. [1] A. Maleki and D.L. Donoho, "Optimally Tuned Iterative Reconstruction
       Algorithms for Compressed Sensing", *IEEE Journal Selected Topics in
       Signal Processing*, vol. 3, no. 2, pp. 330-341, Apr. 2010.

    """

    # Known optimal values (x - indeterminacy / y - FAR)
    x = [0.05, 0.11, 0.21, 0.41, 0.50, 0.60, 0.70, 0.80, 0.93]
    if it_algorithm == 'IHT':
        y = [0.0015, 0.002, 0.004, 0.011, 0.015, 0.02, 0.027, 0.035, 0.043]
    else:
        y = [0.02, 0.037, 0.07, 0.12, 0.16, 0.2, 0.25, 0.32, 0.37, 0.42]

    i = next((i for i in range(len(x) - 1) if delta <= x[i + 1]), len(x) - 2)

    FAR = y[i] + (delta - x[i]) * (y[i + 1] - y[i]) / (x[i + 1] - x[i])

    return FAR