2 (**************************************************************************)
5 (* ||A|| A project by Andrea Asperti *)
7 (* ||I|| Developers: *)
8 (* ||T|| The HELM team. *)
9 (* ||A|| http://helm.cs.unibo.it *)
11 (* \ / This file is distributed under the terms of the *)
12 (* v GNU General Public License Version 2 *)
14 (**************************************************************************)
16 include "ground_2/relocation/nstream_after.ma".
17 include "basic_2/notation/relations/rliftstar_3.ma".
18 include "basic_2/syntax/term.ma".
20 (* GENERIC RELOCATION FOR TERMS *********************************************)
23 lift_sort lift_lref_lt lift_lref_ge lift_bind lift_flat
26 inductive lifts: rtmap → relation term ≝
27 | lifts_sort: ∀f,s. lifts f (⋆s) (⋆s)
28 | lifts_lref: ∀f,i1,i2. @⦃i1, f⦄ ≡ i2 → lifts f (#i1) (#i2)
29 | lifts_gref: ∀f,l. lifts f (§l) (§l)
30 | lifts_bind: ∀f,p,I,V1,V2,T1,T2.
31 lifts f V1 V2 → lifts (↑f) T1 T2 →
32 lifts f (ⓑ{p,I}V1.T1) (ⓑ{p,I}V2.T2)
33 | lifts_flat: ∀f,I,V1,V2,T1,T2.
34 lifts f V1 V2 → lifts f T1 T2 →
35 lifts f (ⓕ{I}V1.T1) (ⓕ{I}V2.T2)
38 interpretation "uniform relocation (term)"
39 'RLiftStar i T1 T2 = (lifts (uni i) T1 T2).
41 interpretation "generic relocation (term)"
42 'RLiftStar f T1 T2 = (lifts f T1 T2).
45 (* Basic inversion lemmas ***************************************************)
47 fact lifts_inv_sort1_aux: ∀f,X,Y. ⬆*[f] X ≡ Y → ∀s. X = ⋆s → Y = ⋆s.
48 #f #X #Y * -f -X -Y //
49 [ #f #i1 #i2 #_ #x #H destruct
50 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
51 | #f #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
55 (* Basic_1: was: lift1_sort *)
56 (* Basic_2A1: includes: lift_inv_sort1 *)
57 lemma lifts_inv_sort1: ∀f,Y,s. ⬆*[f] ⋆s ≡ Y → Y = ⋆s.
58 /2 width=4 by lifts_inv_sort1_aux/ qed-.
60 fact lifts_inv_lref1_aux: ∀f,X,Y. ⬆*[f] X ≡ Y → ∀i1. X = #i1 →
61 ∃∃i2. @⦃i1, f⦄ ≡ i2 & Y = #i2.
63 [ #f #s #x #H destruct
64 | #f #i1 #i2 #Hi12 #x #H destruct /2 width=3 by ex2_intro/
65 | #f #l #x #H destruct
66 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
67 | #f #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
71 (* Basic_1: was: lift1_lref *)
72 (* Basic_2A1: includes: lift_inv_lref1 lift_inv_lref1_lt lift_inv_lref1_ge *)
73 lemma lifts_inv_lref1: ∀f,Y,i1. ⬆*[f] #i1 ≡ Y →
74 ∃∃i2. @⦃i1, f⦄ ≡ i2 & Y = #i2.
75 /2 width=3 by lifts_inv_lref1_aux/ qed-.
77 fact lifts_inv_gref1_aux: ∀f,X,Y. ⬆*[f] X ≡ Y → ∀l. X = §l → Y = §l.
78 #f #X #Y * -f -X -Y //
79 [ #f #i1 #i2 #_ #x #H destruct
80 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
81 | #f #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
85 (* Basic_2A1: includes: lift_inv_gref1 *)
86 lemma lifts_inv_gref1: ∀f,Y,l. ⬆*[f] §l ≡ Y → Y = §l.
87 /2 width=4 by lifts_inv_gref1_aux/ qed-.
89 fact lifts_inv_bind1_aux: ∀f,X,Y. ⬆*[f] X ≡ Y →
90 ∀p,I,V1,T1. X = ⓑ{p,I}V1.T1 →
91 ∃∃V2,T2. ⬆*[f] V1 ≡ V2 & ⬆*[↑f] T1 ≡ T2 &
94 [ #f #s #q #J #W1 #U1 #H destruct
95 | #f #i1 #i2 #_ #q #J #W1 #U1 #H destruct
96 | #f #l #b #J #W1 #U1 #H destruct
97 | #f #p #I #V1 #V2 #T1 #T2 #HV12 #HT12 #q #J #W1 #U1 #H destruct /2 width=5 by ex3_2_intro/
98 | #f #I #V1 #V2 #T1 #T2 #_ #_ #q #J #W1 #U1 #H destruct
102 (* Basic_1: was: lift1_bind *)
103 (* Basic_2A1: includes: lift_inv_bind1 *)
104 lemma lifts_inv_bind1: ∀f,p,I,V1,T1,Y. ⬆*[f] ⓑ{p,I}V1.T1 ≡ Y →
105 ∃∃V2,T2. ⬆*[f] V1 ≡ V2 & ⬆*[↑f] T1 ≡ T2 &
107 /2 width=3 by lifts_inv_bind1_aux/ qed-.
109 fact lifts_inv_flat1_aux: ∀f:rtmap. ∀X,Y. ⬆*[f] X ≡ Y →
110 ∀I,V1,T1. X = ⓕ{I}V1.T1 →
111 ∃∃V2,T2. ⬆*[f] V1 ≡ V2 & ⬆*[f] T1 ≡ T2 &
114 [ #f #s #J #W1 #U1 #H destruct
115 | #f #i1 #i2 #_ #J #W1 #U1 #H destruct
116 | #f #l #J #W1 #U1 #H destruct
117 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #J #W1 #U1 #H destruct
118 | #f #I #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W1 #U1 #H destruct /2 width=5 by ex3_2_intro/
122 (* Basic_1: was: lift1_flat *)
123 (* Basic_2A1: includes: lift_inv_flat1 *)
124 lemma lifts_inv_flat1: ∀f:rtmap. ∀I,V1,T1,Y. ⬆*[f] ⓕ{I}V1.T1 ≡ Y →
125 ∃∃V2,T2. ⬆*[f] V1 ≡ V2 & ⬆*[f] T1 ≡ T2 &
127 /2 width=3 by lifts_inv_flat1_aux/ qed-.
129 fact lifts_inv_sort2_aux: ∀f,X,Y. ⬆*[f] X ≡ Y → ∀s. Y = ⋆s → X = ⋆s.
130 #f #X #Y * -f -X -Y //
131 [ #f #i1 #i2 #_ #x #H destruct
132 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
133 | #f #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
137 (* Basic_1: includes: lift_gen_sort *)
138 (* Basic_2A1: includes: lift_inv_sort2 *)
139 lemma lifts_inv_sort2: ∀f,X,s. ⬆*[f] X ≡ ⋆s → X = ⋆s.
140 /2 width=4 by lifts_inv_sort2_aux/ qed-.
142 fact lifts_inv_lref2_aux: ∀f,X,Y. ⬆*[f] X ≡ Y → ∀i2. Y = #i2 →
143 ∃∃i1. @⦃i1, f⦄ ≡ i2 & X = #i1.
145 [ #f #s #x #H destruct
146 | #f #i1 #i2 #Hi12 #x #H destruct /2 width=3 by ex2_intro/
147 | #f #l #x #H destruct
148 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
149 | #f #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
153 (* Basic_1: includes: lift_gen_lref lift_gen_lref_lt lift_gen_lref_false lift_gen_lref_ge *)
154 (* Basic_2A1: includes: lift_inv_lref2 lift_inv_lref2_lt lift_inv_lref2_be lift_inv_lref2_ge lift_inv_lref2_plus *)
155 lemma lifts_inv_lref2: ∀f,X,i2. ⬆*[f] X ≡ #i2 →
156 ∃∃i1. @⦃i1, f⦄ ≡ i2 & X = #i1.
157 /2 width=3 by lifts_inv_lref2_aux/ qed-.
159 fact lifts_inv_gref2_aux: ∀f,X,Y. ⬆*[f] X ≡ Y → ∀l. Y = §l → X = §l.
160 #f #X #Y * -f -X -Y //
161 [ #f #i1 #i2 #_ #x #H destruct
162 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
163 | #f #I #V1 #V2 #T1 #T2 #_ #_ #x #H destruct
167 (* Basic_2A1: includes: lift_inv_gref1 *)
168 lemma lifts_inv_gref2: ∀f,X,l. ⬆*[f] X ≡ §l → X = §l.
169 /2 width=4 by lifts_inv_gref2_aux/ qed-.
171 fact lifts_inv_bind2_aux: ∀f,X,Y. ⬆*[f] X ≡ Y →
172 ∀p,I,V2,T2. Y = ⓑ{p,I}V2.T2 →
173 ∃∃V1,T1. ⬆*[f] V1 ≡ V2 & ⬆*[↑f] T1 ≡ T2 &
176 [ #f #s #q #J #W2 #U2 #H destruct
177 | #f #i1 #i2 #_ #q #J #W2 #U2 #H destruct
178 | #f #l #q #J #W2 #U2 #H destruct
179 | #f #p #I #V1 #V2 #T1 #T2 #HV12 #HT12 #q #J #W2 #U2 #H destruct /2 width=5 by ex3_2_intro/
180 | #f #I #V1 #V2 #T1 #T2 #_ #_ #q #J #W2 #U2 #H destruct
184 (* Basic_1: includes: lift_gen_bind *)
185 (* Basic_2A1: includes: lift_inv_bind2 *)
186 lemma lifts_inv_bind2: ∀f,p,I,V2,T2,X. ⬆*[f] X ≡ ⓑ{p,I}V2.T2 →
187 ∃∃V1,T1. ⬆*[f] V1 ≡ V2 & ⬆*[↑f] T1 ≡ T2 &
189 /2 width=3 by lifts_inv_bind2_aux/ qed-.
191 fact lifts_inv_flat2_aux: ∀f:rtmap. ∀X,Y. ⬆*[f] X ≡ Y →
192 ∀I,V2,T2. Y = ⓕ{I}V2.T2 →
193 ∃∃V1,T1. ⬆*[f] V1 ≡ V2 & ⬆*[f] T1 ≡ T2 &
196 [ #f #s #J #W2 #U2 #H destruct
197 | #f #i1 #i2 #_ #J #W2 #U2 #H destruct
198 | #f #l #J #W2 #U2 #H destruct
199 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #J #W2 #U2 #H destruct
200 | #f #I #V1 #V2 #T1 #T2 #HV12 #HT12 #J #W2 #U2 #H destruct /2 width=5 by ex3_2_intro/
204 (* Basic_1: includes: lift_gen_flat *)
205 (* Basic_2A1: includes: lift_inv_flat2 *)
206 lemma lifts_inv_flat2: ∀f:rtmap. ∀I,V2,T2,X. ⬆*[f] X ≡ ⓕ{I}V2.T2 →
207 ∃∃V1,T1. ⬆*[f] V1 ≡ V2 & ⬆*[f] T1 ≡ T2 &
209 /2 width=3 by lifts_inv_flat2_aux/ qed-.
211 (* Advanced inversion lemmas ************************************************)
213 lemma lifts_inv_atom1: ∀f,I,Y. ⬆*[f] ⓪{I} ≡ Y →
214 ∨∨ ∃∃s. I = Sort s & Y = ⋆s
215 | ∃∃i,j. @⦃i, f⦄ ≡ j & I = LRef i & Y = #j
216 | ∃∃l. I = GRef l & Y = §l.
218 [ lapply (lifts_inv_sort1 … H)
219 | elim (lifts_inv_lref1 … H)
220 | lapply (lifts_inv_gref1 … H)
221 ] -H /3 width=5 by or3_intro0, or3_intro1, or3_intro2, ex3_2_intro, ex2_intro/
224 lemma lifts_inv_atom2: ∀f,I,X. ⬆*[f] X ≡ ⓪{I} →
225 ∨∨ ∃∃s. X = ⋆s & I = Sort s
226 | ∃∃i,j. @⦃i, f⦄ ≡ j & X = #i & I = LRef j
227 | ∃∃l. X = §l & I = GRef l.
229 [ lapply (lifts_inv_sort2 … H)
230 | elim (lifts_inv_lref2 … H)
231 | lapply (lifts_inv_gref2 … H)
232 ] -H /3 width=5 by or3_intro0, or3_intro1, or3_intro2, ex3_2_intro, ex2_intro/
235 (* Basic_2A1: includes: lift_inv_pair_xy_x *)
236 lemma lifts_inv_pair_xy_x: ∀f,I,V,T. ⬆*[f] ②{I}V.T ≡ V → ⊥.
239 [ lapply (lifts_inv_sort2 … H) -H #H destruct
240 | elim (lifts_inv_lref2 … H) -H
242 | lapply (lifts_inv_gref2 … H) -H #H destruct
244 | * [ #p ] #I #V2 #T2 #IHV2 #_ #U #H
245 [ elim (lifts_inv_bind2 … H) -H #V1 #T1 #HV12 #_ #H destruct /2 width=3 by/
246 | elim (lifts_inv_flat2 … H) -H #V1 #T1 #HV12 #_ #H destruct /2 width=3 by/
251 (* Basic_1: includes: thead_x_lift_y_y *)
252 (* Basic_2A1: includes: lift_inv_pair_xy_y *)
253 lemma lifts_inv_pair_xy_y: ∀I,T,V,f. ⬆*[f] ②{I}V.T ≡ T → ⊥.
256 [ lapply (lifts_inv_sort2 … H) -H #H destruct
257 | elim (lifts_inv_lref2 … H) -H
259 | lapply (lifts_inv_gref2 … H) -H #H destruct
261 | * [ #p ] #I #V2 #T2 #_ #IHT2 #W #f #H
262 [ elim (lifts_inv_bind2 … H) -H #V1 #T1 #_ #HT12 #H destruct /2 width=4 by/
263 | elim (lifts_inv_flat2 … H) -H #V1 #T1 #_ #HT12 #H destruct /2 width=4 by/
268 (* Inversion lemmas with uniform relocations ********************************)
270 lemma lifts_inv_lref1_uni: ∀l,Y,i. ⬆*[l] #i ≡ Y → Y = #(l+i).
271 #l #Y #i1 #H elim (lifts_inv_lref1 … H) -H /4 width=4 by at_mono, eq_f/
274 lemma lifts_inv_lref2_uni: ∀l,X,i2. ⬆*[l] X ≡ #i2 →
275 ∃∃i1. X = #i1 & i2 = l + i1.
276 #l #X #i2 #H elim (lifts_inv_lref2 … H) -H
277 /3 width=3 by at_inv_uni, ex2_intro/
280 lemma lifts_inv_lref2_uni_ge: ∀l,X,i. ⬆*[l] X ≡ #(l + i) → X = #i.
281 #l #X #i2 #H elim (lifts_inv_lref2_uni … H) -H
282 #i1 #H1 #H2 destruct /4 width=2 by injective_plus_r, eq_f, sym_eq/
285 lemma lifts_inv_lref2_uni_lt: ∀l,X,i. ⬆*[l] X ≡ #i → i < l → ⊥.
286 #l #X #i2 #H elim (lifts_inv_lref2_uni … H) -H
287 #i1 #_ #H1 #H2 destruct /2 width=4 by lt_le_false/
290 (* Basic forward lemmas *****************************************************)
292 (* Basic_2A1: includes: lift_inv_O2 *)
293 lemma lifts_fwd_isid: ∀f,T1,T2. ⬆*[f] T1 ≡ T2 → 𝐈⦃f⦄ → T1 = T2.
294 #f #T1 #T2 #H elim H -f -T1 -T2
295 /4 width=3 by isid_inv_at_mono, isid_push, eq_f2, eq_f/
298 (* Basic_2A1: includes: lift_fwd_pair1 *)
299 lemma lifts_fwd_pair1: ∀f:rtmap. ∀I,V1,T1,Y. ⬆*[f] ②{I}V1.T1 ≡ Y →
300 ∃∃V2,T2. ⬆*[f] V1 ≡ V2 & Y = ②{I}V2.T2.
301 #f * [ #p ] #I #V1 #T1 #Y #H
302 [ elim (lifts_inv_bind1 … H) -H /2 width=4 by ex2_2_intro/
303 | elim (lifts_inv_flat1 … H) -H /2 width=4 by ex2_2_intro/
307 (* Basic_2A1: includes: lift_fwd_pair2 *)
308 lemma lifts_fwd_pair2: ∀f:rtmap. ∀I,V2,T2,X. ⬆*[f] X ≡ ②{I}V2.T2 →
309 ∃∃V1,T1. ⬆*[f] V1 ≡ V2 & X = ②{I}V1.T1.
310 #f * [ #p ] #I #V2 #T2 #X #H
311 [ elim (lifts_inv_bind2 … H) -H /2 width=4 by ex2_2_intro/
312 | elim (lifts_inv_flat2 … H) -H /2 width=4 by ex2_2_intro/
316 (* Basic properties *********************************************************)
318 lemma lifts_eq_repl_back: ∀T1,T2. eq_repl_back … (λf. ⬆*[f] T1 ≡ T2).
319 #T1 #T2 #f1 #H elim H -T1 -T2 -f1
320 /4 width=5 by lifts_flat, lifts_bind, lifts_lref, at_eq_repl_back, eq_push/
323 lemma lifts_eq_repl_fwd: ∀T1,T2. eq_repl_fwd … (λf. ⬆*[f] T1 ≡ T2).
324 #T1 #T2 @eq_repl_sym /2 width=3 by lifts_eq_repl_back/ (**) (* full auto fails *)
327 (* Basic_1: includes: lift_r *)
328 (* Basic_2A1: includes: lift_refl *)
329 lemma lifts_refl: ∀T,f. 𝐈⦃f⦄ → ⬆*[f] T ≡ T.
331 /4 width=3 by lifts_flat, lifts_bind, lifts_lref, isid_inv_at, isid_push/
334 (* Basic_2A1: includes: lift_total *)
335 lemma lifts_total: ∀T1,f. ∃T2. ⬆*[f] T1 ≡ T2.
337 /3 width=2 by lifts_lref, lifts_sort, lifts_gref, ex_intro/
338 [ #p ] #I #V1 #T1 #IHV1 #IHT1 #f
339 elim (IHV1 f) -IHV1 #V2 #HV12
340 [ elim (IHT1 (↑f)) -IHT1 /3 width=2 by lifts_bind, ex_intro/
341 | elim (IHT1 f) -IHT1 /3 width=2 by lifts_flat, ex_intro/
345 lemma lift_lref_uni: ∀l,i. ⬆*[l] #i ≡ #(l+i).
346 #l elim l -l /2 width=1 by lifts_lref/
349 (* Basic_1: includes: lift_free (right to left) *)
350 (* Basic_2A1: includes: lift_split *)
351 lemma lifts_split_trans: ∀f,T1,T2. ⬆*[f] T1 ≡ T2 →
352 ∀f1,f2. f2 ⊚ f1 ≡ f →
353 ∃∃T. ⬆*[f1] T1 ≡ T & ⬆*[f2] T ≡ T2.
354 #f #T1 #T2 #H elim H -f -T1 -T2
355 [ /3 width=3 by lifts_sort, ex2_intro/
356 | #f #i1 #i2 #Hi #f1 #f2 #Ht elim (after_at_fwd … Hi … Ht) -Hi -Ht
357 /3 width=3 by lifts_lref, ex2_intro/
358 | /3 width=3 by lifts_gref, ex2_intro/
359 | #f #p #I #V1 #V2 #T1 #T2 #_ #_ #IHV #IHT #f1 #f2 #Ht
360 elim (IHV … Ht) elim (IHT (↑f1) (↑f2)) -IHV -IHT
361 /3 width=5 by lifts_bind, after_O2, ex2_intro/
362 | #f #I #V1 #V2 #T1 #T2 #_ #_ #IHV #IHT #f1 #f2 #Ht
363 elim (IHV … Ht) elim (IHT … Ht) -IHV -IHT -Ht
364 /3 width=5 by lifts_flat, ex2_intro/
368 (* Note: apparently, this was missing in Basic_2A1 *)
369 lemma lifts_split_div: ∀f1,T1,T2. ⬆*[f1] T1 ≡ T2 →
371 ∃∃T. ⬆*[f2] T2 ≡ T & ⬆*[f] T1 ≡ T.
372 #f1 #T1 #T2 #H elim H -f1 -T1 -T2
373 [ /3 width=3 by lifts_sort, ex2_intro/
374 | #f1 #i1 #i2 #Hi #f2 #f #Ht elim (after_at1_fwd … Hi … Ht) -Hi -Ht
375 /3 width=3 by lifts_lref, ex2_intro/
376 | /3 width=3 by lifts_gref, ex2_intro/
377 | #f1 #p #I #V1 #V2 #T1 #T2 #_ #_ #IHV #IHT #f2 #f #Ht
378 elim (IHV … Ht) elim (IHT (↑f2) (↑f)) -IHV -IHT
379 /3 width=5 by lifts_bind, after_O2, ex2_intro/
380 | #f1 #I #V1 #V2 #T1 #T2 #_ #_ #IHV #IHT #f2 #f #Ht
381 elim (IHV … Ht) elim (IHT … Ht) -IHV -IHT -Ht
382 /3 width=5 by lifts_flat, ex2_intro/
386 (* Basic_1: includes: dnf_dec2 dnf_dec *)
387 (* Basic_2A1: includes: is_lift_dec *)
388 lemma is_lifts_dec: ∀T2,f. Decidable (∃T1. ⬆*[f] T1 ≡ T2).
390 [ * [1,3: /3 width=2 by lifts_sort, lifts_gref, ex_intro, or_introl/ ]
391 #i2 #f elim (is_at_dec f i2) //
392 [ * /4 width=3 by lifts_lref, ex_intro, or_introl/
394 #X #HX elim (lifts_inv_lref2 … HX) -HX
395 /3 width=2 by ex_intro/
397 | * [ #p ] #I #V2 #T2 #IHV2 #IHT2 #f
398 [ elim (IHV2 f) -IHV2
399 [ * #V1 #HV12 elim (IHT2 (↑f)) -IHT2
400 [ * #T1 #HT12 @or_introl /3 width=2 by lifts_bind, ex_intro/
401 | -V1 #HT2 @or_intror * #X #H
402 elim (lifts_inv_bind2 … H) -H /3 width=2 by ex_intro/
404 | -IHT2 #HV2 @or_intror * #X #H
405 elim (lifts_inv_bind2 … H) -H /3 width=2 by ex_intro/
407 | elim (IHV2 f) -IHV2
408 [ * #V1 #HV12 elim (IHT2 f) -IHT2
409 [ * #T1 #HT12 /4 width=2 by lifts_flat, ex_intro, or_introl/
410 | -V1 #HT2 @or_intror * #X #H
411 elim (lifts_inv_flat2 … H) -H /3 width=2 by ex_intro/
413 | -IHT2 #HV2 @or_intror * #X #H
414 elim (lifts_inv_flat2 … H) -H /3 width=2 by ex_intro/
420 (* Properties with uniform relocation ***************************************)
422 lemma lifts_uni: ∀n1,n2,T,U. ⬆*[𝐔❴n1❵∘𝐔❴n2❵] T ≡ U → ⬆*[n1+n2] T ≡ U.
423 /3 width=4 by lifts_eq_repl_back, after_inv_total/ qed.
425 (* Basic_2A1: removed theorems 14:
426 lifts_inv_nil lifts_inv_cons
427 lift_inv_Y1 lift_inv_Y2 lift_inv_lref_Y1 lift_inv_lref_Y2 lift_lref_Y lift_Y1
428 lift_lref_lt_eq lift_lref_ge_eq lift_lref_plus lift_lref_pred
429 lift_lref_ge_minus lift_lref_ge_minus_eq
431 (* Basic_1: removed theorems 8:
433 lift_head lift_gen_head
434 lift_weight_map lift_weight lift_weight_add lift_weight_add_O