From: tone@m.mscs.mu.edu (Peter Tonellato)
Newsgroups: comp.sys.apollo
Subject: Machine Constants for Numerical Packages. (DN10000)
Date: 13 Nov 1992 15:54:48 GMT
Organization: Marquette University - Department MSCS
Distribution: world
Reply-To: tone@m.mscs.mu.edu (Peter Tonellato)
NNTP-Posting-Host: m.mscs.mu.edu
Originator: tone@m.mscs.mu.edu

Dear Netters:

Typical numerical packages include subroutines that determine the standard
machine constants used for machine-epsilon accurate numerical computations.

A common subroutine (e.g. used in MINPACK) is DPMPAR (or SPMPAR for single
precision.) This subroutine has been designed so that appropriate entries
for many architectures are available. To use the routine on your home
machine one need only uncomment the appropriate entry. 

My question is can someone please send me the correct machine constants for
the DN1000 PRISM architecture? I would very much appreciate it and will submit
the entry to "netlib" for inclusion in future releases of the public domain
numerical packages they offer.

Thanks Very Much,

Peter J. Tonellato

US Mail: Department of Mathematics, Statistics and Computer Science
         Marquette University
         Milwaukee, Wisconsin 53233
Voice:   414-288-5228 (Office)
         414-288-7573 (Message)
FAX:     414-288-5472 (FAX)
Arpa:    tone@m.mscs.mu.edu   

***************************************************************************
DPMPAR.F:
***************************************************************************

      DOUBLE PRECISION FUNCTION DPMPAR(I)
      INTEGER I
C     **********
C
C     FUNCTION DPMPAR
C
C     THIS FUNCTION PROVIDES DOUBLE PRECISION MACHINE PARAMETERS
C     WHEN THE APPROPRIATE SET OF DATA STATEMENTS IS ACTIVATED (BY
C     REMOVING THE C FROM COLUMN 1) AND ALL OTHER DATA STATEMENTS ARE
C     RENDERED INACTIVE. MOST OF THE PARAMETER VALUES WERE OBTAINED
C     FROM THE CORRESPONDING BELL LABORATORIES PORT LIBRARY FUNCTION.
C
C     THE FUNCTION STATEMENT IS
C
C       DOUBLE PRECISION FUNCTION DPMPAR(I)
C
C     WHERE
C
C       I IS AN INTEGER INPUT VARIABLE SET TO 1, 2, OR 3 WHICH
C         SELECTS THE DESIRED MACHINE PARAMETER. IF THE MACHINE HAS
C         T BASE B DIGITS AND ITS SMALLEST AND LARGEST EXPONENTS ARE
C         EMIN AND EMAX, RESPECTIVELY, THEN THESE PARAMETERS ARE
C
C         DPMPAR(1) = B**(1 - T), THE MACHINE PRECISION,
C
C         DPMPAR(2) = B**(EMIN - 1), THE SMALLEST MAGNITUDE,
C
C         DPMPAR(3) = B**EMAX*(1 - B**(-T)), THE LARGEST MAGNITUDE.
C
C     ARGONNE NATIONAL LABORATORY. MINPACK PROJECT. MARCH 1980.
C     BURTON S. GARBOW, KENNETH E. HILLSTROM, JORGE J. MORE
C
C     **********
      INTEGER MCHEPS(4)
      INTEGER MINMAG(4)
      INTEGER MAXMAG(4)
      DOUBLE PRECISION DMACH(3)
      EQUIVALENCE (DMACH(1),MCHEPS(1))
      EQUIVALENCE (DMACH(2),MINMAG(1))
      EQUIVALENCE (DMACH(3),MAXMAG(1))
C
C     MACHINE CONSTANTS FOR THE VAX-11.
C
C     DATA MCHEPS(1),MCHEPS(2) /   9472,  0 /
C     DATA MINMAG(1),MINMAG(2) /    128,  0 /
C     DATA MAXMAG(1),MAXMAG(2) / -32769, -1 /
C
C     MACHINE CONSTANTS FOR IEEE ARITHMETIC MACHINES, SUCH AS THE AT&T
C     3B SERIES AND MOTOROLA 68000 BASED MACHINES (E.G. SUN 3 AND AT&T
C     PC 7300), IN WHICH THE MOST SIGNIFICANT BYTE IS STORED FIRST.
C     Sun machine constants are provided by Dr.George F. Corliss (8/92)
C     
      DATA MCHEPS(1),MCHEPS(2) / 1018167296,          0 /
      DATA MINMAG(1),MINMAG(2) / 2146435071,         -1 /
      DATA MAXMAG(1),MAXMAG(2) /    1048576,          0 / 
C
      DPMPAR = DMACH(I)
      RETURN
C
C     LAST CARD OF FUNCTION DPMPAR.
C
      END

***************************************************************************
***************************************************************************