Comment: Hypothesis Subsumption with pointwise
The rule is
  x:A, J ⊢ ext t

  BY hypothesis_subsumption #$i ()
  
  H  ⊢ B ⊆A
  x:A, J ⊢ x ∈ B
  x:B, J ⊢ ext t

(Note that from this rule we can derive the rule hyp_replacement
 so that rule could be removed if we rewrite few tactics.)

Here is the proof that the rule is correct (using pointwise functionality)
  Let Gamma_A be the hypotheses  x:A J,  and Gamma_B be  x:B J.
  Let be substitution for the variables declared in Gamma.
  substitution s' "agrees with mod Gamma" if for each v:T in Gamma,
   s'(v) s(v) \in s(T)

  satisfies Gamma if for each v:T in Gamma
  s(v) in s(T)  and  for any s' that agrees with mod Gamma, 
  s'(T) s(T) in some universe Ui.

  satisfies the conclusion (C ext t) if
  s(t) in s(C) and for any s' that agrees with mod Gamma,
  s'(C) s(C) in some universe

  sequent is true if every that satisfies its hyps also
  satisfies its concl.
 
  Assuming that the three subgoal sequents are true we must show that
  if satisfies Gamma_A then satisfies (C ext t)

   Since x:B, J ⊢ ext is assumed true, it is enough to show
   satisfies Gamma_B.

   Since satisfies Gamma_A, it is enough to show that
   1) s(x) in s(B)  and 
   2) for any s' that agrees with mod Gamma_B,  for each v:T in Gamma_B 
      s'(T) s(T) in some universe.

   From the truth of x:A, J ⊢ x ∈ B  we get
    Ax \in s(x ∈ B) 
    and for any s' that agrees with mod Gamma
    s'(x ∈ B) s'(x ∈ B) in some universe

  The first of these implies that s(x) \in s(B), so we have 1)
  For 2) it is enough to show that if s' agrees with mod Gamma_B
         then s' agrees with mod Gamma_A
         and s'(B) s(B) in some universe

  For that, suppose s' agrees with mod Gamma_B. Then s' agrees with mod H
  so since H  ⊢ B ⊆is true,
    Ax \in s(B ⊆A) and s'(B ⊆A) s(B ⊆A) in some universe

  The second of these implies that s'(B) s(B)
  and the first implies that since s'(x) s(x) \in s(B) then
   s'(x) s(x) \in s(A), so s' agrees with mod Gamma_A

  .
  QED  
.






 ⋅

Comment: Hypothesis Subsumption with pairwise
In pairwise functionality, the rule is simpler than in pointwise functionality
since we don't need to prove H  ⊢ B ⊆A.
The rule becomes:
  x:A, J ⊢ ext t

  BY hypothesis_subsumption #$i ()
  
  x:A, J ⊢ x ∈ B
  x:B, J ⊢ ext t

Here is the proof:
  Let Gamma be the hypotheses  x:A J,  and Gamma' be  x:B J.
  Let s1, s2 be substitutions for the variables declared in Gamma.

  The pair s1,s2 satisfies Gamma if for each v:T in Gamma
  s1(v) s2(v) in s1(T)  and  s1(T) s2(T) in some universe Ui.

  The pair s1,s2 satisfies the conclusion (C ext t) if
  s1(t) s2(t) in s1(C) and  s1(C) s2(C) in some universe

  sequent is true in pairwise functionality
  if every pair s1,s2 that satisfies its hyps also
  satisfies its concl.
 
  Assuming that the two subgoal sequents are true (in pairwise functionality) 
  we must show that
  if s1,s2 satisfies Gamma then s1,s2 satisfies (C ext t)

   Since x:B, J ⊢ ext is assumed true, it is enough to show
   s1,s2 satisfies Gamma'.

   Since s1,s2 satisfy Gamma, it is enough to show that
   s1(x) s2(x) in s1(B)  and  s1(B) s2(B) in some universe.

   From the truth of x:A, J ⊢ x ∈ B  we get
    Ax \in s1(x ∈ B) and s1(x ∈ B) s2(x ∈ B) in some universe

  This implies that  s1(x) s2(x) in s1(B) and that
        s1(B) s2(B) in that universe .
  QED  
.






 ⋅

Lemma: sq_stable__subtype_rel
[A,B:Type].  SqStable(A ⊆B)

Lemma: subtype_rel_universe1
Type ⊆r 𝕌'

Lemma: subtype_rel_universe2
Type ⊆r 𝕌''

Lemma: subtype_rel_function
[A,B,C,D:Type].  ((A ⟶ B) ⊆(C ⟶ D)) supposing ((B ⊆D) and (C ⊆A))

Lemma: subtype_rel_dep_function
[A:Type]. ∀[B:A ⟶ Type]. ∀[C:Type]. ∀[D:C ⟶ Type].
  ((a:A ⟶ B[a]) ⊆(c:C ⟶ D[c])) supposing ((∀a:C. (B[a] ⊆D[a])) and (C ⊆A))

