let c be FinSequence; :: thesis: ( c is Chain of G iff ( c is FinSequence of the carrier' of G & ex p being FinSequence of the carrier of G st p is_vertex_seq_of c ) )
hereby :: thesis: ( c is FinSequence of the carrier' of G & ex p being FinSequence of the carrier of G st p is_vertex_seq_of c implies c is Chain of G )
assume A1:
c is
Chain of
G
;
:: thesis: ( c is FinSequence of the carrier' of G & ex p being FinSequence of the carrier of G st p is_vertex_seq_of c )then consider p being
FinSequence such that A2:
len p = (len c) + 1
and A3:
for
n being
Element of
NAT st 1
<= n &
n <= len p holds
p . n in the
carrier of
G
and A4:
for
n being
Element of
NAT st 1
<= n &
n <= len c holds
ex
x',
y' being
Element of the
carrier of
G st
(
x' = p . n &
y' = p . (n + 1) &
c . n joins x',
y' )
by GRAPH_1:def 12;
then reconsider p =
p as
FinSequence of the
carrier of
G by FINSEQ_2:14;
thus
c is
FinSequence of the
carrier' of
G
by A1;
:: thesis: ex p being FinSequence of the carrier of G st p is_vertex_seq_of ctake p =
p;
:: thesis: p is_vertex_seq_of cthus
p is_vertex_seq_of c
:: thesis: verumproof
thus
len p = (len c) + 1
by A2;
:: according to GRAPH_2:def 7 :: thesis: for b1 being Element of NAT holds
( not 1 <= b1 or not b1 <= len c or c . b1 joins p /. b1,p /. (b1 + 1) )
let n be
Element of
NAT ;
:: thesis: ( not 1 <= n or not n <= len c or c . n joins p /. n,p /. (n + 1) )
assume A6:
( 1
<= n &
n <= len c )
;
:: thesis: c . n joins p /. n,p /. (n + 1)
then
( 1
<= n + 1 &
n <= len p &
n + 1
<= len p )
by A2, NAT_1:12, XREAL_1:8;
then A7:
(
p /. n = p . n &
p /. (n + 1) = p . (n + 1) )
by A6, FINSEQ_4:24;
ex
x',
y' being
Element of the
carrier of
G st
(
x' = p . n &
y' = p . (n + 1) &
c . n joins x',
y' )
by A4, A6;
hence
c . n joins p /. n,
p /. (n + 1)
by A7;
:: thesis: verum
end;
end;
assume A8:
c is FinSequence of the carrier' of G
; :: thesis: ( for p being FinSequence of the carrier of G holds not p is_vertex_seq_of c or c is Chain of G )
given p being FinSequence of the carrier of G such that A9:
p is_vertex_seq_of c
; :: thesis: c is Chain of G
take
p
; :: thesis: ( len p = (len c) + 1 & ( for b1 being Element of NAT holds
( not 1 <= b1 or not b1 <= len p or p . b1 in the carrier of G ) ) & ( for b1 being Element of NAT holds
( not 1 <= b1 or not b1 <= len c or ex b2, b3 being Element of the carrier of G st
( b2 = p . b1 & b3 = p . (b1 + 1) & c . b1 joins b2,b3 ) ) ) )
thus A10:
len p = (len c) + 1
by A9, GRAPH_2:def 7; :: thesis: ( ( for b1 being Element of NAT holds
( not 1 <= b1 or not b1 <= len p or p . b1 in the carrier of G ) ) & ( for b1 being Element of NAT holds
( not 1 <= b1 or not b1 <= len c or ex b2, b3 being Element of the carrier of G st
( b2 = p . b1 & b3 = p . (b1 + 1) & c . b1 joins b2,b3 ) ) ) )
let n be Element of NAT ; :: thesis: ( not 1 <= n or not n <= len c or ex b1, b2 being Element of the carrier of G st
( b1 = p . n & b2 = p . (n + 1) & c . n joins b1,b2 ) )
assume A11:
( 1 <= n & n <= len c )
; :: thesis: ex b1, b2 being Element of the carrier of G st
( b1 = p . n & b2 = p . (n + 1) & c . n joins b1,b2 )
take x' = p /. n; :: thesis: ex b1 being Element of the carrier of G st
( x' = p . n & b1 = p . (n + 1) & c . n joins x',b1 )
take y' = p /. (n + 1); :: thesis: ( x' = p . n & y' = p . (n + 1) & c . n joins x',y' )
( 1 <= n + 1 & n <= len p & n + 1 <= len p )
by A10, A11, NAT_1:12, XREAL_1:8;
hence
( x' = p . n & y' = p . (n + 1) )
by A11, FINSEQ_4:24; :: thesis: c . n joins x',y'
thus
c . n joins x',y'
by A9, A11, GRAPH_2:def 7; :: thesis: verum