Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] Computation and proofs over proof objects | How to prove that two proofs objects are equal?

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] Computation and proofs over proof objects | How to prove that two proofs objects are equal?


Chronological Thread 
  • From: Cao Qinxiang <caoqinxiang AT gmail.com>
  • To: coq-club AT inria.fr
  • Subject: Re: [Coq-Club] Computation and proofs over proof objects | How to prove that two proofs objects are equal?
  • Date: Wed, 24 Apr 2019 22:54:39 +0800
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None smtp.pra=caoqinxiang AT gmail.com; spf=Pass smtp.mailfrom=caoqinxiang AT gmail.com; spf=None smtp.helo=postmaster AT mail-ot1-f53.google.com
  • Ironport-phdr: 9a23:sdpE6BTLy3LqMmLAdaPPaqpvbdpsv+yvbD5Q0YIujvd0So/mwa69ZBON2/xhgRfzUJnB7Loc0qyK6vmmBDVLuMfJmUtBWaQEbwUCh8QSkl5oK+++Imq/EsTXaTcnFt9JTl5v8iLzG0FUHMHjew+a+SXqvnYdFRrlKAV6OPn+FJLMgMSrzeCy/IDYbxlViDanbr5+MQi6oR/Ru8ULjoduN6I8wQbVr3VVfOhb2XlmLk+JkRbm4cew8p9j8yBOtP8k6sVNT6b0cbkmQLJBFDgpPHw768PttRnYUAuA/WAcXXkMkhpJGAfK8hf3VYrsvyTgt+p93C6aPdDqTb0xRD+v4btnRAPuhSwaMTMy7WPZhdFqjK9Drx2hqR5wzY7abo+WKfRwYL/ScMgASmZdRMtcTTBNDp++YoYJEuEPPfxYr474p1YWsxaxHw6sD/70xD9JgH/30qw63P4nEQHJwQctGM4Bv27TrNXsNacSV++0zKjSwjXFYPNbwjj96I3SfRAgpfGAR65/cc3UyUQ2EQ7Ok1aeqZT9Mj+LyugAt3KX4ulgWO61lWIrth19riKvy8oijITCm5gbxUre9SpjxYY4Pd24R1B/Yd6jCJZQsjuVN4pyQs87RGFopDs2xqQIuZO7ciUG0psnxxnYa/yId4iH/AjvW/qWITd9nH5lebS/iAiu8UW41OHwSs253ExJoydFiNXAqG0B2wDJ5sWHRPZx5kKh1iyO1wDX5OFEO0c0la/DJpE92LEwkYMTsUXFHi75mUX5lqmWdko/9+in7uToeLTmppuGO4BojQH+N7wimtajDuQgLggOQ2+b9Pyg273k5E31WalFjvkrkqbCq53aPsQapquhAwBPyIoj6hC/Dy2n0NsCh3UHIkhFK1q7iN3iPEiLK/TlB9++hU6tmXFl3aPoJLrkV77EKTD6kbHxfL975AYIwwM01NFZ95NdDL4pL/f6W0u3v9vdWExqezeoyvrqXY0unrgVXniCV/fAbPHi9GSQ7+dqGNGiIZcPsW+kefcg7v/qy3Q+nA1FJPj77d4scHm9W89eDQCcaHvojM0GFD5T7AU7Re3uzlaFVGwKPivgb+cH/jg+TbmeI8LDS4Sq2uHT2S66GthRejkDBA3XV3jvcIqAVrEHbyfAesI=

A short answer is: when you prove [introTF], use [Defined] instead of [Qed].

Another suggestion: try to avoid proving an equality between two proof terms. :)


Qinxiang Cao
Shanghai Jiao Tong University, John Hopcroft Center
Room 1110-2, SJTUSE Building
800 Dongchuan Road, Shanghai, China, 200240



On Wed, Apr 24, 2019 at 10:28 PM Benoît Viguier <beviguier AT gmail.com> wrote:

Dear all,

I have a type defined in the following kind:

  Definition oncurve (p : point K) := (
    match p with
    | EC_Inf    => true
    | EC_In x y => M#b * y^+2 == x^+3 + M#a * x^+2 + x
    end).

  Inductive mc : Type := MC p of oncurve p.

  Coercion point_of_mc p := let: MC p _ := p in p.
    

and at some point I am trying to prove that :

MC p (proof_of p) = MC p (another_proof_of p).
    Reflexivity do not work in this case because : (proof_of_p p) and
    (another_proof_of p) while being the same in some senses are not the
    same object.

However by doing f_equal, the goal becomes:

proof_of p = another_proof_of p

    

I can unfold both of them and the subsequent definitions, applying a compute leads me to the following state:

match
  match
    introTF (c:=true) idP
      (equivPif idP (fun _view_subject_ : true = true => _view_subject_)
         (fun _view_subject_ : true = true => _view_subject_)) in 
    (_ = y) return (y = true)
  with
  | Logic.eq_refl => Logic.eq_refl
  end in (_ = y) return (y = true)
with
| Logic.eq_refl =>
    match
      introTF (c:=true) idP
        (equivPif idP (fun _view_subject_ : true = true => _view_subject_)
           (fun _view_subject_ : true = true => _view_subject_)) in 
      (_ = y) return (y = true)
    with
    | Logic.eq_refl => Logic.eq_refl
    end
end = is_true_true

    

Thus my question would be is there anyway to un-opaque those last part ? It says that introTF is defined as Opaque, thus Transparent does not go through either. How can I proceed forward?

From which I cannot work further as introTF etc are opaque. Is there any other way I can prove my equality?

Thanks a lot for any help or insight you can provide me with.

Kind Regards,

Benoit Viguier.




Archive powered by MHonArc 2.6.18.

Top of Page