
theorem NF807:
  for a being non empty positive at_most_one FinSequence of REAL,
  h being non empty FinSequence of NAT* st
  h = OnlinePackingHistory(a, NextFit(a)) holds
  (for i, k being Nat st
  1 <= i & i <= len a & rng (h . i) = Seg k holds (h . i) . i = k)
  proof
    let a be non empty positive at_most_one FinSequence of REAL,
        h be non empty FinSequence of NAT*;

    assume HN00: h = OnlinePackingHistory(a, NextFit(a));

    let i, k be Nat;

    assume that
    L410: 1 <= i and
    L415: i <= len a and
    L417: rng (h . i) = Seg k;

    consider k0 being Nat such that
    L427: rng (h . i) = Seg k0 and
    L428: (h . i) . i = k0 by HN00,L410,L415,NF805;

    thus thesis by L417,L427,FINSEQ_1:6,L428;
  end;
