let G be finite real-weighted WGraph; :: thesis: for n being Nat holds
( ((PRIM:CompSeq G) . n) `1 is non empty Subset of (the_Vertices_of G) & ((PRIM:CompSeq G) . n) `2 c= G .edgesBetween (((PRIM:CompSeq G) . n) `1 ) )

set PCS = PRIM:CompSeq G;
defpred S1[ Nat] means ( ((PRIM:CompSeq G) . $1) `1 is non empty Subset of (the_Vertices_of G) & ((PRIM:CompSeq G) . $1) `2 c= G .edgesBetween (((PRIM:CompSeq G) . $1) `1 ) );
now end;
then A1: S1[ 0 ] ;
now
let n be Nat; :: thesis: ( S1[n] implies S1[n + 1] )
assume A2: S1[n] ; :: thesis: S1[n + 1]
set Gn = (PRIM:CompSeq G) . n;
set Gn1 = (PRIM:CompSeq G) . (n + 1);
set Next = PRIM:NextBestEdges ((PRIM:CompSeq G) . n);
set e = choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n));
A3: (PRIM:CompSeq G) . (n + 1) = PRIM:Step ((PRIM:CompSeq G) . n) by Def15;
now
per cases ( PRIM:NextBestEdges ((PRIM:CompSeq G) . n) = {} or PRIM:NextBestEdges ((PRIM:CompSeq G) . n) <> {} ) ;
suppose A4: PRIM:NextBestEdges ((PRIM:CompSeq G) . n) <> {} ; :: thesis: S1[n + 1]
set src = (the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)));
set tar = (the_Target_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)));
A5: choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)) in PRIM:NextBestEdges ((PRIM:CompSeq G) . n) by A4;
A9: choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)) SJoins ((PRIM:CompSeq G) . n) `1 ,(the_Vertices_of G) \ (((PRIM:CompSeq G) . n) `1 ),G by A4, Def12;
now
per cases ( (the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))) in ((PRIM:CompSeq G) . n) `1 or not (the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))) in ((PRIM:CompSeq G) . n) `1 ) ;
suppose A10: (the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))) in ((PRIM:CompSeq G) . n) `1 ; :: thesis: ( ((PRIM:CompSeq G) . (n + 1)) `1 is non empty Subset of (the_Vertices_of G) & ((PRIM:CompSeq G) . (n + 1)) `2 c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 ) )
then A11: (PRIM:CompSeq G) . (n + 1) = [((((PRIM:CompSeq G) . n) `1 ) \/ {((the_Target_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))))}),((((PRIM:CompSeq G) . n) `2 ) \/ {(choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)))})] by A3, A4, Def14;
A12: ((PRIM:CompSeq G) . (n + 1)) `1 = (((PRIM:CompSeq G) . n) `1 ) \/ {((the_Target_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))))} by A11, MCART_1:7;
A13: ((PRIM:CompSeq G) . (n + 1)) `2 = (((PRIM:CompSeq G) . n) `2 ) \/ {(choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)))} by A11, MCART_1:7;
now end;
hence ((PRIM:CompSeq G) . (n + 1)) `1 is non empty Subset of (the_Vertices_of G) by A11, MCART_1:7, TARSKI:def 3; :: thesis: ((PRIM:CompSeq G) . (n + 1)) `2 c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 )
A15: ((PRIM:CompSeq G) . n) `1 c= ((PRIM:CompSeq G) . (n + 1)) `1 by A12, XBOOLE_1:7;
A16: G .edgesBetween (((PRIM:CompSeq G) . n) `1 ) c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 ) by A12, GLIB_000:39, XBOOLE_1:7;
now end;
hence ((PRIM:CompSeq G) . (n + 1)) `2 c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 ) by TARSKI:def 3; :: thesis: verum
end;
suppose A19: not (the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))) in ((PRIM:CompSeq G) . n) `1 ; :: thesis: ( ((PRIM:CompSeq G) . (n + 1)) `1 is non empty Subset of (the_Vertices_of G) & ((PRIM:CompSeq G) . (n + 1)) `2 c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 ) )
then A20: (PRIM:CompSeq G) . (n + 1) = [((((PRIM:CompSeq G) . n) `1 ) \/ {((the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))))}),((((PRIM:CompSeq G) . n) `2 ) \/ {(choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)))})] by A3, A4, Def14;
A21: ((PRIM:CompSeq G) . (n + 1)) `1 = (((PRIM:CompSeq G) . n) `1 ) \/ {((the_Source_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))))} by A20, MCART_1:7;
A22: ((PRIM:CompSeq G) . (n + 1)) `2 = (((PRIM:CompSeq G) . n) `2 ) \/ {(choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n)))} by A20, MCART_1:7;
now end;
hence ((PRIM:CompSeq G) . (n + 1)) `1 is non empty Subset of (the_Vertices_of G) by A20, MCART_1:7, TARSKI:def 3; :: thesis: ((PRIM:CompSeq G) . (n + 1)) `2 c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 )
A24: ((PRIM:CompSeq G) . n) `1 c= ((PRIM:CompSeq G) . (n + 1)) `1 by A21, XBOOLE_1:7;
A25: G .edgesBetween (((PRIM:CompSeq G) . n) `1 ) c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 ) by A21, GLIB_000:39, XBOOLE_1:7;
A26: (the_Target_of G) . (choose (PRIM:NextBestEdges ((PRIM:CompSeq G) . n))) in ((PRIM:CompSeq G) . n) `1 by A9, A19, GLIB_000:def 17;
now end;
hence ((PRIM:CompSeq G) . (n + 1)) `2 c= G .edgesBetween (((PRIM:CompSeq G) . (n + 1)) `1 ) by TARSKI:def 3; :: thesis: verum
end;
end;
end;
hence S1[n + 1] ; :: thesis: verum
end;
end;
end;
hence S1[n + 1] ; :: thesis: verum
end;
then A29: for n being Nat st S1[n] holds
S1[n + 1] ;
for n being Nat holds S1[n] from NAT_1:sch 2(A1, A29);
hence for n being Nat holds
( ((PRIM:CompSeq G) . n) `1 is non empty Subset of (the_Vertices_of G) & ((PRIM:CompSeq G) . n) `2 c= G .edgesBetween (((PRIM:CompSeq G) . n) `1 ) ) ; :: thesis: verum