Lahey Support
08-15-2003, 12:19 AM
> c---------------------
> program test
> implicit none
> real :: a
>
> a = .123456
>
> ccc a = a*10**10
> a = a*10**10.0 !<<<<<try this instead.
>
> WRITE(*,*) a
>
> stop
> end program test
> c---------------------
> ----------------------------------------------------------------------
> From: "cosine Cheng" [address removed]
> Subject: [LF] Help!Magic # for float #
> Date: Sat, 23 Jan 1999 00:32:09 PST
>
> Dear All:
>
> I wrote a small code and met some strange things...
>
> program test
> implicit none
> real :: a
>
> a = .123456
> a = a*10**10
> WRITE(*,*) a
> ...
>
> stop
> end program test
>
> The code replied me a strange # to a as: 0.174081E+09
>
> What's wrong with that? How to solve it out? By the way,
>
> if I use
>
> a = a*10**9
> WRITE(*,*) a ! <-- get 0.123456E+09
>
>
> or
>
> WRITE(*,*) .123456*10.**10 ! <-- get 0.123456E+10
>
> They worked well.
>
> Thanks
>
> Cosine
> Jan/23/1999 UT
>
>
> __________________________________________________ ____
> Get Your Private, Free Email at http://www.hotmail.com
> ----------------------------------------------------------------------
> To post a reply to the list, you must send it to [address removed]
> ----------------------------------------------------------------------
> From: [address removed]
> Date: Sat, 23 Jan 1999 04:16:28 EST
> Subject: Re: [LF] Help!Magic # for float #
>
> In a message dated 1/23/99 12:45:36 AM Pacific Standard Time,
> [address removed] writes:
>
> << a = .123456
> a = a*10**10
> WRITE(*,*) a
> ...
>
> stop
> end program test
>
> The code replied me a strange # to a as: 0.174081E+09 >>
> 10**10 must be overflowing. Did you mean 10D0**10?
> ----------------------------------------------------------------------
>
> program test
> implicit none
> real :: a
>
> a = .123456
>
> ccc a = a*10**10
> a = a*10**10.0 !<<<<<try this instead.
>
> WRITE(*,*) a
>
> stop
> end program test
> c---------------------
> ----------------------------------------------------------------------
> From: "cosine Cheng" [address removed]
> Subject: [LF] Help!Magic # for float #
> Date: Sat, 23 Jan 1999 00:32:09 PST
>
> Dear All:
>
> I wrote a small code and met some strange things...
>
> program test
> implicit none
> real :: a
>
> a = .123456
> a = a*10**10
> WRITE(*,*) a
> ...
>
> stop
> end program test
>
> The code replied me a strange # to a as: 0.174081E+09
>
> What's wrong with that? How to solve it out? By the way,
>
> if I use
>
> a = a*10**9
> WRITE(*,*) a ! <-- get 0.123456E+09
>
>
> or
>
> WRITE(*,*) .123456*10.**10 ! <-- get 0.123456E+10
>
> They worked well.
>
> Thanks
>
> Cosine
> Jan/23/1999 UT
>
>
> __________________________________________________ ____
> Get Your Private, Free Email at http://www.hotmail.com
> ----------------------------------------------------------------------
> To post a reply to the list, you must send it to [address removed]
> ----------------------------------------------------------------------
> From: [address removed]
> Date: Sat, 23 Jan 1999 04:16:28 EST
> Subject: Re: [LF] Help!Magic # for float #
>
> In a message dated 1/23/99 12:45:36 AM Pacific Standard Time,
> [address removed] writes:
>
> << a = .123456
> a = a*10**10
> WRITE(*,*) a
> ...
>
> stop
> end program test
>
> The code replied me a strange # to a as: 0.174081E+09 >>
> 10**10 must be overflowing. Did you mean 10D0**10?
> ----------------------------------------------------------------------
>