let n be Element of NAT ; :: thesis: width (elementary_tree (n + 1)) = n + 1
set T = elementary_tree (n + 1);
now
{ <*k*> where k is Element of NAT : k < n + 1 } is AntiChain_of_Prefixes-like
proof
thus for x being set st x in { <*k*> where k is Element of NAT : k < n + 1 } holds
x is FinSequence :: according to TREES_1:def 13 :: thesis: for p1, p2 being FinSequence st p1 in { <*k*> where k is Element of NAT : k < n + 1 } & p2 in { <*k*> where k is Element of NAT : k < n + 1 } & p1 <> p2 holds
not p1,p2 are_c=-comparable
proof
let x be set ; :: thesis: ( x in { <*k*> where k is Element of NAT : k < n + 1 } implies x is FinSequence )
assume x in { <*k*> where k is Element of NAT : k < n + 1 } ; :: thesis: x is FinSequence
then ex k being Element of NAT st
( x = <*k*> & k < n + 1 ) ;
hence x is FinSequence ; :: thesis: verum
end;
let p1, p2 be FinSequence; :: thesis: ( p1 in { <*k*> where k is Element of NAT : k < n + 1 } & p2 in { <*k*> where k is Element of NAT : k < n + 1 } & p1 <> p2 implies not p1,p2 are_c=-comparable )
assume ( p1 in { <*k*> where k is Element of NAT : k < n + 1 } & p2 in { <*m*> where m is Element of NAT : m < n + 1 } ) ; :: thesis: ( not p1 <> p2 or not p1,p2 are_c=-comparable )
then ( ex k being Element of NAT st
( p1 = <*k*> & k < n + 1 ) & ex m being Element of NAT st
( p2 = <*m*> & m < n + 1 ) ) ;
hence ( not p1 <> p2 or not p1,p2 are_c=-comparable ) by Th23; :: thesis: verum
end;
then reconsider X = { <*k*> where k is Element of NAT : k < n + 1 } as AntiChain_of_Prefixes ;
X c= elementary_tree (n + 1) by XBOOLE_1:7;
then reconsider X = X as AntiChain_of_Prefixes of elementary_tree (n + 1) by Def14;
take X = X; :: thesis: ( n + 1 = card X & ( for Y being AntiChain_of_Prefixes of elementary_tree (n + 1) holds card Y <= card X ) )
X, Seg (n + 1) are_equipotent
proof
defpred S1[ set , set ] means ex n being Element of NAT st
( $1 = <*n*> & $2 = n + 1 );
A9: for x, y, z being set st x in X & S1[x,y] & S1[x,z] holds
y = z
proof
let x, y, z be set ; :: thesis: ( x in X & S1[x,y] & S1[x,z] implies y = z )
assume x in X ; :: thesis: ( not S1[x,y] or not S1[x,z] or y = z )
given n1 being Element of NAT such that A10: ( x = <*n1*> & y = n1 + 1 ) ; :: thesis: ( not S1[x,z] or y = z )
given n2 being Element of NAT such that A11: ( x = <*n2*> & z = n2 + 1 ) ; :: thesis: y = z
<*n1*> . 1 = n1 by FINSEQ_1:def 8;
hence y = z by A10, A11, FINSEQ_1:def 8; :: thesis: verum
end;
A13: for x being set st x in X holds
ex y being set st S1[x,y]
proof
let x be set ; :: thesis: ( x in X implies ex y being set st S1[x,y] )
assume x in X ; :: thesis: ex y being set st S1[x,y]
then consider k being Element of NAT such that
A15: x = <*k*> and
k < n + 1 ;
reconsider y = k + 1 as set ;
take y ; :: thesis: S1[x,y]
thus S1[x,y] by A15; :: thesis: verum
end;
consider f being Function such that
A16: ( dom f = X & ( for x being set st x in X holds
S1[x,f . x] ) ) from CLASSES1:sch 1(A13);
take f ; :: according to WELLORD2:def 4 :: thesis: ( f is one-to-one & proj1 f = X & proj2 f = Seg (n + 1) )
thus f is one-to-one :: thesis: ( proj1 f = X & proj2 f = Seg (n + 1) )
proof
let x be set ; :: according to FUNCT_1:def 8 :: thesis: for b1 being set holds
( not x in proj1 f or not b1 in proj1 f or not f . x = f . b1 or x = b1 )

