Nuprl Lemma : bag-partitions-cons
∀[X:Type]
  ∀[eq:EqDecider(X)]. ∀[x:X]. ∀[b:bag(X)].
    (bag-partitions(eq;x.b)
    = (bag-map(λp.<x.fst(p), snd(p)>[p∈bag-partitions(eq;b)|((#x in snd(p)) =z 0)])
      + bag-map(λp.<fst(p), x.snd(p)>bag-partitions(eq;b)))
    ∈ bag(bag(X) × bag(X))) 
  supposing valueall-type(X)
Proof
Definitions occuring in Statement : 
bag-partitions: bag-partitions(eq;bs)
, 
bag-count: (#x in bs)
, 
bag-filter: [x∈b|p[x]]
, 
bag-append: as + bs
, 
bag-map: bag-map(f;bs)
, 
cons-bag: x.b
, 
bag: bag(T)
, 
deq: EqDecider(T)
, 
valueall-type: valueall-type(T)
, 
eq_int: (i =z j)
, 
uimplies: b supposing a
, 
uall: ∀[x:A]. B[x]
, 
pi1: fst(t)
, 
pi2: snd(t)
, 
lambda: λx.A[x]
, 
pair: <a, b>
, 
product: x:A × B[x]
, 
natural_number: $n
, 
universe: Type
, 
equal: s = t ∈ T
Definitions unfolded in proof : 
uall: ∀[x:A]. B[x]
, 
member: t ∈ T
, 
uimplies: b supposing a
, 
implies: P 
⇒ Q
, 
all: ∀x:A. B[x]
, 
so_lambda: λ2x.t[x]
, 
so_apply: x[s]
, 
subtype_rel: A ⊆r B
, 
nat: ℕ
, 
prop: ℙ
, 
top: Top
, 
and: P ∧ Q
, 
cand: A c∧ B
, 
uiff: uiff(P;Q)
, 
bag-member: x ↓∈ bs
, 
squash: ↓T
, 
not: ¬A
, 
false: False
, 
inject: Inj(A;B;f)
, 
pi2: snd(t)
, 
pi1: fst(t)
, 
true: True
, 
exists: ∃x:A. B[x]
, 
guard: {T}
, 
rev_uimplies: rev_uimplies(P;Q)
, 
iff: P 
⇐⇒ Q
, 
single-bag: {x}
, 
deq: EqDecider(T)
, 
or: P ∨ Q
, 
sq_type: SQType(T)
, 
eqof: eqof(d)
, 
ifthenelse: if b then t else f fi 
, 
btrue: tt
, 
rev_implies: P 
⇐ Q
, 
bfalse: ff
, 
decidable: Dec(P)
, 
ge: i ≥ j 
, 
satisfiable_int_formula: satisfiable_int_formula(fmla)
, 
le: A ≤ B
, 
sq_or: a ↓∨ b
, 
bool: 𝔹
, 
unit: Unit
, 
it: ⋅
, 
bnot: ¬bb
, 
assert: ↑b
Lemmas referenced : 
bag-extensionality-no-repeats, 
bag_wf, 
decidable__equal_product, 
decidable__equal_bag, 
decidable-equal-deq, 
bag-partitions_wf, 
cons-bag_wf, 
bag-append_wf, 
bag-map_wf, 
assert_wf, 
eq_int_wf, 
bag-count_wf, 
pi2_wf, 
nat_wf, 
pi1_wf_top, 
subtype_rel_product, 
top_wf, 
bag-filter_wf, 
no-repeats-bag-partitions, 
bag-member_wf, 
deq_wf, 
valueall-type_wf, 
bag-no-repeats-append, 
subtype_rel_bag, 
bag-map-no-repeats, 
equal_wf, 
bag-append-cancel, 
single-bag_wf, 
squash_wf, 
true_wf, 
cons-bag-as-append, 
bag-filter-no-repeats, 
bag-member-map, 
not_wf, 
exists_wf, 
assert_functionality_wrt_uiff, 
assert_of_eq_int, 
bag-count-append, 
subtype_rel_self, 
iff_weakening_equal, 
cons_wf, 
nil_wf, 
list-subtype-bag, 
ifthenelse_wf, 
add_functionality_wrt_eq, 
bag-count-single, 
bnot_wf, 
eqof_wf, 
member_wf, 
bool_cases, 
subtype_base_sq, 
bool_wf, 
bool_subtype_base, 
eqtt_to_assert, 
safe-assert-deq, 
eqff_to_assert, 
iff_transitivity, 
iff_weakening_uiff, 
assert_of_bnot, 
le_weakening2, 
decidable__lt, 
nat_properties, 
full-omega-unsat, 
intformand_wf, 
intformle_wf, 
itermConstant_wf, 
itermVar_wf, 
intformeq_wf, 
itermAdd_wf, 
int_formula_prop_and_lemma, 
int_formula_prop_le_lemma, 
int_term_value_constant_lemma, 
int_term_value_var_lemma, 
int_formula_prop_eq_lemma, 
int_term_value_add_lemma, 
int_formula_prop_wf, 
bag-member-partitions, 
bag-member-append, 
bag-member-filter, 
or_wf, 
sq_or_wf, 
decidable__equal_int, 
bag-drop-property, 
bag-drop_wf, 
bag-append-assoc, 
bag-member-count, 
int_subtype_base, 
add-zero, 
add-commutes, 
decidable__le, 
intformnot_wf, 
int_formula_prop_not_lemma, 
bool_cases_sqequal, 
assert-bnot, 
bag-append-comm, 
cons_bag_append_lemma, 
bag-append-assoc-comm
Rules used in proof : 
sqequalSubstitution, 
sqequalTransitivity, 
computationStep, 
sqequalReflexivity, 
isect_memberFormation, 
introduction, 
cut, 
extract_by_obid, 
sqequalHypSubstitution, 
isectElimination, 
thin, 
productEquality, 
hypothesisEquality, 
hypothesis, 
independent_functionElimination, 
lambdaFormation, 
sqequalRule, 
lambdaEquality, 
because_Cache, 
dependent_functionElimination, 
independent_isectElimination, 
setEquality, 
applyEquality, 
setElimination, 
rename, 
natural_numberEquality, 
independent_pairEquality, 
isect_memberEquality, 
voidElimination, 
voidEquality, 
productElimination, 
independent_pairFormation, 
imageElimination, 
imageMemberEquality, 
baseClosed, 
axiomEquality, 
equalityTransitivity, 
equalitySymmetry, 
universeEquality, 
applyLambdaEquality, 
hyp_replacement, 
addLevel, 
impliesFunctionality, 
intEquality, 
instantiate, 
unionElimination, 
cumulativity, 
promote_hyp, 
approximateComputation, 
dependent_pairFormation, 
int_eqEquality, 
orFunctionality, 
existsFunctionality, 
andLevelFunctionality, 
inlFormation, 
equalityElimination, 
addEquality, 
inrFormation
Latex:
\mforall{}[X:Type]
    \mforall{}[eq:EqDecider(X)].  \mforall{}[x:X].  \mforall{}[b:bag(X)].
        (bag-partitions(eq;x.b)
        =  (bag-map(\mlambda{}p.<x.fst(p),  snd(p)>[p\mmember{}bag-partitions(eq;b)|((\#x  in  snd(p))  =\msubz{}  0)])
            +  bag-map(\mlambda{}p.<fst(p),  x.snd(p)>bag-partitions(eq;b)))) 
    supposing  valueall-type(X)
Date html generated:
2018_05_21-PM-09_50_07
Last ObjectModification:
2018_05_19-PM-04_21_18
Theory : bags_2
Home
Index