🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Ray Brownrigg Wed, 14 Oct 1987 23:03
3B2 floating point libraries
#619
Author: Ray Brownrigg
Date: Wed, 14 Oct 1987 23:03
19 lines
1424 bytes
I have uncovered a strange bug in the floating point routines for the
Fortran XLA+ and C-FP+ compilers for an AT&T 3B2 (with MAU), relating
to non-integral powers of 0.5 (and perhaps other numbers as well). For
example the expression 0.5**Y returns the value 0.5**(Y-1) when Y is
2.5, 4.5, 6.5, 8.5, ... Further, using C-FP+, the statement
	printf("%10.8f\n", pow(0.5, 2.5))
results in a zero being output.

I have reported the bugs (to Olivetti), but would be interested if anybody
else has seen the same problem.

Otherwise, beware. One workaround it to use exp(0.5*log(y)), but this is
not easy in a package as large as the S statistical package.

-- 
Ray Brownrigg		UUCP: {utai!calgary,uunet}!vuwcomp!dsiramd!ray
Applied Maths Div, DSIR		ACSnet:	ray@dsiramd.nz[@munnari]
PO Box 1335			System:	OLIVETTI/AT&T 3B2/400B+, System V R3.0
Wellington, New Zealand			"UNX -rules -OK"
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads