def get_inf_rate(mod_year):
    """
    Estimate infiltration rate in 1/h, dependend on last year of modernization.
    If no modernization has been performed, use year of construction instead.

    Parameters
    ----------
    mod_year : int
        Year of last modernization

    Returns
    -------
    inf_rate : float
        Infiltration rate in 1/h (related to building air volume)
    """

    if mod_year < 1951:
        inf_rate = 1
    elif mod_year < 1969:
        inf_rate = 0.5
    elif mod_year < 1982:
        inf_rate = 0.3
    elif mod_year < 1994:
        inf_rate = 0.25
    elif mod_year < 2001:
        inf_rate = 0.2
    elif mod_year < 2009:
        inf_rate = 0.15
    elif mod_year < 2014:
        inf_rate = 0.1
    else:
        inf_rate = 0.1

    return inf_rate