Metamath Proof Explorer


Theorem subfaclim

Description: The subfactorial converges rapidly to N ! / _e . This is part of Metamath 100 proof #88. (Contributed by Mario Carneiro, 23-Jan-2015)

Ref Expression
Hypotheses derang.d D = x Fin f | f : x 1-1 onto x y x f y y
subfac.n S = n 0 D 1 n
Assertion subfaclim N N ! e S N < 1 N

Proof

Step Hyp Ref Expression
1 derang.d D = x Fin f | f : x 1-1 onto x y x f y y
2 subfac.n S = n 0 D 1 n
3 nnnn0 N N 0
4 faccl N 0 N !
5 3 4 syl N N !
6 5 nncnd N N !
7 ere e
8 7 recni e
9 epos 0 < e
10 7 9 gt0ne0ii e 0
11 divcl N ! e e 0 N ! e
12 8 10 11 mp3an23 N ! N ! e
13 6 12 syl N N ! e
14 1 2 subfacf S : 0 0
15 14 ffvelrni N 0 S N 0
16 3 15 syl N S N 0
17 16 nn0cnd N S N
18 13 17 subcld N N ! e S N
19 18 abscld N N ! e S N
20 peano2nn N N + 1
21 20 peano2nnd N N + 1 + 1
22 21 nnred N N + 1 + 1
23 20 20 nnmulcld N N + 1 N + 1
24 22 23 nndivred N N + 1 + 1 N + 1 N + 1
25 nnrecre N 1 N
26 eqid n 0 1 n n ! = n 0 1 n n !
27 eqid n 0 1 n n ! = n 0 1 n n !
28 eqid n 0 1 N + 1 N + 1 ! 1 N + 1 + 1 n = n 0 1 N + 1 N + 1 ! 1 N + 1 + 1 n
29 neg1cn 1
30 29 a1i N 1
31 ax-1cn 1
32 31 absnegi 1 = 1
33 abs1 1 = 1
34 32 33 eqtri 1 = 1
35 1le1 1 1
36 34 35 eqbrtri 1 1
37 36 a1i N 1 1
38 26 27 28 20 30 37 eftlub N k N + 1 n 0 1 n n ! k 1 N + 1 N + 1 + 1 N + 1 ! N + 1
39 20 nnnn0d N N + 1 0
40 eluznn0 N + 1 0 k N + 1 k 0
41 39 40 sylan N k N + 1 k 0
42 26 eftval k 0 n 0 1 n n ! k = 1 k k !
43 41 42 syl N k N + 1 n 0 1 n n ! k = 1 k k !
44 43 sumeq2dv N k N + 1 n 0 1 n n ! k = k N + 1 1 k k !
45 44 fveq2d N k N + 1 n 0 1 n n ! k = k N + 1 1 k k !
46 34 oveq1i 1 N + 1 = 1 N + 1
47 20 nnzd N N + 1
48 1exp N + 1 1 N + 1 = 1
49 47 48 syl N 1 N + 1 = 1
50 46 49 syl5eq N 1 N + 1 = 1
51 50 oveq1d N 1 N + 1 N + 1 + 1 N + 1 ! N + 1 = 1 N + 1 + 1 N + 1 ! N + 1
52 faccl N + 1 0 N + 1 !
53 39 52 syl N N + 1 !
54 53 20 nnmulcld N N + 1 ! N + 1
55 22 54 nndivred N N + 1 + 1 N + 1 ! N + 1
56 55 recnd N N + 1 + 1 N + 1 ! N + 1
57 56 mulid2d N 1 N + 1 + 1 N + 1 ! N + 1 = N + 1 + 1 N + 1 ! N + 1
58 51 57 eqtrd N 1 N + 1 N + 1 + 1 N + 1 ! N + 1 = N + 1 + 1 N + 1 ! N + 1
59 38 45 58 3brtr3d N k N + 1 1 k k ! N + 1 + 1 N + 1 ! N + 1
60 eqid N + 1 = N + 1
61 eftcl 1 k 0 1 k k !
62 29 61 mpan k 0 1 k k !
63 41 62 syl N k N + 1 1 k k !
64 26 eftlcvg 1 N + 1 0 seq N + 1 + n 0 1 n n ! dom
65 29 39 64 sylancr N seq N + 1 + n 0 1 n n ! dom
66 60 47 43 63 65 isumcl N k N + 1 1 k k !
67 66 abscld N k N + 1 1 k k !
68 5 nnred N N !
69 5 nngt0d N 0 < N !
70 lemul2 k N + 1 1 k k ! N + 1 + 1 N + 1 ! N + 1 N ! 0 < N ! k N + 1 1 k k ! N + 1 + 1 N + 1 ! N + 1 N ! k N + 1 1 k k ! N ! N + 1 + 1 N + 1 ! N + 1
71 67 55 68 69 70 syl112anc N k N + 1 1 k k ! N + 1 + 1 N + 1 ! N + 1 N ! k N + 1 1 k k ! N ! N + 1 + 1 N + 1 ! N + 1
72 59 71 mpbid N N ! k N + 1 1 k k ! N ! N + 1 + 1 N + 1 ! N + 1
73 1 2 subfacval2 N 0 S N = N ! k = 0 N 1 k k !
74 3 73 syl N S N = N ! k = 0 N 1 k k !
75 nncn N N
76 pncan N 1 N + 1 - 1 = N
77 75 31 76 sylancl N N + 1 - 1 = N
78 77 oveq2d N 0 N + 1 - 1 = 0 N
79 78 sumeq1d N k = 0 N + 1 - 1 1 k k ! = k = 0 N 1 k k !
80 79 oveq2d N N ! k = 0 N + 1 - 1 1 k k ! = N ! k = 0 N 1 k k !
81 74 80 eqtr4d N S N = N ! k = 0 N + 1 - 1 1 k k !
82 81 oveq1d N S N + N ! k N + 1 1 k k ! = N ! k = 0 N + 1 - 1 1 k k ! + N ! k N + 1 1 k k !
83 divrec N ! e e 0 N ! e = N ! 1 e
84 8 10 83 mp3an23 N ! N ! e = N ! 1 e
85 6 84 syl N N ! e = N ! 1 e
86 df-e e = e 1
87 86 oveq2i 1 e = 1 e 1
88 efneg 1 e 1 = 1 e 1
89 31 88 ax-mp e 1 = 1 e 1
90 efval 1 e 1 = k 0 1 k k !
91 29 90 ax-mp e 1 = k 0 1 k k !
92 87 89 91 3eqtr2i 1 e = k 0 1 k k !
93 nn0uz 0 = 0
94 42 adantl N k 0 n 0 1 n n ! k = 1 k k !
95 62 adantl N k 0 1 k k !
96 0nn0 0 0
97 26 eftlcvg 1 0 0 seq 0 + n 0 1 n n ! dom
98 29 96 97 mp2an seq 0 + n 0 1 n n ! dom
99 98 a1i N seq 0 + n 0 1 n n ! dom
100 93 60 39 94 95 99 isumsplit N k 0 1 k k ! = k = 0 N + 1 - 1 1 k k ! + k N + 1 1 k k !
101 92 100 syl5eq N 1 e = k = 0 N + 1 - 1 1 k k ! + k N + 1 1 k k !
102 101 oveq2d N N ! 1 e = N ! k = 0 N + 1 - 1 1 k k ! + k N + 1 1 k k !
103 fzfid N 0 N + 1 - 1 Fin
104 elfznn0 k 0 N + 1 - 1 k 0
105 104 adantl N k 0 N + 1 - 1 k 0
106 29 105 61 sylancr N k 0 N + 1 - 1 1 k k !
107 103 106 fsumcl N k = 0 N + 1 - 1 1 k k !
108 6 107 66 adddid N N ! k = 0 N + 1 - 1 1 k k ! + k N + 1 1 k k ! = N ! k = 0 N + 1 - 1 1 k k ! + N ! k N + 1 1 k k !
109 85 102 108 3eqtrd N N ! e = N ! k = 0 N + 1 - 1 1 k k ! + N ! k N + 1 1 k k !
110 82 109 eqtr4d N S N + N ! k N + 1 1 k k ! = N ! e
111 6 66 mulcld N N ! k N + 1 1 k k !
112 13 17 111 subaddd N N ! e S N = N ! k N + 1 1 k k ! S N + N ! k N + 1 1 k k ! = N ! e
113 110 112 mpbird N N ! e S N = N ! k N + 1 1 k k !
114 113 fveq2d N N ! e S N = N ! k N + 1 1 k k !
115 6 66 absmuld N N ! k N + 1 1 k k ! = N ! k N + 1 1 k k !
116 5 nnnn0d N N ! 0
117 116 nn0ge0d N 0 N !
118 68 117 absidd N N ! = N !
119 118 oveq1d N N ! k N + 1 1 k k ! = N ! k N + 1 1 k k !
120 114 115 119 3eqtrd N N ! e S N = N ! k N + 1 1 k k !
121 facp1 N 0 N + 1 ! = N ! N + 1
122 3 121 syl N N + 1 ! = N ! N + 1
123 122 oveq1d N N + 1 ! N + 1 = N ! N + 1 N + 1
124 20 nncnd N N + 1
125 6 124 124 mulassd N N ! N + 1 N + 1 = N ! N + 1 N + 1
126 123 125 eqtr2d N N ! N + 1 N + 1 = N + 1 ! N + 1
127 126 oveq2d N N ! N + 1 + 1 N ! N + 1 N + 1 = N ! N + 1 + 1 N + 1 ! N + 1
128 21 nncnd N N + 1 + 1
129 23 nncnd N N + 1 N + 1
130 23 nnne0d N N + 1 N + 1 0
131 5 nnne0d N N ! 0
132 128 129 6 130 131 divcan5d N N ! N + 1 + 1 N ! N + 1 N + 1 = N + 1 + 1 N + 1 N + 1
133 54 nncnd N N + 1 ! N + 1
134 54 nnne0d N N + 1 ! N + 1 0
135 6 128 133 134 divassd N N ! N + 1 + 1 N + 1 ! N + 1 = N ! N + 1 + 1 N + 1 ! N + 1
136 127 132 135 3eqtr3d N N + 1 + 1 N + 1 N + 1 = N ! N + 1 + 1 N + 1 ! N + 1
137 72 120 136 3brtr4d N N ! e S N N + 1 + 1 N + 1 N + 1
138 nnmulcl N + 1 + 1 N N + 1 + 1 N
139 21 138 mpancom N N + 1 + 1 N
140 139 nnred N N + 1 + 1 N
141 140 ltp1d N N + 1 + 1 N < N + 1 + 1 N + 1
142 129 mulid2d N 1 N + 1 N + 1 = N + 1 N + 1
143 31 a1i N 1
144 75 143 124 adddird N N + 1 N + 1 = N N + 1 + 1 N + 1
145 75 124 mulcomd N N N + 1 = N + 1 N
146 124 mulid2d N 1 N + 1 = N + 1
147 145 146 oveq12d N N N + 1 + 1 N + 1 = N + 1 N + N + 1
148 124 143 75 adddird N N + 1 + 1 N = N + 1 N + 1 N
149 148 oveq1d N N + 1 + 1 N + 1 = N + 1 N + 1 N + 1
150 75 mulid2d N 1 N = N
151 150 oveq2d N N + 1 N + 1 N = N + 1 N + N
152 151 oveq1d N N + 1 N + 1 N + 1 = N + 1 N + N + 1
153 124 75 mulcld N N + 1 N
154 153 75 143 addassd N N + 1 N + N + 1 = N + 1 N + N + 1
155 149 152 154 3eqtrd N N + 1 + 1 N + 1 = N + 1 N + N + 1
156 147 155 eqtr4d N N N + 1 + 1 N + 1 = N + 1 + 1 N + 1
157 142 144 156 3eqtrd N 1 N + 1 N + 1 = N + 1 + 1 N + 1
158 141 157 breqtrrd N N + 1 + 1 N < 1 N + 1 N + 1
159 nnre N N
160 nngt0 N 0 < N
161 159 160 jca N N 0 < N
162 1red N 1
163 nnre N + 1 N + 1 N + 1 N + 1
164 nngt0 N + 1 N + 1 0 < N + 1 N + 1
165 163 164 jca N + 1 N + 1 N + 1 N + 1 0 < N + 1 N + 1
166 23 165 syl N N + 1 N + 1 0 < N + 1 N + 1
167 lt2mul2div N + 1 + 1 N 0 < N 1 N + 1 N + 1 0 < N + 1 N + 1 N + 1 + 1 N < 1 N + 1 N + 1 N + 1 + 1 N + 1 N + 1 < 1 N
168 22 161 162 166 167 syl22anc N N + 1 + 1 N < 1 N + 1 N + 1 N + 1 + 1 N + 1 N + 1 < 1 N
169 158 168 mpbid N N + 1 + 1 N + 1 N + 1 < 1 N
170 19 24 25 137 169 lelttrd N N ! e S N < 1 N