有谁能向我解释为什么同样的策略(毁灭)适用于同样的假设(双射f)在第一个引理中而不是在第二个引理中?另外,我应该做些什么来修复它呢?我想这与第二个引理中的混合支撑和类型有关,但我不明白这里到底发生了什么。提前谢谢你。
Require Import Setoid.
Definition injective {A B: Type} (f: A->B) :=
forall x y: A, f x = f y -> x = y.
Definition bijective {A B: Type} (f: A->B) :=
exists g: B->A, (forall x: A, g (f x) = x) /\ (forall y: B, f (g y) = y).
Definition decidable (t: Type): Type:=
(forall x y: t, {x=y}+{x<>y}).
Lemma bijective_to_injective:
forall t1 t2: Type,
forall f: t1 -> t2,
bijective f -> injective f.
Proof.
intros t1 t2 f H1.
destruct H1 as [g [H1 H2]]. (* <--- WORKS HERE *)
intros x y H3.
rewrite <- H1.
rewrite <- H1 at 1.
rewrite H3.
reflexivity.
Qed.
Lemma bijective_dec:
forall t1 t2: Type,
forall f: t1 -> t2,
bijective f ->
decidable t1 ->
decidable t2.
Proof.
intros t1 t2 f H1 H2 x y.
destruct H1 as [g [H1 H2]]. (* <--- DOESN´T WORK HERE *)
Qed.发布于 2017-04-13 21:20:19
实际上,您的问题是您需要为bijective提供一个所谓的“信息性定义”,也就是说,您可以在其中提取实际的证人,例如:
{ g: B -> A | cancel f g /\ cancel g f }https://stackoverflow.com/questions/43395845
复制相似问题