Hi all, I am working on the following proof (independently of the meaning):
Section Property.
Hypothesis Helper: forall A, A \/ ~A.
Hypothesis Hypn : exists n : nat, True.
Variable P : nat -> Prop.
Theorem test : exists n : nat, (P n -> forall m : nat, P m).
Proof.
destruct Hypn as [n T].
exists n.
assert (H : (P n -> forall m : nat, P m) \/ ~(P n -> forall m : nat, P m)).
{ apply Helper. }
destruct H as [H1 | H2].
+ exact H1.
+
Admitted.
End Property.
In the second bullet of the destruct Hex, I can clearly see a contradiction between my hypothesis H2 and the goal, unfortunately I don’t know how to proceed to conclude the proof (still a beginner sorry).
Any help please (or explanation on the way to solve it).
Thanks!
For future people who might find it helpful, here is how I solved it, it was not the theorem, just a trick in the proof to get the contradiction.
Theorem test : exists n : nat, (P n -> forall m : nat, P m).
Proof.
destruct Hypn as [n T].
assert (Hn : (forall z : nat, P z) \/ ~((forall z : nat, P z))).
{ apply Helper. }
destruct Hn as [H1 | H2].
- exists n.
intros _.
exact H1.
- assert (Hz : exists z, ~P z).
{
apply not_all_ex_not.
exact H2.
}
destruct Hz as [z H_not_z].
exists z.
intros Hz.
contradiction.
Qed.