let S be Language; :: thesis: for D being RuleSet of S st ( for R being Rule of S st R in D holds
R is Correct ) holds
D is Correct

let D be RuleSet of S; :: thesis: ( ( for R being Rule of S st R in D holds
R is Correct ) implies D is Correct )

set Q = S -sequents ;
set O = OneStep D;
{} null S is S -correct ;
then reconsider e = {} null (S -sequents) as S -correct Subset of (S -sequents) ;
reconsider RO = rng (OneStep D) as Subset of (bool (S -sequents)) by RELAT_1:def 19;
assume A1: for R being Rule of S st R in D holds
R is Correct ; :: thesis: D is Correct
defpred S1[ Nat] means for X being S -correct Subset of (S -sequents) holds (($1,D) -derivables) . X is S -correct ;
A2: S1[ 0 ]
proof
set f = (0,D) -derivables ;
A3: (0,D) -derivables = id (field (OneStep D)) by FUNCT_7:68
.= id ((bool (S -sequents)) \/ RO) by FUNCT_2:def 1
.= id (bool (S -sequents)) ;
let X be S -correct Subset of (S -sequents); :: thesis: ((0,D) -derivables) . X is S -correct
thus ((0,D) -derivables) . X is S -correct by A3; :: thesis: verum
end;
A4: for n being Nat st S1[n] holds
S1[n + 1]
proof
let n be Nat; :: thesis: ( S1[n] implies S1[n + 1] )
assume A5: S1[n] ; :: thesis: S1[n + 1]
let X be S -correct Subset of (S -sequents); :: thesis: (((n + 1),D) -derivables) . X is S -correct
set DM = ((n + 1),D) -derivables ;
set Dm = (n,D) -derivables ;
A6: dom ((n,D) -derivables) = bool (S -sequents) by FUNCT_2:def 1;
reconsider oldSeqs = ((n,D) -derivables) . X as S -correct Subset of (S -sequents) by A5;
A7: ((n + 1),D) -derivables = (OneStep D) * ((n,D) -derivables) by FUNCT_7:71;
now :: thesis: for U being non empty set
for I being Element of U -InterpretersOf S
for H being b2 -satisfied set
for phi being wff string of S st [H,phi] in (((n + 1),D) -derivables) . X holds
I -TruthEval phi = 1
let U be non empty set ; :: thesis: for I being Element of U -InterpretersOf S
for H being b1 -satisfied set
for phi being wff string of S st [H,phi] in (((n + 1),D) -derivables) . X holds
I -TruthEval phi = 1

set II = U -InterpretersOf S;
let I be Element of U -InterpretersOf S; :: thesis: for H being I -satisfied set
for phi being wff string of S st [H,phi] in (((n + 1),D) -derivables) . X holds
I -TruthEval phi = 1

let H be I -satisfied set ; :: thesis: for phi being wff string of S st [H,phi] in (((n + 1),D) -derivables) . X holds
I -TruthEval phi = 1

let phi be wff string of S; :: thesis: ( [H,phi] in (((n + 1),D) -derivables) . X implies I -TruthEval phi = 1 )
assume A8: [H,phi] in (((n + 1),D) -derivables) . X ; :: thesis: I -TruthEval phi = 1
set Fam = { (R .: {oldSeqs}) where R is Subset of [:(bool (S -sequents)),(bool (S -sequents)):] : R in D } ;
(((n + 1),D) -derivables) . X = (OneStep D) . oldSeqs by A6, A7, FUNCT_1:13
.= union (union { (R .: {oldSeqs}) where R is Subset of [:(bool (S -sequents)),(bool (S -sequents)):] : R in D } ) by Lm5 ;
then consider x being set such that
A9: ( [H,phi] in x & x in union { (R .: {oldSeqs}) where R is Subset of [:(bool (S -sequents)),(bool (S -sequents)):] : R in D } ) by A8, TARSKI:def 4;
consider y being set such that
A10: ( x in y & y in { (R .: {oldSeqs}) where R is Subset of [:(bool (S -sequents)),(bool (S -sequents)):] : R in D } ) by A9, TARSKI:def 4;
consider R being Subset of [:(bool (S -sequents)),(bool (S -sequents)):] such that
A11: ( y = R .: {oldSeqs} & R in D ) by A10;
reconsider RR = R as Correct Rule of S by A1, A11;
reconsider newSeqs = RR . oldSeqs as S -correct Subset of (S -sequents) by Def68;
dom RR = bool (S -sequents) by FUNCT_2:def 1;
then ( y = Im (R,oldSeqs) & Im (RR,oldSeqs) = {(RR . oldSeqs)} ) by FUNCT_1:59, A11;
then [H,phi] in newSeqs by A9, TARSKI:def 1, A10;
hence I -TruthEval phi = 1 by FOMODEL2:def 44; :: thesis: verum
end;
hence (((n + 1),D) -derivables) . X is S -correct ; :: thesis: verum
end;
A12: for n being Nat holds S1[n] from NAT_1:sch 2(A2, A4);
now :: thesis: for phi being wff string of S
for X being set st phi is X,D -provable holds
for U being non empty set
for I being Element of U -InterpretersOf S st X is I -satisfied holds
I -TruthEval phi = 1
let phi be wff string of S; :: thesis: for X being set st phi is X,D -provable holds
for U being non empty set
for I being Element of U -InterpretersOf S st X is I -satisfied holds
I -TruthEval phi = 1

let X be set ; :: thesis: ( phi is X,D -provable implies for U being non empty set
for I being Element of U -InterpretersOf S st X is I -satisfied holds
I -TruthEval phi = 1 )

assume phi is X,D -provable ; :: thesis: for U being non empty set
for I being Element of U -InterpretersOf S st X is I -satisfied holds
I -TruthEval phi = 1

then consider H being set , m being Nat such that
A13: ( H c= X & [H,phi] is m, {} ,D -derivable ) ;
reconsider HH = H as Subset of X by A13;
reconsider seqt = [H,phi] as Element of S -sequents by Def2, A13;
reconsider okSeqs = ((m,D) -derivables) . e as S -correct Subset of (S -sequents) by A12;
hereby :: thesis: verum
let U be non empty set ; :: thesis: for I being Element of U -InterpretersOf S st X is I -satisfied holds
I -TruthEval phi = 1

set II = U -InterpretersOf S;
let I be Element of U -InterpretersOf S; :: thesis: ( X is I -satisfied implies I -TruthEval phi = 1 )
assume X is I -satisfied ; :: thesis: I -TruthEval phi = 1
then reconsider XX = X as I -satisfied set ;
reconsider HHH = HH as I -satisfied Subset of XX ;
[HHH,phi] in okSeqs by A13;
hence I -TruthEval phi = 1 by FOMODEL2:def 44; :: thesis: verum
end;
end;
hence D is Correct ; :: thesis: verum