code: def index(self, date):
          
          for (i, (start, end, ruler)) in enumerate(self.table):
              if start <= date.jd <= end:
                  return i
          return None
docs: Returns the index of a date in the table.