let X be finite set ; :: thesis: for C being Subset-Family of X st C is (C1) & C is without_proper_subsets holds
ex F being Full-family of X st C = candidate-keys F
let C be Subset-Family of X; :: thesis: ( C is (C1) & C is without_proper_subsets implies ex F being Full-family of X st C = candidate-keys F )
assume A1:
C is (C1)
; :: thesis: ( not C is without_proper_subsets or ex F being Full-family of X st C = candidate-keys F )
assume A2:
C is without_proper_subsets
; :: thesis: ex F being Full-family of X st C = candidate-keys F
set B = { b where b is Subset of X : for K being Subset of X st K in C holds
not K c= b } ;
{ b where b is Subset of X : for K being Subset of X st K in C holds
not K c= b } c= bool X
then reconsider BB = { b where b is Subset of X : for K being Subset of X st K in C holds
not K c= b } as Subset-Family of X ;
set F = { [a,b] where a, b is Subset of X : for c being set st c in BB & a c= c holds
b c= c } ;
{ [a,b] where a, b is Subset of X : for c being set st c in BB & a c= c holds
b c= c } = X deps_encl_by BB
;
then reconsider F = { [a,b] where a, b is Subset of X : for c being set st c in BB & a c= c holds
b c= c } as Full-family of X by Th35;
take
F
; :: thesis: C = candidate-keys F
A3:
[#] X = X
;
A4:
now let x be
set ;
:: thesis: ( x in C implies [x,X] in Maximal_wrt F )assume A5:
x in C
;
:: thesis: [x,X] in Maximal_wrt Fthen reconsider x' =
x as
Subset of
X ;
then
[x',X] in F
by A3;
then consider a,
b being
Subset of
X such that A7:
[a,b] in Maximal_wrt F
and A8:
[a,b] >= [x',([#] X)]
by Th28;
A9:
a c= x'
by A8, Th15;
X c= b
by A8, Th15;
then A10:
b = X
by XBOOLE_0:def 10;
assume A11:
not
[x,X] in Maximal_wrt F
;
:: thesis: contradictionthen
a in BB
;
then
X c= a
by A7, A10, Lm2;
then
X = a
by XBOOLE_0:def 10;
hence
contradiction
by A7, A9, A10, A11, XBOOLE_0:def 10;
:: thesis: verum end;
now let x be
set ;
:: thesis: ( ( x in C implies x in candidate-keys F ) & ( x in candidate-keys F implies x in C ) )assume
x in candidate-keys F
;
:: thesis: x in Cthen consider A being
Subset of
X such that A15:
x = A
and A16:
[A,X] in Maximal_wrt F
;
A17:
for
c being
set holds
( not
c in BB or
c = X or not
A c= c )
assume A21:
not
x in C
;
:: thesis: contradictionnow given K being
Subset of
X such that A22:
K in C
and A23:
K c= A
;
:: thesis: contradictionA24:
[K,X] in Maximal_wrt F
by A4, A22;
A25:
A ^|^ X,
F
by A16, Def18;
[K,([#] X)] >= [A,([#] X)]
by A23, Th15;
hence
contradiction
by A15, A21, A22, A24, A25, Th29;
:: thesis: verum end; then
A in BB
;
then
X in BB
by A17;
then consider b being
Subset of
X such that A26:
b = X
and A27:
for
K being
Subset of
X st
K in C holds
not
K c= b
;
for
K being
set holds not
K in C
by A26, A27;
hence
contradiction
by A1, XBOOLE_0:def 1;
:: thesis: verum end;
hence
C = candidate-keys F
by TARSKI:2; :: thesis: verum