Closed nateyazdani closed 4 years ago
Linking to #39 also
All requests for changes have been addressed, with the exception of the naming scheme and a line in the example script; I asked follow-up questions in reply to those comments.
All tests pass.
Ah, it seems that I've let this linger too long, and there are now merge conflicts. They're pretty innocuous, so I'll leave them be for now, in case you'd like to inspect.
Yeah, don't bother trying the merge, I'll do it once everything is addressed
All done with requested changes! After switching the initial retraction name back to ${ornament}_retraction
, I used ${ornament}_retraction_adjoint
for the adjointified version.
LGTM, I will take over and try the merge.
Thanks for the great work!!
This PR pulls in Jasper's HoTT module for adjointifying equivalences and applies its generic lemmas when equivalence-proving is enabled. The module is placed at
theories/Adjoint.v
.For an ornament named
${ornament}
, this feature instantiates Jasper'sfg_id'
(to adjointify retraction) as${ornament}_retraction
andf_adjoint
(to prove adjunction) as${ornament}_adjunction
.The initial retraction proof (which is an input to the previous two lemmas) is now generated as
${ornament}_retraction0
to prevent a name collision. To actually benefit from the adjunction theorem, rewritings need to use the adjointified retraction lemma, hence the preferential naming scheme.The test script (
test.sh
) passes successfully.Some potential design concerns:
Adjoint.v
module translated to use Ltac proof scripts instead of terms?refold_retraction
inExample.v
does not hold, though a different proof could plausibly work).If satisfactory, this feature would resolve issue #57.