Lemma: subtype_rel_product
[A:Type]. ∀[B:A ⟶ Type]. ∀[C:Type]. ∀[D:C ⟶ Type].
  ((a:A × B[a]) ⊆(c:C × D[c])) supposing ((∀a:A. (B[a] ⊆D[a])) and (A ⊆C))

Lemma: subtype_rel_image
[A,B:Type]. ∀[f:Base].  Image(A,f) ⊆Image(B,f) supposing A ⊆B

Lemma: subtype_rel_tunion
[A:Type]. ∀[B:A ⟶ Type]. ∀[C:Type]. ∀[D:C ⟶ Type].
  (⋃a:A.B[a] ⊆r ⋃c:C.D[c]) supposing ((∀a:A. (B[a] ⊆D[a])) and (A ⊆C))

Lemma: subtype_rel_simple_product
[A,B,C,D:Type].  ((A × B) ⊆(C × D)) supposing ((B ⊆D) and (A ⊆C))

Lemma: subtype_rel_union
[A,B,C,D:Type].  ((A B) ⊆(C D)) supposing ((B ⊆D) and (A ⊆C))

Lemma: subtype_rel_dep_product_iff
[A:Type]. ∀[B:A ⟶ Type]. ∀[C:Type]. ∀[D:C ⟶ Type].
  uiff(∀[a:A]. (B[a] ⊆D[a]);(a:A × B[a]) ⊆(c:C × D[c])) supposing A ⊆C

Lemma: subtype_rel_sum
[A,B,C,D:Type].  ((A B) ⊆(C D)) supposing ((B ⊆D) and (A ⊆C))

Lemma: subtype_rel_set
[A,B:Type]. ∀[P:A ⟶ ℙ].  {a:A| P[a]}  ⊆supposing A ⊆B

Lemma: subtype_rel_set_simple
[A:Type]. ∀[P:A ⟶ ℙ].  ({a:A| P[a]}  ⊆A)

Lemma: subtype_rel_sets
[A,B:Type]. ∀[P:A ⟶ ℙ]. ∀[Q:B ⟶ ℙ].  ({a:A| P[a]}  ⊆{b:B| Q[b]} supposing ((∀a:A. (P[a]  Q[a])) and ({a:A| P[a]\000C}  ⊆B))

Lemma: subtype_rel_sets_simple
[A:Type]. ∀[P,Q:A ⟶ ℙ].  {a:A| P[a]}  ⊆{b:A| Q[b]}  supposing ∀a:A. (P[a]  Q[a])

Lemma: subtype_rel_transitivity
[A,B,C:Type].  (A ⊆C) supposing ((B ⊆C) and (A ⊆B))

Lemma: subtype_rel_nested_set
[A,B:Type]. ∀[P:B ⟶ ℙ]. ∀[Q:{b:B| P[b]}  ⟶ ℙ].  A ⊆{b:{b:B| P[b]} Q[b]}  supposing A ⊆{b:B| P[b] ∧ Q[b]} 

Lemma: subtype_rel_nested_set2
[A,B:Type]. ∀[P:B ⟶ ℙ]. ∀[Q:{b:B| P[b]}  ⟶ ℙ].  {b:{b:B| P[b]} Q[b]}  ⊆supposing {b:B| P[b] ∧ Q[b]}  ⊆A

Lemma: subtype_rel_isect_general
[A,T:Type]. ∀[C:A ⟶ Type]. ∀[B:T ⟶ Type].  (⋂x:A. C[x]) ⊆(⋂x:T. B[x]) supposing (T ⊆A) ∧ (∀x:T. (C[x] ⊆B[x]))

Lemma: subtype_rel_isect
[A,T:Type]. ∀[B:T ⟶ Type].  uiff(A ⊆(⋂x:T. B[x]);∀[x:T]. (A ⊆B[x]))

Lemma: subtype_rel_isect_as_subtyping_lemma
[A,T:Type]. ∀[B:T ⟶ Type].  A ⊆(⋂x:T. B[x]) supposing ∀[x:T]. (A ⊆B[x])

Lemma: subtype_rel_isect-2
[A:Type]. ∀[B1,B2:A ⟶ Type].  (⋂x:A. B1[x]) ⊆(⋂x:A. B2[x]) supposing ∀[x:A]. (B1[x] ⊆B2[x])

Lemma: subtype_rel_double_isect
[A,T1,T2:Type]. ∀[B:T1 ⟶ T2 ⟶ Type].  uiff(A ⊆(⋂x:T1. ⋂y:T2.  B[x;y]);∀[x:T1]. ∀[y:T2].  (A ⊆B[x;y]))

Lemma: subtype_rel_not
[P,Q:ℙ].  P) ⊆Q) supposing  (↓P)

Lemma: isect_subtype_rel_trivial
[A,C:Type]. ∀[B:A ⟶ Type].  (⋂x:A. B[x]) ⊆supposing ∃x:A. (B[x] ⊆C)

Lemma: isect_subtype_rel
[A:Type]. ∀[B:A ⟶ Type]. ∀[x:A].  ((⋂x:A. B[x]) ⊆B[x])

