Open palmskog opened 1 month ago
Note that the second formalization doesn't seem quite correct to me. It deprives the contestant of determining that the set of solutions is a singleton. Should probably rather be something like this:
Definition putnam_1963_b1_solution (i : int) : Prop := i = 2.
Theorem putnam_1963_b1 (R : realType) (a : int) :
(('X^2 - 'X + a%:~R) : {poly R}) %| ('X^13 + 'X + 90) <-> putnam_1963_b1_solution a.
@LasseBlaauwbroek you're probably right, I was just aiming for a straight translation of the original Coq statement to idiomatic MathComp Analysis. Another orthogonal question is definitely whether an idiomatic Coq statement captures the mathematical English meaning (I wish those were kept more accessible outside a JSON).
Edit: Moved to #195 to keep concerns separate.
Hi Karl,
Thank you for the feedback! We are going to begin migrating the Coq formalizations to depend mostly on Mathcomp shortly. I think this way we'll get the formalizations to be more idiomatic (maybe not perfect) and smooth out any kinks as we proceed. Thanks for providing some examples as well, it is a helpful starting point.
A set of modified formalizations from years 1979 and 1980 appears in #201. Idiomaticity-wise, what do you think? Most have been changed to rely on mathcomp. I am particularly interested in any common shortcuts that we missed which could be used in the formalizations.
A further set of modified formalizations from years 1973 to 1978 appears in #211. Let me know if you have any comments.
I've looked through several of the Coq formalizations, and one problem I see is the mixing of modules and idioms from different overlapping libraries, such as Coq's Stdlib, Coquelicot, and MathComp Analysis. It's likely that nonidiomatic use of libraries will make it difficult for both humans and AI to solve a problem.
The best solution would likely be to focus on formalizing as many problems as possible using MathComp Analysis, which together with other MathComp libraries comprise a unfied Coq library of mathematics comparable to Lean's Mathlib, as described in #190. MathComp Analysis likely contains a superset of the results concerning reals in Coquelicot and Stdlib. When using MathComp, it's customary to avoid explicitly using Stdlib, e.g., one uses the MathComp type
int
instead ofZ
.I give two examples of what I believe are idiomatic statements using MathComp Analysis. Since I nearly always use regular MathComp without reals, there is no guarantee that this is fully idiomatic, but it may still get the ideas across.