let y be set ; :: thesis: ( not x in proj1 f or not y in proj1 f or not f . x = f . y or x = y )
assume that
A17: ( x in dom f & y in dom f ) and
A18: f . x = f . y ; :: thesis: x = y
( ex k1 being Element of NAT st
( x = <*k1*> & f . x = k1 + 1 ) & ex k2 being Element of NAT st
( y = <*k2*> & f . y = k2 + 1 ) ) by A16, A17;
hence x = y by A18; :: thesis: verum
end;
thus dom f = X by A16; :: thesis: proj2 f = Seg (n + 1)
thus rng f c= Seg (n + 1) :: according to XBOOLE_0:def 10 :: thesis: Seg (n + 1) is_a_prefix_of proj2 f
proof
let x be set ; :: according to TARSKI:def 3 :: thesis: ( not x in rng f or x in Seg (n + 1) )
assume x in rng f ; :: thesis: x in Seg (n + 1)
then consider y being set such that
A21: y in dom f and
A22: x = f . y by FUNCT_1:def 5;
consider k being Element of NAT such that
A23: y = <*k*> and
A24: x = k + 1 by A16, A21, A22;
consider m being Element of NAT such that
A25: ( y = <*m*> & m < n + 1 ) by A16, A21;
( <*k*> . 1 = k & <*m*> . 1 = m ) by FINSEQ_1:def 8;
then ( 0 + 1 <= k + 1 & k + 1 <= n + 1 ) by A23, A25, NAT_1:13;
hence x in Seg (n + 1) by A24, FINSEQ_1:3; :: thesis: verum
end;
let x be set ; :: according to TARSKI:def 3 :: thesis: ( not x in Seg (n + 1) or x in proj2 f )
assume A28: x in Seg (n + 1) ; :: thesis: x in proj2 f
then reconsider k = x as Element of NAT ;
A29: 1 <= k by A28, FINSEQ_1:3;
A30: k <= n + 1 by A28, FINSEQ_1:3;
consider m being Nat such that
A31: k = 1 + m by A29, NAT_1:10;
reconsider m = m as Element of NAT by ORDINAL1:def 13;
m < n + 1 by A30, A31, NAT_1:13;
then A33: <*m*> in X ;
then S1[<*m*>,f . <*m*>] by A16;
then x = f . <*m*> by A9, A31, A33;
hence x in proj2 f by A16, A33, FUNCT_1:def 5; :: thesis: verum
end;
then A36: card (Seg (n + 1)) = card X by CARD_1:21;
hence n + 1 = card X by FINSEQ_1:78; :: thesis: for Y being AntiChain_of_Prefixes of elementary_tree (n + 1) holds card Y <= card X
let Y be AntiChain_of_Prefixes of elementary_tree (n + 1); :: thesis: card Y <= card X
A37: Y c= elementary_tree (n + 1) by Def14;
A38: ( {} in Y implies Y = {{} } )
proof
assume that
A39: {} in Y and
A40: Y <> {{} } ; :: thesis: contradiction
consider x being set such that
A41: ( ( x in Y & not x in {{} } ) or ( x in {{} } & not x in Y ) ) by A40, TARSKI:2;
A42: {} <> x by A39, A41, TARSKI:def 1;
reconsider x = x as FinSequence of NAT by A37, A39, A41, Th44, TARSKI:def 1;
{} is_a_prefix_of x by XBOOLE_1:2;
then {} ,x are_c=-comparable by XBOOLE_0:def 9;
hence contradiction by A39, A41, A42, Def13, TARSKI:def 1; :: thesis: verum
end;
A45: ( card {{} } = 1 & 1 <= 1 + n ) by CARD_1:50, NAT_1:11;
now
assume A47: not {} in Y ; :: thesis: card Y <= card X
Y c= X
proof
let x be set ; :: according to TARSKI:def 3 :: thesis: ( not x in Y or x in X )
assume A49: x in Y ; :: thesis: x in X
then ( x in { <*k*> where k is Element of NAT : k < n + 1 } or x in {{} } ) by A37, XBOOLE_0:def 3;
hence x in X by A47, A49, TARSKI:def 1; :: thesis: verum
end;
hence card Y <= card X by NAT_1:44; :: thesis: verum
end;
hence card Y <= card X by A36, A38, A45, FINSEQ_1:78; :: thesis: verum
end;
hence width (elementary_tree (n + 1)) = n + 1 by Def16; :: thesis: verum