Lemma: double_isect_subtype_rel
[T1,T2:Type]. ∀[B:T1 ⟶ T2 ⟶ Type]. ∀[x:T1]. ∀[y:T2].  ((⋂x:T1. ⋂y:T2.  B[x;y]) ⊆B[x;y])

Definition: rev_subtype_rel
A ⊇==  B ⊆A

Lemma: rev_subtype_rel_wf
[A,B:Type].  (A ⊇B ∈ ℙ)

Definition: ext-eq
A ≡ ==  (A ⊆B) ∧ (B ⊆A)

Lemma: ext-eq_wf
[A,B:Type].  (A ≡ B ∈ ℙ)

Lemma: sq_stable__ext-eq
[A,B:Type].  SqStable(A ≡ B)

Lemma: ext-eq_weakening
[A,B:Type].  A ≡ supposing B ∈ Type

Lemma: ext-eq_inversion
[A,B:Type].  B ≡ supposing A ≡ B

Lemma: ext-eq_transitivity
[A,B,C:Type].  (A ≡ C) supposing (B ≡ and A ≡ B)

Lemma: iff_weakening_ext-eq
[A,B:Type].  {A ⇐⇒ B} supposing A ≡ B

Lemma: subtype_rel_functionality_wrt_iff
[A,B,C,D:Type].  ({uiff(A ⊆B;C ⊆D)}) supposing (B ≡ and A ≡ C)

Lemma: subtype_rel_functionality_wrt_implies
[A,B,C,D:Type].  ({C ⊆supposing A ⊆B}) supposing ((B ⊆D) and (A ⊇C))

Lemma: subtype_rel_weakening
[A,B:Type].  A ⊆supposing A ≡ B

Lemma: rev_subtype_rel_weakening
[A,B:Type].  A ⊇supposing A ≡ B

Lemma: subtype-top
[T:Type]. uiff(T ⊆Top;True)

Lemma: subtype_rel-equal
[A,B:Type].  A ⊆supposing B ∈ Type

Lemma: subtype_rel_self
[A:Type]. (A ⊆A)

Lemma: void-product
[T,S:Type].  T × S ≡ Void supposing S ≡ Void

Lemma: void-dep-product
[S:Type]. ∀[F:S ⟶ Type].  m:S × (F m) ≡ Void supposing S ≡ Void

Lemma: product_subtype_base
[A:Type]. ∀[B:A ⟶ Type].  ((a:A × B[a]) ⊆Base) supposing ((∀a:A. (B[a] ⊆Base)) and (A ⊆Base))

Lemma: simple-product_subtype_base
[A,B:Type].  ((A × B) ⊆Base) supposing ((B ⊆Base) and (A ⊆Base))

Lemma: union_subtype_base
[A,B:Type].  ((A B) ⊆Base) supposing ((B ⊆Base) and (A ⊆Base))

Lemma: set_subtype_base
[A:Type]. ∀[P:A ⟶ ℙ].  {a:A| P[a]}  ⊆Base supposing A ⊆Base

Lemma: isect_subtype_base
[A:Type]. ∀[B:A ⟶ Type].  (⋂a:A. B[a]) ⊆Base supposing ∃a:A. (B[a] ⊆Base)

Lemma: tunion_subtype_base
[A:Type]. ∀[B:A ⟶ Type].  ⋃a:A.B[a] ⊆Base supposing ∀a:A. (B[a] ⊆Base)

Lemma: baseof_subtype
[T:Type]. (baseof(T) ⊆T)

Lemma: baseof_subtype_base
[T:Type]. (baseof(T) ⊆Base)

Lemma: subtype_top
[T:Type]. (T ⊆Top)

Lemma: uall_instance_test
[F:Type ⟶ ℤ ⟶ ℤ ⟶ ℙ]. ∀x:∀[A:Type]. ∀[m,c:ℤ].  F[A;m;c]. ∀B:Type. ∀n,b:ℤ.  (x ∈ F[B;n;b])

Lemma: tunion-is-image
[A:Type]. ∀[B:A ⟶ Type].  (⋃a:A.B[a] Image((a:A × B[a]),(λp.(snd(p)))))

Lemma: set-is-image
[A:Type]. ∀[B:A ⟶ Type].  {a:A| B[a]}  ≡ Image((a:A × B[a]),(λp.(fst(p))))

Lemma: equal_functionality_wrt_subtype_rel
[A,B:Type]. ∀[x,y:A].  {x y ∈ supposing y ∈ A} supposing A ⊆B

Lemma: equal_functionality_wrt_subtype_rel2
[A,B:Type]. ∀[x,y:A].  {(x y ∈ A)  (x y ∈ B)} supposing A ⊆B

Lemma: decidable-subtype
[P,Q:ℙ].  (Dec(P) ⊆Dec(Q)) supposing ((Q  P) and (P ⊆Q))

Lemma: subtype-respects-equality
[A,B:Type].  respects-equality(B;A) supposing B ⊆A

Lemma: general-subtype-respects-equality
[A,B,C:Type].  (respects-equality(B;C)) supposing (respects-equality(A;C) and (B ⊆A))

Lemma: subtype-base-respects-equality
[A,B:Type].  respects-equality(B;A) supposing B ⊆Base



Home Index