Changeset 35266 in project
 Timestamp:
 03/08/18 18:51:20 (4 months ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

wiki/eggref/4/mathh
r35123 r35266 33 33 ==== besselyn 34 34 35 <procedure>(besselj0 N) => real</procedure>36 <procedure>(besselj1 N) => real</procedure>37 <procedure>(besseljn O N) => real</procedure>38 <procedure>(bessely0 N) => real</procedure>39 <procedure>(bessely1 N) => real</procedure>40 <procedure>(besselyn O N) => real</procedure>35 <procedure>(besselj0 N) > real</procedure> 36 <procedure>(besselj1 N) > real</procedure> 37 <procedure>(besseljn O N) > real</procedure> 38 <procedure>(bessely0 N) > real</procedure> 39 <procedure>(bessely1 N) > real</procedure> 40 <procedure>(besselyn O N) > real</procedure> 41 41 42 42 ==== cosh … … 47 47 ==== atanh 48 48 49 <procedure>(cosh N) => real</procedure>50 <procedure>(sinh N) => real</procedure>51 <procedure>(tanh N) => real</procedure>52 <procedure>(acosh N) => real</procedure>53 <procedure>(asinh N) => real</procedure>54 <procedure>(atanh N) => real</procedure>49 <procedure>(cosh N) > real</procedure> 50 <procedure>(sinh N) > real</procedure> 51 <procedure>(tanh N) > real</procedure> 52 <procedure>(acosh N) > real</procedure> 53 <procedure>(asinh N) > real</procedure> 54 <procedure>(atanh N) > real</procedure> 55 55 56 56 ==== hypot 57 57 58 <procedure>(hypot N1 N2) => real</procedure>58 <procedure>(hypot N1 N2) > real</procedure> 59 59 60 60 ==== gamma 61 61 ==== lgamma 62 62 63 <procedure>(gamma N) => real</procedure>64 <procedure>(lgamma N) => real</procedure>63 <procedure>(gamma N) > real</procedure> 64 <procedure>(lgamma N) > real</procedure> 65 65 66 66 ==== erf 67 67 ==== erfc 68 68 69 <procedure>(erf N) => real</procedure>70 <procedure>(erfc N) => real</procedure>69 <procedure>(erf N) > real</procedure> 70 <procedure>(erfc N) > real</procedure> 71 71 72 72 ==== log10 … … 74 74 ==== log1p 75 75 76 <procedure>(log10 N) => real</procedure>77 <procedure>(log2 N) => real</procedure>78 <procedure>(log1p N) => real</procedure>76 <procedure>(log10 N) > real</procedure> 77 <procedure>(log2 N) > real</procedure> 78 <procedure>(log1p N) > real</procedure> 79 79 80 80 ==== logwithbase 81 81 82 <procedure>(logwithbase N) => (procedure (real) real)</procedure>82 <procedure>(logwithbase N) > (procedure (real) real)</procedure> 83 83 84 84 Returns a monadic function, the logarithm of base {{N}}. … … 87 87 ==== scalbn 88 88 89 <procedure>(ldexp N P2) => real</procedure>90 <procedure>(scalbn N P2) => real</procedure>89 <procedure>(ldexp N P2) > real</procedure> 90 <procedure>(scalbn N P2) > real</procedure> 91 91 92 92 ==== cbrt 93 93 94 <procedure>(cbrt N) => real</procedure>94 <procedure>(cbrt N) > real</procedure> 95 95 96 96 ==== nextafter 97 97 98 <procedure>(nextafter N M) => real</procedure>98 <procedure>(nextafter N M) > real</procedure> 99 99 100 100 Returns the next {{N}} in the direction of {{M}}. … … 102 102 ==== fpmod 103 103 104 <procedure>(fpmod N M) => real</procedure>104 <procedure>(fpmod N M) > real</procedure> 105 105 106 106 Returns the modulus of {{N}} for {{M}}. … … 108 108 ==== modf 109 109 110 <procedure>(modf N) => (values real integer)</procedure>110 <procedure>(modf N) > (values real integer)</procedure> 111 111 112 112 Returns two values, the integral and fractional components of {{N}}. … … 114 114 ==== frexp 115 115 116 <procedure>(frexp N) => (values real real)</procedure>116 <procedure>(frexp N) > (values real real)</procedure> 117 117 118 118 Returns two values, the fraction and the exponent components of {{N}}. … … 120 120 ==== signbit 121 121 122 <procedure>(signbit N) => boolean</procedure>122 <procedure>(signbit N) > boolean</procedure> 123 123 124 124 Returns {{#t}} when negative, {{#f}} otherwise. … … 126 126 ==== copysign 127 127 128 <procedure>(copysign N M) => real</procedure>128 <procedure>(copysign N M) > real</procedure> 129 129 130 130 Returns {{N}} with same sign as {{M}}. … … 132 132 ==== fpclassify 133 133 134 <procedure>(fpclassify N) => symbol</procedure>134 <procedure>(fpclassify N) > symbol</procedure> 135 135 136 136 Returns a symbol denoting the floatingpoint kind of {{N}}. … … 145 145 ==== fpclass 146 146 147 <procedure>(fpclass N) => symbol</procedure>147 <procedure>(fpclass N) > symbol</procedure> 148 148 149 149 Returns a symbol denoting the floatingpoint kind of {{N}}. … … 176 176 ==== fprandom 177 177 178 <procedure>(fprandom [N]) => flonum</procedure>178 <procedure>(fprandom [N]) > flonum</procedure> 179 179 180 180 Returns {{flonum}} in {{[0 1)}}. … … 184 184 ==== fpzero? 185 185 186 <procedure>(fpzero? N) => boolean</procedure>186 <procedure>(fpzero? N) > boolean</procedure> 187 187 188 188 ==== fppositive? 189 189 190 <procedure>(fppositive? N) => boolean</procedure> 190 <procedure>(fppositive? N) > boolean</procedure> 191 192 Note that {{0.0}} is '''not''' positive, due to {{(fl<? 0.0 0.0)}}. 191 193 192 194 ==== fpcardinal? 193 195 194 <procedure>(fpcardinal? N) => boolean</procedure> 196 <procedure>(fpcardinal? N) > boolean</procedure> 197 198 Note that {{0.0}} is '''not''' cardinal, due to {{(fl<? 0.0 0.0)}}. 195 199 196 200 ==== fpnegative? 197 201 198 <procedure>(fpnegative? N) => boolean</procedure> 202 <procedure>(fpnegative? N) > boolean</procedure> 203 204 Note that {{0.0}} is '''not''' negative, due to {{(fl<? 0.0 0.0)}}. 199 205 200 206 ==== fpeven? 201 207 202 <procedure>(fpeven? N) => boolean</procedure>208 <procedure>(fpeven? N) > boolean</procedure> 203 209 204 210 ==== fpodd? 205 211 206 <procedure>(fpodd? N) => boolean</procedure>212 <procedure>(fpodd? N) > boolean</procedure> 207 213 208 214 ==== fpclosedright? 209 215 ==== fpclosedr? 210 216 211 <procedure>(fpclosedright? L N H) => boolean</procedure>212 <procedure>(fpclosedr? L N H) => boolean</procedure>217 <procedure>(fpclosedright? L N H) > boolean</procedure> 218 <procedure>(fpclosedr? L N H) > boolean</procedure> 213 219 214 220 Returns {{N}} in {{(L .. H]}}. … … 220 226 Returns {{N}} in {{[L .. H]}}. 221 227 222 <procedure>(fpclosed? L N H) => boolean</procedure>228 <procedure>(fpclosed? L N H) > boolean</procedure> 223 229 224 230 {{N}}, {{L}} & {{H}} are {{flonum}} low & high limits. … … 229 235 Returns {{N}} in {{[L .. H)}}. 230 236 231 <procedure>(fpclosedleft? L N H) => boolean</procedure>232 <procedure>(fpclosedl? L N H) => boolean</procedure>237 <procedure>(fpclosedleft? L N H) > boolean</procedure> 238 <procedure>(fpclosedl? L N H) > boolean</procedure> 233 239 234 240 {{N}}, {{L}} & {{H}} are {{flonum}} low & high limits. … … 236 242 ==== fpadd1 237 243 238 <procedure>(fpadd1 N) => flonum</procedure>244 <procedure>(fpadd1 N) > flonum</procedure> 239 245 240 246 ==== fpsub1 241 247 242 <procedure>(fpsub1 N) => flonum</procedure>248 <procedure>(fpsub1 N) > flonum</procedure> 243 249 244 250 ==== fpmodulo 245 251 246 <procedure>(fpmodulo N1 N2) => flonum</procedure>252 <procedure>(fpmodulo N1 N2) > flonum</procedure> 247 253 248 254 ==== fpquotient 249 255 250 <procedure>(fpquotient N1 N2) => flonum</procedure>256 <procedure>(fpquotient N1 N2) > flonum</procedure> 251 257 252 258 ==== fpremainder 253 259 254 <procedure>(fpremainder N1 N2) => flonum</procedure>260 <procedure>(fpremainder N1 N2) > flonum</procedure> 255 261 256 262 ==== fpfraction 257 263 258 <procedure>(fpfraction N) => flonum</procedure>264 <procedure>(fpfraction N) > flonum</procedure> 259 265 260 266 ==== fptruncate/precision 261 267 262 <procedure>(fptruncate/precision N [P 4]) => flonum</procedure>268 <procedure>(fptruncate/precision N [P 4]) > flonum</procedure> 263 269 264 270 ==== fpround/precision 265 271 266 <procedure>(fpround/precision N [P 4]) => flonum</procedure>272 <procedure>(fpround/precision N [P 4]) > flonum</procedure> 267 273 268 274 ==== fpceiling/precision 269 275 270 <procedure>(fpceiling/precision N [P 4]) => flonum</procedure>276 <procedure>(fpceiling/precision N [P 4]) > flonum</procedure> 271 277 272 278 ==== fpfloor/precision 273 279 274 <procedure>(fpfloor/precision N [P 4]) => flonum</procedure>280 <procedure>(fpfloor/precision N [P 4]) > flonum</procedure> 275 281 276 282 ==== fp~= 277 283 278 <procedure>(fp~= N1 N2 [EPS flonumepsilon]) => flonum</procedure>284 <procedure>(fp~= N1 N2 [EPS flonumepsilon]) > flonum</procedure> 279 285 280 286 Compare floatingpoint values {{N1}} and {{N2}} within some {{flonum}} epsilon … … 283 289 ==== fp~<= 284 290 285 <procedure>(fp~<= N) => boolean</procedure>291 <procedure>(fp~<= N) > boolean</procedure> 286 292 287 293 ==== fp~>= 288 294 289 <procedure>(fp~>= N) => boolean</procedure>295 <procedure>(fp~>= N) > boolean</procedure> 290 296 291 297 ==== fpsqr 292 298 293 <procedure>(fpsqr N) => flonum</procedure>299 <procedure>(fpsqr N) > flonum</procedure> 294 300 295 301 ==== fpcub 296 302 297 <procedure>(fpcub N) => flonum</procedure>303 <procedure>(fpcub N) > flonum</procedure> 298 304 299 305 ==== fpdegree>radian 300 306 301 <procedure>(fpdegree>radian N) => flonum</procedure>307 <procedure>(fpdegree>radian N) > flonum</procedure> 302 308 303 309 ==== fpradian>degree 304 310 305 <procedure>(fpradian>degree N) => flonum</procedure>311 <procedure>(fpradian>degree N) > flonum</procedure> 306 312 307 313 ==== fpdistance 308 314 309 <procedure>(fpdistance X1 Y1 X2 Y2) => flonum</procedure>315 <procedure>(fpdistance X1 Y1 X2 Y2) > flonum</procedure> 310 316 311 317 Pythagorean distance between the points {{X1 Y1}} and {{X2 Y2}}. … … 313 319 ==== fpdistance* 314 320 315 <procedure>(fpdistance* X1 Y1 X2 Y2) => flonum</procedure>321 <procedure>(fpdistance* X1 Y1 X2 Y2) > flonum</procedure> 316 322 317 323 Pythagorean distance, inaccurate but useful for relative comparisons. … … 319 325 ==== fpmaxandmin 320 326 321 <procedure>(fpmaxandmin N ...) => (values flonum flonum)</procedure>327 <procedure>(fpmaxandmin N ...) > (values flonum flonum)</procedure> 322 328 323 329 Returns the maximum & minimum values for the {{flonum}}s {{N ...}}. … … 325 331 ==== fpprecisionfactor 326 332 327 <procedure>(fpprecisionfactor P [BASE 10.0]) => flonum</procedure>333 <procedure>(fpprecisionfactor P [BASE 10.0]) > flonum</procedure> 328 334 329 335 Returns factor for {{P}} decimal digits precision. … … 342 348 ==== fxrandom 343 349 344 <procedure>(fxrandom [N]) => fixnum</procedure>350 <procedure>(fxrandom [N]) > fixnum</procedure> 345 351 346 352 {{N}} {{fixnum}} limit. … … 348 354 ==== fxzero? 349 355 350 <procedure>(fxzero? N) => boolean</procedure>356 <procedure>(fxzero? N) > boolean</procedure> 351 357 352 358 ==== fxpositive? 353 359 354 <procedure>(fxpositive? N) => boolean</procedure>360 <procedure>(fxpositive? N) > boolean</procedure> 355 361 356 362 ==== fxcardinal? 357 363 358 <procedure>(fxcardinal? N) => boolean</procedure>364 <procedure>(fxcardinal? N) > boolean</procedure> 359 365 360 366 ==== fxnegative? 361 367 362 <procedure>(fxnegative? N) => boolean</procedure>368 <procedure>(fxnegative? N) > boolean</procedure> 363 369 364 370 ==== fxclosedright? 365 371 ==== fxclosedr? 366 372 367 <procedure>(fxclosedright? L N H) => boolean</procedure>368 <procedure>(fxclosedr? L N H) => boolean</procedure>373 <procedure>(fxclosedright? L N H) > boolean</procedure> 374 <procedure>(fxclosedr? L N H) > boolean</procedure> 369 375 370 376 Returns {{N}} in {{(L .. H]}}. … … 376 382 Returns {{N}} in {{[L .. H]}}. 377 383 378 <procedure>(fxclosed? L N H) => boolean</procedure>384 <procedure>(fxclosed? L N H) > boolean</procedure> 379 385 380 386 {{N}}, {{L}} & {{H}} are {{fixnum}} low & high limits. … … 385 391 Returns {{N}} in {{[L .. H)}}. 386 392 387 <procedure>(fxclosedleft? L N H) => boolean</procedure>388 <procedure>(fxclosedl? L N H) => boolean</procedure>393 <procedure>(fxclosedleft? L N H) > boolean</procedure> 394 <procedure>(fxclosedl? L N H) > boolean</procedure> 389 395 390 396 {{N}}, {{L}} & {{H}} are {{fixnum}} low & high limits. … … 392 398 ==== fxadd1 393 399 394 <procedure>(fxadd1 N) => fixnum</procedure>400 <procedure>(fxadd1 N) > fixnum</procedure> 395 401 396 402 ==== fxsub1 397 403 398 <procedure>(fxsub1 N) => fixnum</procedure>404 <procedure>(fxsub1 N) > fixnum</procedure> 399 405 400 406 ==== fxabs 401 407 402 <procedure>(fxabs N) => fixnum</procedure>408 <procedure>(fxabs N) > fixnum</procedure> 403 409 404 410 ==== fxsqr 405 411 406 <procedure>(fxsqr N) => fixnum</procedure>412 <procedure>(fxsqr N) > fixnum</procedure> 407 413 408 414 ==== fxcub 409 415 410 <procedure>(fxcub N) => fixnum</procedure>416 <procedure>(fxcub N) > fixnum</procedure> 411 417 412 418 ==== fxlog2 413 419 414 <procedure>(fxlog2 N) => fixnum</procedure>420 <procedure>(fxlog2 N) > fixnum</procedure> 415 421 416 422 Returns index of highest bit set, so {{N}} is treated as unsigned. … … 418 424 ==== fxpow2log2 419 425 420 <procedure>(fxpow2log2 N) => fixnum</procedure>426 <procedure>(fxpow2log2 N) > fixnum</procedure> 421 427 422 428 Returns {{fixnum}} {{2^N}}. … … 424 430 ==== fxdistance 425 431 426 <procedure>(fxdistance X1 Y1 X2 Y2) => fixnum</procedure>432 <procedure>(fxdistance X1 Y1 X2 Y2) > fixnum</procedure> 427 433 428 434 Pythagorean distance between the points {{X1 Y1}} and {{X2 Y2}}. … … 430 436 ==== fxdistance* 431 437 432 <procedure>(fxdistance* X1 Y1 X2 Y2) => fixnum</procedure>438 <procedure>(fxdistance* X1 Y1 X2 Y2) > fixnum</procedure> 433 439 434 440 Pythagorean distance, inaccurate but useful for relative comparisons. … … 436 442 ==== fxmaxandmin 437 443 438 <procedure>(fxmaxandmin N ...) => (values fixnum fixnum)</procedure>444 <procedure>(fxmaxandmin N ...) > (values fixnum fixnum)</procedure> 439 445 440 446 Returns the maximum & minimum values for the {{fixnum}}s {{N ...}}. … … 569 575 ; yn : besselyn 570 576 577 571 578 == Bugs and Limitations 572 579 … … 578 585 number. Support for the full numeric tower is '''not''' provided. 579 586 580 * Windows does not provide library calls {{lgamma}}, {{gamma}}, {{acosh}}, 581 {{asinh}}, {{atanh}}, {{log2}}, {{log1p}}, {{erf}}, {{erfc}}, {{scalbn}}, 582 {{cbrt}} & {{signbit}}. 583 584 Usable {{log2}}, {{log1p}}, {{erf}}, {{erfc}}, {{scalbn}} & {{signbit}} are 585 supplied. 587 * Windows library calls {{lgamma}}, {{gamma}}, {{acosh}}, {{asinh}}, 588 {{atanh}}, {{cbrt}} & {{signbit}} are not provided. 586 589 587 590 * FreeBSD does not provide the library call {{log2}}. A usable {{log2}} is … … 601 604 == Version history 602 605 603 ; 3.3.1 ; Rename internal C statics. 606 ; 3.4.0 ; Fix {{fppositive?}}. {{fpnegative?}}, {{fpcardinal?}}, {{fpeven?}}, {{fpodd?}}. 607 ; 3.3.3 ; Remove Windows {{log2}}, {{log1p}}, {{erf}}, {{erfc}}, {{scalbn}}. 608 ; 3.3.2 ; 609 ; 3.3.1 ; 604 610 ; 3.3.0 ; Add {{logwithbase}}. Deprecate {{makelog/base}}. Fix {{fprandom}} sign preservation. 605 611 ; 3.2.4 ; Add {{fxlog2}}, fix {{fxpow2log2}}.
Note: See TracChangeset
for help on using the changeset viewer.