def apply_extinction_correction(f_calc, wavelength, extinction_correction_x=0):
    """
    Routine to apply additional extinction correction
    Parameters
    -----------
    f_calc : cctbx.miller.array
        Array of hkl, and structure factor values
    wavelength: float
        Measurement wavelength in angstroms
    extinction_correction_x: float
        value for shelx extinction correction

    Returns
    ----------
    f_calc : cctbx.miller.array
        Updated array of hkl, and structure factor values
    """
    if extinction_correction_x:
        f_calc.apply_shelxl_extinction_correction(extinction_correction_x, wavelength)
    return f_calc