Build the idea in three steps
- A Solution’ is a hypothetical generalized solution bundled as one object: the numbers a, b, c, the unit u, the λ-divisibility conditions, the coprimality, and the equation H stored as a field.
- A Solution is the same tuple with one extra line: λ ^ 2 ∣ a + b. Neighboring lemmas of this file send any Solution’ to a Solution with the same multiplicities.
- Rank hypothetical solutions by the natural-number multiplicity of λ in c. If at least one solution exists, Solution.exists_minimal selects one of least rank. It does not assert that a solution exists without that assumption.
A small example
Rank the suspects by their record: among all hypothetical solutions, choose one whose λ-count in c is smallest. If the story can always produce a strictly smaller count, the smallest record cannot exist at all.