This program can calculate factorials up to 610!, but it does not print the results. The extended range -\compared to EPF1\- is obtained by truncating all trailing zeroes. The program was originally written by Frank\M. Fujimoto, who submitted it to PPX in 1979 (PPX\#398171). Frank's version didn't use Fast Mode, it was still unknown at the time.
A first conversion to Fast Mode was done by Palmer O. Hanson, editor of TI\PPC Notes. His version appeared in TI\PPC Notes V8N5P4-5. It worked quite satisfactory, but I simply didn't like the appearance.
In the process of getting it to look nicer, I made the following changes:
The method used in this program is virtually the same as the one used in EPF1. The differences are:
If you want to find out in detail how the program functions, you should SST through steps 011-134 several times. (A PC-100 in TRACE-mode would also be useful)
The user instructions for this program are of the same simplicity as those for EPF1.
Think about leading and trailing zeroes!
If you consider the above method of displaying the result not "Anwenderfreundlich", you are right. To make things a little easier, you can enter the following short program from the keyboard when the program has finished. After having entered it, you can press\E, repeatedly followed by R/S to display the result. (If you have a PC-100, you can of course change steps 009 and 016 into PRT) The read-out is complete when a flashing zero appears. .sk Listing of the read-out program .sk
000 76 LBL 007 00 00 014 58 FIX 021 00 00 001 15 E 008 59 INT 015 07 07 022 06 06 002 82 HIR 009 91 R/S 016 91 R/S 023 00 0 003 18 18 010 73 RC* 017 22 INV 024 69 OP 004 42 STO 011 00 00 018 58 FIX 025 68 68 005 00 00 012 22 INV 019 97 DSZ 026 92 RTN 006 73 RC* 013 59 INT 020 00 00 <\pre>Listing of the TI-59 Version
000 92 RTN 060 65 x 120 01 1 180 00 0 001 01 1 061 01 1 121 52 EE 181 00 0 002 00 0 062 52 EE 122 07 7 182 00 0 003 69 OP 063 06 6 123 54 ) 183 00 0 004 17 17 064 54 ) 124 63 EX* 184 00 0 005 47 CMS 065 74 SM* 125 00 00 185 00 0 006 32 X:T 066 00 00 126 97 DSZ 186 00 0 007 42 STO 067 53 ( 127 00 00 187 00 0 008 01 01 068 82 HIR 128 01 01 188 00 0 009 82 HIR 069 16 16 129 03 03 189 00 0 010 18 18 070 55 ö 130 82 HIR 190 00 0 011 53 ( 071 01 1 131 18 18 191 00 0 012 29 CP 072 52 EE 132 77 XòT 192 00 0 013 85 + 073 07 7 133 00 00 193 00 0 014 02 2 074 85 + 134 11 11 194 00 0 015 82 HIR 075 69 OP 135 09 9 195 00 0 016 58 58 076 20 20 136 09 9 196 00 0 017 01 1 077 73 RC* 137 42 STO 197 00 0 018 42 STO 078 00 00 138 00 00 198 00 0 019 00 00 079 22 INV 139 76 LBL 199 76 LBL 020 85 + 080 67 X=T 140 69 OP 200 11 A 021 33 Xý 081 00 00 141 30 30 201 50 IxI 022 54 ) 082 28 28 142 73 RC* 202 59 INT 023 82 HIR 083 54 ) 143 00 00 203 32 X:T 024 05 05 084 72 ST* 144 67 X=T 204 06 6 025 43 RCL 085 00 00 145 01 01 205 01 1 026 01 01 086 53 ( 146 40 40 206 00 0 027 53 ( 087 43 RCL 147 43 RCL 207 77 XòT 028 22 INV 088 01 01 148 00 00 208 02 02 029 59 INT 089 65 x 149 82 HIR 209 15 15 030 65 x 090 01 1 150 08 08 210 00 0 031 82 HIR 091 52 EE 151 32 X:T 211 32 X:T 032 15 15 092 05 5 152 25 CLR 212 69 OP 033 75 - 093 54 ) 153 76 LBL 213 68 68 034 59 INT 094 22 INV 154 15 E 214 92 RTN 035 82 HIR 095 59 INT 155 82 HIR 215 53 ( 036 06 06 096 22 INV 156 17 17 216 32 X:T 037 54 ) 097 67 X=T 157 66 PAU 217 75 - 038 63 EX* 098 01 01 158 81 RST 218 02 2 039 00 00 099 30 30 159 00 0 219 54 ) 040 53 ( 100 02 2 160 00 0 220 29 CP 041 53 ( 101 82 HIR 161 00 0 221 37 P/R 042 53 ( 102 37 37 162 00 0 222 01 1 043 59 INT 103 53 ( 163 00 0 223 52 EE 044 65 x 104 22 INV 164 00 0 224 07 7 045 82 HIR 105 59 INT 165 00 0 225 94 +/- 046 15 15 106 65 x 166 00 0 226 22 INV 047 85 + 107 01 1 167 00 0 227 57 ENG 048 82 HIR 108 52 EE 168 00 0 228 32 X:T 049 16 16 109 05 5 169 00 0 229 22 INV 050 54 ) 110 64 PD* 170 00 0 230 58 FIX 051 55 ö 111 00 00 171 00 0 231 09 9 052 01 1 112 01 1 172 00 0 232 69 OP 053 52 EE 113 52 EE 173 00 0 233 17 17 054 06 6 114 06 6 174 00 0 234 60 DEG 055 75 - 115 85 + 175 00 0 235 04 4 056 59 INT 116 73 RC* 176 00 0 236 05 5 057 82 HIR 117 00 00 177 00 0 237 30 TAN 058 06 06 118 59 INT 178 00 0 238 33 Xý 059 54 ) 119 55 ö 179 00 0 239 86 STF <\pre>The TI-58 Version
User Instructions
The user instructions of this version are equal to those of the TI-59 version. The difference is the fact that this version can only calculate factorials up to 284!, so instead of seeing a flashing display when you enter a number greater than 610, you will now see a flashing display for entries greater then 284.
Listing of the TI-58 Version
To obtain the TI-58 version of the program, you first key in the TI-59 version. Next you make the following modifications in the indicated order:
- Change steps 204-206 into "2" "8" "4".
- Change step 218 into "18".
- Delete steps 231-233.
- Change step 001 into "4".
- Change step 082 into "27".
- Change step 099 into "29".
- Change step 129 into "02".
- Change step 135 into "10".
- Change step 136 into "3".
- Change step 147 into "40".
- Delete step 002.
- Insert four zeroes after step 157.
Instead of first entering the TI-59 version, it is of course also possible to make the above changes directly while keying in the program.
Some last notes about the programs