home

torture test: domains

round #4: calculation domains

i noticed that different types of calculator give up at different points on the domain of scientific functions.

for periodic functions the domain limit is either arbitrary (eg 1440) or governed by the accuracy of performing mod(x, m) for large x. consequently, part of the test is to see how much accuracy is achieved near the manufacturers domain limit. for details of this problem see, the secret life of the mod function.

actual values:

sin(999999999 radians) = -.410137277280044
sin(1e9) = .5458434494486996
sin(1e8) = .9316390271097260
sin(1e30) = -0.0901169019121380

calculator sin, cos & tan (radians) result accuracy sinh, cosh & tanh asinh(x) & acosh(x) x!
sharp el-512 174532925.2 (pi/180*1e10) sin(1e8) = .931691228 5.60e-5 230.258 <1e50 69
sharp el-531p 174532925.2 (pi/180*1e10) sin(1e8) = .931641418 2.57e-6 230.258 <1e50 69
sharp el-9900 174532925.2
(pi/180)*1e10
sin(1e8) = 0.93163923 2.18e-7 230.258 <1e50 69.5
casio fx-992v 15707963267 (5*pi*1e9) sin(999999999)=-.4101331034 1.05e-5 230.258 <5e99 69
casio fx-19, fx-29, fx-39 & fx-120 25.13 (1440*pi/180) sin(25) = -0.1323516   NA NA 69
NA for fx-19 & fx-29
casio fx-101 25.13 sin(25) = -0.13235168   NA NA NA
casio fx-85m, fx-920 25.13 sin(25) = -.1323517   230.258 <5e99 69
casio fx-350 25.13 sin(25) = -.1323517   230 (sinh) <5e99 69
casio fx-3500p 25.13 sin(25) = -.13235175   230.258 <5e99 69
casio fx-100 25.13 sin(25) = -.132351752   NA NA 69
casio fx-4800p 157079632
(pi/2*1e8)
sin(1e8)=.9316391026 8.1e-8 230.258 <5e99 69
casio fx-991es 157079632
(pi/2*1e8)
sin(1e8)=.9316391026 8.1e-8 230.258 <5e99 69
casio fx-50f 157079632
(pi/2*1e8)
sin(1e8)=.931747567 1.17e-4 230.258 <5e99 69
ti-52 785398163
(pi/4*1e9)
sin(1e8)=.931641418 2.57e-6 230.258 <1e50 69
ti-30x iiB 999999999 sin(999999999) = -.410197301 1.46e-4 230.258 <5e99 69
ti-30 1.74e98 sin(1e8) = 0.93169 5.60e-5 NA NA NA
ti-89 9.99e12 sin(999999999) = -.410139240195 4.79e-6 2302 9.99e999 449
ti-51-iii 9.99e99 sin(1e30)=9.622851e-01 completely wrong 227.95 <1e50 69
commodore sr4148r & 1540 9.99e99 sin(999999999) = -.413098193 7.22e-3 NA NA NA
hp15c 9.99e99 sin(999999999) = -.4101973005 1.46e-4 230.951 9.99e99 69.95
hp30s, hp9g 785398163 (pi/180*4.5e10) sin(1e8) = .931639027 0 230.258 <5e99 69
hp48gx 9.99e499 sin(999999999) = -.41013727728 0 1151.98 9.99e499 253.1
hp20s 9.99e499 sin(1e3) = -9.10311968e-2 1.01e-2 1151.98 9.99e499 253
hp32sii 9.99e499 sin(1e30) = -9.10311968e-2 1.01e-2 1151.98 9.99e499 253.1

comments

  • the hp32sii does really well due to its extra exponent capacity, but pushed to 1e30 gets only 2 digits correct.
  • the hp30s, although accurate is not as good in the domain test as other hp machines, but at least it stops the trig domain before it starts to go wrong.
  • the ti89 finds the full integer up to 299!, thereafter goes scientific to 1e1000, it could do better in the trig domain though.
  • above numbers like 9.99 actually mean 9.999999 etc can be accommodated in practice.
  • the hp20s is slow for n! even though it only supports integers.
  • the fx-350 sinh(x) function stops at 230 (but not cosh and tanh). this could be a bug.