Table of ContentsTable of Contents Mathbox for Paul Chapman < Previous   Next >
Related theorems
Unicode version

Theorem algrf 13739
Description: An algorithm is step a function F:S-->S on a state space S. An algorithm acts on an initial state A e. S by iteratively applying F to give A, (F` A), (F` (F` A)) and so on. An algorithm is said to halt if a fixed point of F is reached after a finite number of iterations.

The algorithm iterator R:NN0-->S "runs" the algorithm F so that (R` k) is the state after k iterations of F on the initial state A.

Domain and codomain of the algorithm iterator R. (Contributed by Paul Chapman, 31-Mar-2011.)

Hypotheses
Ref Expression
algrf.1 |- S e. _V
algrf.2 |- F:S-->S
algrf.3 |- R = ((F o. (1st |` (S X. S))) seq0 (NN0 X. {A}))
Assertion
Ref Expression
algrf |- (A e. S -> R:NN0-->S)

Proof of Theorem algrf
StepHypRef Expression
1 algrf.2 . . . . . . . 8 |- F:S-->S
2 f1stres 5034 . . . . . . . 8 |- (1st |` (S X. S)):(S X. S)-->S
3 fco 4573 . . . . . . . 8 |- ((F:S-->S /\ (1st |` (S X. S)):(S X. S)-->S) -> (F o. (1st |` (S X. S))):(S X. S)-->S)
41, 2, 3mp2an 761 . . . . . . 7 |- (F o. (1st |` (S X. S))):(S X. S)-->S
5 algrf.1 . . . . . . . . . 10 |- S e. _V
65, 5xpex 4096 . . . . . . . . 9 |- (S X. S) e. _V
7 fex 4595 . . . . . . . . 9 |- (((F o. (1st |` (S X. S))):(S X. S)-->S /\ (S X. S) e. _V) -> (F o. (1st |` (S X. S))) e. _V)
84, 6, 7mp2an 761 . . . . . . . 8 |- (F o. (1st |` (S X. S))) e. _V
9 nn0ex 7314 . . . . . . . . 9 |- NN0 e. _V
10 snex 3492 . . . . . . . . 9 |- {A} e. _V
119, 10xpex 4096 . . . . . . . 8 |- (NN0 X. {A}) e. _V
128, 11seq0cl 13620 . . . . . . 7 |- ((z e. NN0 /\ (NN0 X. {A}):NN0-->S /\ (F o. (1st |` (S X. S))):(S X. S)-->S) -> (((F o. (1st |` (S X. S))) seq0 (NN0 X. {A}))` z) e. S)
134, 12mp3an3 1180 . . . . . 6 |- ((z e. NN0 /\ (NN0 X. {A}):NN0-->S) -> (((F o. (1st |` (S X. S))) seq0 (NN0 X. {A}))` z) e. S)
14 fconstg 4604 . . . . . . 7 |- (A e. S -> (NN0 X. {A}):NN0-->{A})
15 snssi 3129 . . . . . . 7 |- (A e. S -> {A} C_ S)
16 fss 4571 . . . . . . 7 |- (((NN0 X. {A}):NN0-->{A} /\ {A} C_ S) -> (NN0 X. {A}):NN0-->S)
1714, 15, 16syl11anc 524 . . . . . 6 |- (A e. S -> (NN0 X. {A}):NN0-->S)
1813, 17sylan2 500 . . . . 5 |- ((z e. NN0 /\ A e. S) -> (((F o. (1st |` (S X. S))) seq0 (NN0 X. {A}))` z) e. S)
19 algrf.3 . . . . . 6 |- R = ((F o. (1st |` (S X. S))) seq0 (NN0 X. {A}))
2019fveq1i 4682 . . . . 5 |- (R` z) = (((F o. (1st |` (S X. S))) seq0 (NN0 X. {A}))` z)
2118, 20syl5eqel 1975 . . . 4 |- ((z e. NN0 /\ A e. S) -> (R` z) e. S)
2221ancoms 484 . . 3 |- ((A e. S /\ z e. NN0) -> (R` z) e. S)
2322r19.21aiva 2176 . 2 |- (A e. S -> A.z e. NN0 (R` z) e. S)
24 ffnfv 4801 . . 3 |- (R:NN0-->S <-> (R Fn NN0 /\ A.z e. NN0 (R` z) e. S))
258, 11seq0fn 7789 . . . 4 |- ((F o. (1st |` (S X. S))) seq0 (NN0 X. {A})) Fn NN0
2619fneq1i 4507 . . . 4 |- (R Fn NN0 <-> ((F o. (1st |` (S X. S))) seq0 (NN0 X. {A})) Fn NN0)
2725, 26mpbir 207 . . 3 |- R Fn NN0
2824, 27mpbiran 798 . 2 |- (R:NN0-->S <-> A.z e. NN0 (R` z) e. S)
2923, 28sylibr 217 1 |- (A e. S -> R:NN0-->S)
Colors of variables: wff set class
Syntax hints:   -> wi 3   /\ wa 240   = wceq 1298   e. wcel 1300  A.wral 2105  _Vcvv 2292   C_ wss 2593  {csn 3044   X. cxp 3984   |` cres 3988   o. ccom 3990   Fn wfn 3993  -->wf 3994  ` cfv 3998  (class class class)co 4884  1stc1st 5018  NN0cn0 6450   seq0 cseq0 7775
This theorem is referenced by:  algrp1 13742  alginv 13743  algcvg 13744  algcvga 13747  algfx 13748  eucalgcvga 13754  eucalg 13755  mulgcdlem2 13757
This theorem was proved from axioms:  ax-1 4  ax-2 5  ax-3 6  ax-mp 7  ax-7 1304  ax-gen 1305  ax-8 1306  ax-9 1307  ax-10 1308  ax-11 1309  ax-12 1310  ax-13 1311  ax-14 1312  ax-17 1317  ax-4 1319  ax-5o 1321  ax-6o 1324  ax-9o 1481  ax-10o 1500  ax-16 1580  ax-11o 1588  ax-ext 1865  ax-rep 3428  ax-sep 3438  ax-nul 3445  ax-pow 3481  ax-pr 3524  ax-un 3790  ax-inf2 5731
This theorem depends on definitions:  df-bi 164  df-or 241  df-an 242  df-3or 859  df-3an 860  df-ex 1327  df-sb 1536  df-eu 1775  df-mo 1776  df-clab 1872  df-cleq 1877  df-clel 1880  df-ne 2019  df-nel 2020  df-ral 2109  df-rex 2110  df-reu 2111  df-rab 2112  df-v 2294  df-sbc 2454  df-csb 2541  df-dif 2597  df-un 2600  df-in 2603  df-ss 2605  df-pss 2607  df-nul 2876  df-if 2983  df-pw 3035  df-sn 3049  df-pr 3050  df-tp 3052  df-op 3053  df-uni 3178  df-int 3215  df-iun 3257  df-br 3339  df-opab 3396  df-tr 3412  df-eprel 3583  df-id 3586  df-po 3591  df-so 3604  df-fr 3625  df-we 3644  df-ord 3660  df-on 3661  df-lim 3662  df-suc 3663  df-om 3950  df-xp 4000  df-rel 4001  df-cnv 4002  df-co 4003  df-dm 4004  df-rn 4005  df-res 4006  df-ima 4007  df-fun 4008  df-fn 4009  df-f 4010  df-f1 4011  df-fo 4012  df-f1o 4013  df-fv 4014  df-opr 4886  df-oprab 4887  df-mpt 5006  df-1st 5020  df-2nd 5021  df-iota 5089  df-rdg 5140  df-1o 5177  df-oadd 5179  df-omul 5180  df-er 5318  df-ec 5320  df-qs 5323  df-en 5427  df-dom 5428  df-sdom 5429  df-undef 5556  df-riota 5560  df-ni 6152  df-pli 6153  df-mi 6154  df-lti 6155  df-plpq 6187  df-mpq 6188  df-enq 6189  df-nq 6190  df-plq 6191  df-mq 6192  df-rq 6193  df-ltq 6194  df-1q 6195  df-np 6238  df-1p 6239  df-plp 6240  df-mp 6241  df-ltp 6242  df-plpr 6316  df-mpr 6317  df-enr 6318  df-nr 6319  df-plr 6320  df-mr 6321  df-ltr 6322  df-0r 6323  df-1r 6324  df-m1r 6325  df-c 6392  df-0 6393  df-1 6394  df-i 6395  df-r 6396  df-plus 6397  df-mul 6398  df-lt 6399  df-sub 6511  df-neg 6513  df-pnf 6654  df-mnf 6655  df-xr 6656  df-ltxr 6657  df-le 6658  df-n 7108  df-n0 7309  df-z 7345  df-uz 7587  df-seq1 7721  df-shft 7754  df-seqz 7776  df-seq0 7777
Copyright terms: Public domain