let G be Graph; :: thesis: for vs1, vs2 being FinSequence of the carrier of G
for c1, c2 being Chain of G st vs1 is_vertex_seq_of c1 & vs2 is_vertex_seq_of c2 & vs1 . (len vs1) = vs2 . 1 holds
c1 ^ c2 is Chain of G
let vs1, vs2 be FinSequence of the carrier of G; :: thesis: for c1, c2 being Chain of G st vs1 is_vertex_seq_of c1 & vs2 is_vertex_seq_of c2 & vs1 . (len vs1) = vs2 . 1 holds
c1 ^ c2 is Chain of G
let c1, c2 be Chain of G; :: thesis: ( vs1 is_vertex_seq_of c1 & vs2 is_vertex_seq_of c2 & vs1 . (len vs1) = vs2 . 1 implies c1 ^ c2 is Chain of G )
assume that
A1:
vs1 is_vertex_seq_of c1
and
A2:
( vs2 is_vertex_seq_of c2 & vs1 . (len vs1) = vs2 . 1 )
; :: thesis: c1 ^ c2 is Chain of G
A3:
( len vs1 = (len c1) + 1 & len vs2 = (len c2) + 1 )
by A1, A2, Def7;
then A4:
( vs1 <> {} & vs2 <> {} )
;
set q = c1 ^ c2;
set p = vs1 ^' vs2;
A5:
(len (vs1 ^' vs2)) + 1 = (len vs1) + (len vs2)
by A4, Th13;
then A6: len (vs1 ^' vs2) =
((len c1) + (len c2)) + 1
by A3
.=
(len (c1 ^ c2)) + 1
by FINSEQ_1:35
;
A17:
now let n be
Element of
NAT ;
:: thesis: ( 1 <= n & n <= len (c1 ^ c2) implies ex v1, v2 being Element of the carrier of G st
( v2 = (vs1 ^' vs2) . v1 & b3 = (vs1 ^' vs2) . (v1 + 1) & (c1 ^ c2) . v1 joins v2,b3 ) )assume
( 1
<= n &
n <= len (c1 ^ c2) )
;
:: thesis: ex v1, v2 being Element of the carrier of G st
( v2 = (vs1 ^' vs2) . v1 & b3 = (vs1 ^' vs2) . (v1 + 1) & (c1 ^ c2) . v1 joins v2,b3 )then A18:
n in dom (c1 ^ c2)
by FINSEQ_3:27;
per cases
( n in dom c1 or ex k being Nat st
( k in dom c2 & n = (len c1) + k ) )
by A18, FINSEQ_1:38;
suppose A19:
n in dom c1
;
:: thesis: ex v1, v2 being Element of the carrier of G st
( v2 = (vs1 ^' vs2) . v1 & b3 = (vs1 ^' vs2) . (v1 + 1) & (c1 ^ c2) . v1 joins v2,b3 )then A20:
(c1 ^ c2) . n = c1 . n
by FINSEQ_1:def 7;
set v1 =
vs1 /. n;
set v2 =
vs1 /. (n + 1);
A21:
( 1
<= n &
n <= len c1 )
by A19, FINSEQ_3:27;
then A22:
c1 . n joins vs1 /. n,
vs1 /. (n + 1)
by A1, Def7;
A23:
n <= len vs1
by A3, A21, NAT_1:12;
( 1
<= n + 1 &
n + 1
<= (len c1) + 1 )
by A21, NAT_1:12, XREAL_1:8;
then A24:
( 1
<= n + 1 &
n + 1
<= len vs1 )
by A1, Def7;
then A25:
(
vs1 /. n = vs1 . n &
vs1 /. (n + 1) = vs1 . (n + 1) )
by A21, A23, FINSEQ_4:24;
(
(vs1 ^' vs2) . n = vs1 . n &
(vs1 ^' vs2) . (n + 1) = vs1 . (n + 1) )
by A21, A23, A24, Th14;
hence
ex
v1,
v2 being
Element of the
carrier of
G st
(
v1 = (vs1 ^' vs2) . n &
v2 = (vs1 ^' vs2) . (n + 1) &
(c1 ^ c2) . n joins v1,
v2 )
by A20, A22, A25;
:: thesis: verum end; suppose
ex
k being
Nat st
(
k in dom c2 &
n = (len c1) + k )
;
:: thesis: ex v1, v2 being Element of the carrier of G st
( v2 = (vs1 ^' vs2) . v1 & b3 = (vs1 ^' vs2) . (v1 + 1) & (c1 ^ c2) . v1 joins v2,b3 )then consider k being
Nat such that A26:
(
k in dom c2 &
n = (len c1) + k )
;
A27:
(c1 ^ c2) . n = c2 . k
by A26, FINSEQ_1:def 7;
A28:
( 1
<= k &
k <= len c2 )
by A26, FINSEQ_3:27;
then A29:
( 1
<= k + 1 &
k <= len vs2 &
k + 1
<= len vs2 )
by A3, NAT_1:12, XREAL_1:9;
reconsider k =
k as
Element of
NAT by A26;
set v1 =
vs2 /. k;
set v2 =
vs2 /. (k + 1);
A30:
(
vs2 /. k = vs2 . k &
vs2 /. (k + 1) = vs2 . (k + 1) )
by A28, A29, FINSEQ_4:24;
A31:
c2 . k joins vs2 /. k,
vs2 /. (k + 1)
by A2, A28, Def7;
A32:
k <= len vs2
by A3, A28, NAT_1:12;
0 + 1
<= k
by A26, FINSEQ_3:27;
then consider j being
Element of
NAT such that A33:
(
0 <= j &
j < len vs2 &
k = j + 1 )
by A32, Th1;
A34:
(vs1 ^' vs2) . n = vs2 . k
A37:
k < len vs2
by A3, A28, NAT_1:13;
(vs1 ^' vs2) . (n + 1) =
(vs1 ^' vs2) . (((len c1) + 1) + k)
by A26
.=
vs2 . (k + 1)
by A3, A28, A37, Th15
;
hence
ex
v1,
v2 being
Element of the
carrier of
G st
(
v1 = (vs1 ^' vs2) . n &
v2 = (vs1 ^' vs2) . (n + 1) &
(c1 ^ c2) . n joins v1,
v2 )
by A27, A30, A31, A34;
:: thesis: verum end; end; end;
thus
c1 ^ c2 is Chain of G
:: thesis: verum