Skip to Content.
Sympa Menu

coq-club - Re: [Coq-Club] Doubt about In

coq-club AT inria.fr

Subject: The Coq mailing list

List archive

Re: [Coq-Club] Doubt about In


Chronological Thread 
  • From: Saulo Araujo <saulo2 AT gmail.com>
  • To: coq-club AT inria.fr
  • Subject: Re: [Coq-Club] Doubt about In
  • Date: Mon, 22 Feb 2016 14:37:17 -0300
  • Authentication-results: mail3-smtp-sop.national.inria.fr; spf=None smtp.pra=saulo2 AT gmail.com; spf=Pass smtp.mailfrom=saulo2 AT gmail.com; spf=None smtp.helo=postmaster AT mail-qg0-f44.google.com
  • Ironport-phdr: 9a23:/wmXShG3RNUf0IdBpEvO4J1GYnF86YWxBRYc798ds5kLTJ75pMiwAkXT6L1XgUPTWs2DsrQf27WQ7vyrADRbqb+681k8M7V0HycfjssXmwFySOWkMmbcaMDQUiohAc5ZX0Vk9XzoeWJcGcL5ekGA6ibqtW1aJBzzOEJPK/jvHcaK1oLsh7/0psGYOl0TzBOGIppMbzyO5T3LsccXhYYwYo0Q8TDu5kVyRuJN2GlzLkiSlRuvru25/Zpk7jgC86l5r50IAu3GePEzSqUdBzA7OUg04tfqvF/NV1ih/HwZB14fjx5PSyHf5Qz4Wd+lqSLnsu0n8CafNMzyC7szXGLxvO9QVBb0hXJfZHYC+2bNh5kogQ==

I accidentally sent the previous email before finishing it. I am seding it again, now complete.

Hi,

I am in the middle of a proof in which I need the following theorem:

Theorem strong_in_inv:
  forall E (l: list E) e f,
    In f (e :: l) -> e = f \/ (e <> f /\ In f l).

Unfortunately, I was not able to complete the proof below:

Proof.
  intros.
  simpl in H.
  destruct H.
  {
    left.
    apply H.
  }
  {
    right.
    split.
    {
(* I am stuck here! *)
    }
    {
      apply H.
    }
  }
Qed.

I starting to wonder that one cannot prove this theorem because the definition of In is too weak. Is there a reason for not defining In like below:

Fixpoint contains E (l: list E) e :=
  match l with
  | [] => False
  | e' :: l' => e' = e \/ (e' <> e /\ contains l' e)
  end.

Any help will be greatly appreciated,
Saulo

On Mon, Feb 22, 2016 at 2:27 PM, Saulo Araujo <saulo2 AT gmail.com> wrote:
Hi,

I am in the middle of a proof in which I need the following theorem:

Theorem strong_in_inv:
  forall E (l: list E) e f,
    In f (e :: l) -> e = f \/ (e <> f /\ In f l).

Unfortunately, I was not able to complete the proof below:

Proof.
  intros.
  simpl in H.
  destruct H.
  {
    left.
    apply H.
  }
  {
    right.
    split.
    {
(* I am stuck here! *)
    }
    {
      apply H.
    }
  }
Qed.





Archive powered by MHonArc 2.6.18.

Top of Page