scheme
SeqLambda1C{
F1()
-> Nat,
F2()
-> non
empty set ,
P1[
object ],
F3(
object )
-> set ,
F4(
object )
-> set } :
ex
p being
FinSequence of
F2() st
(
len p = F1() & ( for
i being
Nat st
i in Seg F1() holds
( (
P1[
i] implies
p . i = F3(
i) ) & (
P1[
i] implies
p . i = F4(
i) ) ) ) )
provided
A1:
for
i being
Nat st
i in Seg F1() holds
( (
P1[
i] implies
F3(
i)
in F2() ) & (
P1[
i] implies
F4(
i)
in F2() ) )
definition
let X be
set ;
let p be
FinSequence of
bool X;
let q be
FinSequence of
BOOLEAN ;
existence
ex b1 being FinSequence of bool X st
( len b1 = len p & ( for i being Nat st i in dom p holds
b1 . i = IFEQ ((q . i),TRUE,(p . i),(X \ (p . i))) ) )
uniqueness
for b1, b2 being FinSequence of bool X st len b1 = len p & ( for i being Nat st i in dom p holds
b1 . i = IFEQ ((q . i),TRUE,(p . i),(X \ (p . i))) ) & len b2 = len p & ( for i being Nat st i in dom p holds
b2 . i = IFEQ ((q . i),TRUE,(p . i),(X \ (p . i))) ) holds
b1 = b2
end;
theorem
for
X being
set for
x,
y,
z being
Subset of
X for
q being
FinSequence of
BOOLEAN holds
( (
q . 1
= TRUE implies
(MergeSequence (<*x,y,z*>,q)) . 1
= x ) & (
q . 1
= FALSE implies
(MergeSequence (<*x,y,z*>,q)) . 1
= X \ x ) & (
q . 2
= TRUE implies
(MergeSequence (<*x,y,z*>,q)) . 2
= y ) & (
q . 2
= FALSE implies
(MergeSequence (<*x,y,z*>,q)) . 2
= X \ y ) & (
q . 3
= TRUE implies
(MergeSequence (<*x,y,z*>,q)) . 3
= z ) & (
q . 3
= FALSE implies
(MergeSequence (<*x,y,z*>,q)) . 3
= X \ z ) )