Metamath Proof Explorer


Theorem algfx

Description: If F reaches a fixed point when the countdown function C reaches 0 , F remains fixed after N steps. (Contributed by Paul Chapman, 22-Jun-2011)

Ref Expression
Hypotheses algcvga.1 F : S S
algcvga.2 R = seq 0 F 1 st 0 × A
algcvga.3 C : S 0
algcvga.4 z S C F z 0 C F z < C z
algcvga.5 N = C A
algfx.6 z S C z = 0 F z = z
Assertion algfx A S K N R K = R N

Proof

Step Hyp Ref Expression
1 algcvga.1 F : S S
2 algcvga.2 R = seq 0 F 1 st 0 × A
3 algcvga.3 C : S 0
4 algcvga.4 z S C F z 0 C F z < C z
5 algcvga.5 N = C A
6 algfx.6 z S C z = 0 F z = z
7 3 ffvelrni A S C A 0
8 5 7 eqeltrid A S N 0
9 8 nn0zd A S N
10 uzval N N = z | N z
11 10 eleq2d N K N K z | N z
12 11 pm5.32i N K N N K z | N z
13 fveqeq2 m = N R m = R N R N = R N
14 13 imbi2d m = N A S R m = R N A S R N = R N
15 fveqeq2 m = k R m = R N R k = R N
16 15 imbi2d m = k A S R m = R N A S R k = R N
17 fveqeq2 m = k + 1 R m = R N R k + 1 = R N
18 17 imbi2d m = k + 1 A S R m = R N A S R k + 1 = R N
19 fveqeq2 m = K R m = R N R K = R N
20 19 imbi2d m = K A S R m = R N A S R K = R N
21 eqidd A S R N = R N
22 21 a1i N A S R N = R N
23 10 eleq2d N k N k z | N z
24 23 pm5.32i N k N N k z | N z
25 eluznn0 N 0 k N k 0
26 8 25 sylan A S k N k 0
27 nn0uz 0 = 0
28 0zd A S 0
29 id A S A S
30 1 a1i A S F : S S
31 27 2 28 29 30 algrp1 A S k 0 R k + 1 = F R k
32 26 31 syldan A S k N R k + 1 = F R k
33 27 2 28 29 30 algrf A S R : 0 S
34 33 ffvelrnda A S k 0 R k S
35 26 34 syldan A S k N R k S
36 1 2 3 4 5 algcvga A S k N C R k = 0
37 36 imp A S k N C R k = 0
38 fveqeq2 z = R k C z = 0 C R k = 0
39 fveq2 z = R k F z = F R k
40 id z = R k z = R k
41 39 40 eqeq12d z = R k F z = z F R k = R k
42 38 41 imbi12d z = R k C z = 0 F z = z C R k = 0 F R k = R k
43 42 6 vtoclga R k S C R k = 0 F R k = R k
44 35 37 43 sylc A S k N F R k = R k
45 32 44 eqtrd A S k N R k + 1 = R k
46 45 eqeq1d A S k N R k + 1 = R N R k = R N
47 46 biimprd A S k N R k = R N R k + 1 = R N
48 47 expcom k N A S R k = R N R k + 1 = R N
49 48 adantl N k N A S R k = R N R k + 1 = R N
50 24 49 sylbir N k z | N z A S R k = R N R k + 1 = R N
51 50 a2d N k z | N z A S R k = R N A S R k + 1 = R N
52 14 16 18 20 22 51 uzind3 N K z | N z A S R K = R N
53 12 52 sylbi N K N A S R K = R N
54 53 ex N K N A S R K = R N
55 54 com3r A S N K N R K = R N
56 9 55 mpd A S K N R K = R N