code: @Override
      @SuppressWarnings("unchecked")
      protected void fixup(int k) {
          if (onMinLevel(k)) {
              int p = k / 2;
              K kValue = array[k];
              if (p > 0 && ((Comparable<? super K>) array[p]).compareTo(kValue) < 0) {
                  array[k] = array[p];
                  array[p] = kValue;
                  fixupMax(p);
              } else {
                  fixupMin(k);
              }
          } else {
              int p = k / 2;
              K kValue = array[k];
              if (p > 0 && ((Comparable<? super K>) kValue).compareTo(array[p]) < 0) {
                  array[k] = array[p];
                  array[p] = kValue;
                  fixupMin(p);
              } else {
                  fixupMax(k);
              }
          }
      }
docs: Upwards fix starting from a particular element
  
  @param k
  the index of the starting element