Search found 3 matches

by Andrei Khokhlov
Wed Oct 04, 2023 5:00 pm
Forum: ZX BASIC
Topic: Math bug?
Replies: 5
Views: 6286

Re: Math bug?

I was inattentive, in EightyOne emulator ROM may be selected and with zx81.edition1.rom errors present.
by Andrei Khokhlov
Tue Oct 03, 2023 4:07 pm
Forum: ZX BASIC
Topic: Math bug?
Replies: 5
Views: 6286

Re: Math bug?

Yes, my test code implicitly assumes double precision arithmetic (REAL*8), but ZX81 arithmetic is REAL*5 (32-bit for mantissa). So error 1E-16 unnecessary small. With 1E-8 as error limit result much more correct, but it differ from built-in sin 2.0980103 vs 1.9998355 (built-n sin) Maybe I would assu...
by Andrei Khokhlov
Tue Oct 03, 2023 12:13 am
Forum: ZX BASIC
Topic: Math bug?
Replies: 5
Views: 6286

Math bug?

Some time ago, I decided to understand the floating point arithmetic and wrote a simple test that calculates the area under half the period of the sine function. It's not complete, but some results can be seen here http://avhohlov.narod.ru/p9882en.htm . Test may be done also on old home computers an...