Debian Codegraph @

test-suite/bugs/bug_4097.v

raw
1 Require Import TestSuite.admit.
2 (* File reduced by coq-bug-finder from original input, then from 6082 lines to 81 lines, then from 436 lines to 93 lines *)
3 (* coqc version 8.5beta1 (February 2015) compiled on Feb 27 2015 15:10:37 with OCaml 4.01.0
4 coqtop version cagnode15:/afs/csail.mit.edu/u/j/jgross/coq-8.5,v8.5 (fc1b3ef9d7270938cd83c524aae0383093b7a4b5) *)
5 Global Set Primitive Projections.
6 Record sigT {A} (P : A -> Type) := exist { projT1 : A ; projT2 : P projT1 }.
7 Arguments projT1 {A P} _ / .
8 Arguments projT2 {A P} _ / .
9 Notation "{ x : A & P }" := (sigT (fun x:A => P)) : type_scope.
10 Delimit Scope path_scope with path.
11 Delimit Scope fibration_scope with fibration.
12 Open Scope path_scope.
13 Open Scope fibration_scope.
14 Notation "( x ; y )" := (exist _ _ x y) : fibration_scope.
15 Notation pr1 := projT1.
16 Notation pr2 := projT2.
17 Notation "x .1" := (pr1 x) : fibration_scope.
18 Notation "x .2" := (pr2 x) : fibration_scope.
19 Inductive paths {A : Type} (a : A) : A -> Type := idpath : paths a a.
20 Arguments idpath {A a} , [A] a.
21 Notation "x = y :> A" := (@paths A x y) : type_scope.
22 Notation "x = y" := (x = y :>_) : type_scope.
23 Definition inverse {A : Type} {x y : A} (p : x = y) : y = x
24 := match p with idpath => idpath end.
25 Definition concat {A : Type} {x y z : A} (p : x = y) (q : y = z) : x = z :=
26 match p, q with idpath, idpath => idpath end.
27 Notation "p @ q" := (concat p%path q%path) (at level 20) : path_scope.
28 Notation "p ^" := (inverse p%path) (at level 3, format "p '^'") : path_scope.
29 Definition transport {A : Type} (P : A -> Type) {x y : A} (p : x = y) (u : P x) : P y :=
30 match p with idpath => u end.
31 Notation "p # x" := (transport _ p x) (right associativity, at level 65, only parsing) : path_scope.
32 Definition ap {A B:Type} (f:A -> B) {x y:A} (p:x = y) : f x = f y
33 := match p with idpath => idpath end.
34 Definition apD {A:Type} {B:A->Type} (f:forall a:A, B a) {x y:A} (p:x=y):
35 p # (f x) = f y
36 :=
37 match p with idpath => idpath end.
38 Lemma transport_compose {A B} {x y : A} (P : B -> Type) (f : A -> B)
39 (p : x = y) (z : P (f x))
40 : transport (fun x => P (f x)) p z = transport P (ap f p) z.
41 admit.
42 Defined.
43 Generalizable Variables X A B C f g n.
44 Definition pr1_path `{P : A -> Type} {u v : sigT P} (p : u = v)
45 : u.1 = v.1
46 := ap pr1 p.
47 Notation "p ..1" := (pr1_path p) (at level 3) : fibration_scope.
48 Definition pr2_path `{P : A -> Type} {u v : sigT P} (p : u = v)
49 : p..1 # u.2 = v.2
50 := (transport_compose P pr1 p u.2)^
51 @ (@apD {x:A & P x} _ pr2 _ _ p).
52 Notation "p ..2" := (pr2_path p) (at level 3) : fibration_scope.
53 Definition path_path_sigma_uncurried {A : Type} (P : A -> Type) (u v : sigT P)
54 (p q : u = v)
55 (rs : {r : p..1 = q..1 & transport (fun x => transport P x u.2 = v.2) r p..2 = q..2})
56 : p = q.
57 admit.
58 Defined.
59 Set Debug Unification.
60 Definition path_path_sigma {A : Type} (P : A -> Type) (u v : sigT P)
61 (p q : u = v)
62 (r : p..1 = q..1)
63 (s : transport (fun x => transport P x u.2 = v.2) r p..2 = q..2)
64 : p = q
65 := path_path_sigma_uncurried P u v p q (r; s).