code: def inject(self, other):
          
          # check Series compatibility
          self.is_compatible(other)
          if (self.xunit == second) and (other.xspan[0] < self.xspan[0]):
              other = other.crop(start=self.xspan[0])
          if (self.xunit == second) and (other.xspan[1] > self.xspan[1]):
              other = other.crop(end=self.xspan[1])
          ox0 = other.x0.to(self.x0.unit)
          idx = ((ox0 - self.x0) / self.dx).value
          if not idx.is_integer():
              warn('Series have overlapping xspan but their x-axis values are '
                   'uniformly offset. Returning a copy of the original Series.')
              return self.copy()
          # add the Series along their shared samples
          slice_ = slice(int(idx), int(idx) + other.size)
          out = self.copy()
          out.value[slice_] += other.value
          return out
docs: Add two compatible `Series` along their shared x-axis values.
  
          Parameters
          ----------
          other : `Series`
              a `Series` whose xindex intersects with `self.xindex`
  
          Returns
          -------
          out : `Series`
              the sum of `self` and `other` along their shared x-axis values
  
          Raises
          ------
          ValueError
              if `self` and `other` have incompatible units or xindex intervals
  
          Notes
          -----
          If `other.xindex` and `self.xindex` do not intersect, this method will
          return a copy of `self`. If the series have uniformly offset indices,
          this method will raise a warning.
  
          If `self.xindex` is an array of timestamps, and if `other.xspan` is
          not a subset of `self.xspan`, then `other` will be cropped before
          being adding to `self`.
  
          Users who wish to taper or window their `Series` should do so before
          passing it to this method. See :meth:`TimeSeries.taper` and
          :func:`~gwpy.signal.window.planck` for more information.