AFTD Auto-Formalizing Theoretical Domains

timely_bin_is_valid

def

A timely bin b : TimelyBin is valid, written timely_bin_is_valid b, if for every item p ∈ b.items the packing time b.time satisfies p.arrival ≤ b.time ∧ b.time ≤ p.deadline, and the sum of sizes of items in b.items is at most 1.

Statement

def timely_bin_is_valid (b : TimelyBin) : Prop
Defined in
arXiv:2611.09611, Section 1.1
Verified
09 Nov 2026
Axioms
none listed
Built on 2
  • TimelyBinA structure TimelyBin representing a bin in timely bin packing, with fields items : Finset TimelyItem (the finite set of items packed…
  • TimelyItemA structure TimelyItem representing an item in online timely bin packing, with fields id : ℕ (a unique natural identifier),…
Used by 1
  • is_valid_timely_packingA finite set of bins P : Finset TimelyBin is a valid timely packing of an item set I : Finset TimelyItem, written…

Read back from the Lean

The property that a given TimelyBin b is valid, defined as the conjunction of two conditions: (1) for every item p in b.items, p.arrival ≤ b.time and b.time ≤ p.deadline; and (2) the sum of p.size over all items p ∈ b.items is less than or equal to 1.

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- A timely bin is valid if its packing time lies in every item's interval and total size is at most 1. -/
def timely_bin_is_valid (b : TimelyBin) : Prop :=
  (∀ p ∈ b.items, p.arrival ≤ b.time ∧ b.time ≤ p.deadline) ∧
  (∑ p ∈ b.items, p.size) ≤ 1
See it in the graphDiscuss this resultChallenge it