code: def get_distance_term(self, C, dists, rup):
          
          x_ij = dists.rrup
          # Get anelastic scaling term in quation 5
          if rup.ztor >= 50.:
              qslh = C["eSLH"] * (0.02 * rup.ztor - 1.0)
          else:
              qslh = 0.0
          # r_volc = np.copy(dists.rvolc)
          # r_volc[np.logical_and(r_volc > 0.0, r_volc <= 12.0)] = 12.0
          # r_volc[r_volc >= 80.0] = 80.0
          # Get r_ij - distance for geometric spreading (equations 3 and 4)
          c_m = min(rup.mag, self.CONSTANTS["m_c"])
          r_ij = x_ij + np.exp(C["alpha"] + C["beta"] * c_m)
          return C["gSL"] * np.log(r_ij) + \
              C["gLL"] * np.log(x_ij + 200.) +\
              C["eSL"] * x_ij + qslh * x_ij +\
              C["eSLV"] * dists.rvolc + C["gamma"]
docs: Returns the distance scaling term in equation 2a
  
          Note that the paper describes a lower and upper cap on Rvolc that
          is not found in the Fortran code, and is thus neglected here.