Hello,
Having read the two responses (which gave very good explanations),
I'll venture a recommendation:
method A
Say what you mean, get what you need, move between 32-bit and 64-bit
processors (which is probably what you're trying to do).
Processors are on the verge of making the 32-bit to 64-bit transition
(which is to say, Intel is on the verge...), so IMNSHO, that's
the biggest concern.
YMMV, of course.
--
Cheers!
Dan Nagle
Purple Sage Computing Solutions, Inc.
On Wed, 12 Feb 2003 07:33:00 -0700, "Blackwell, Bennie F"
<[log in to unmask]> wrote:
>I have seen (and used) the following two ways of setting machine precision.
>What is recommended way and why?
>
>method A
> INTEGER, PARAMETER :: REAL_8 = SELECTED_REAL_KIND(15,30)
> REAL(KIND=REAL_8), PARAMETER :: PI = 3.141592653589793238462643383_REAL_8
>
>method B
> INTEGER, PARAMETER :: SP = KIND(1.0) ! single precision
> INTEGER, PARAMETER :: DP = KIND(1.0D0) ! double precision
> REAL (DP), PARAMETER :: PI = 3.141592653589793238462643383_DP
>
>Thanks,
>
>Ben
>
>
>===================================================================
>
> Ben Blackwell, PhD E-mail: [log in to unmask]
> Sandia National Laboratories
> Validation and Uncertainty
> Quantification 9133
> MS 0828
> PO Box 5800 Phone: (505) 845-8844
> Albuquerque, NM 87185-0828 FAX: (505) 844-4523
> UPS/FedEx: SNL / MS 0828 / 1515 Eubank Blvd SE / Albuq, NM 87123
>
>"Build only what you can model. Model only what you can build." 1999
>
>===================================================================
>
|