0

This question is probably trivial, but I'm stuck on it since yesterday and I couldn't find the relevant keyword to search for.

Consider the following:

Fixpoint mfp (t: nat*nat) := fst t.

Lemma ml: forall (t: nat*nat), mfp t = fst t.
Proof.
  intros.
  unfold mfp.
  (* substitute t0 with t in lhs *)
  reflexivity.
Qed.

After unfolding mfp, I have to prove (fix mfp (t0 : nat * nat) : nat := fst t0) t = fst t which trivially holds, yet I don't know how to tell Coq "Do the substitution of t0 by t".

Do you know how to do that substitution ?

Bromind
  • 1,065
  • 8
  • 23
  • 2
    `destruct t` would trigger computation in this case. Is this a minimized example? Because `Definition mfp (t: nat*nat) := fst t.` would let you get rid of that `destruct`. – Anton Trunov Sep 18 '18 at 10:04
  • `destruct` works in my case thanks :-) . Yes, I wrote a `Fixpoint` instead of `Definition` because this is minimized. – Bromind Sep 19 '18 at 07:22

0 Answers0