error with "if" !!!
- From: nakisa <nakisa.nooraee@xxxxxxxxx>
- Date: 28 Apr 2007 01:52:20 -0700
Hi ,everybody
I have encounter with strange error ( strange in my point view !)
In program, I need to find the sample values of function named f . I
use these 3 commands :
1) if (f<0.0005D0 ) then
2) if (abs(f-0.0005D0)<0.001D0) then
3) if (abs(f-0.0005D0)<0.01D0 ) then
to see the answer . I was surprised to see the answer of this commands
are different !
for example , 7.3124E-5 only given by second if !!
my question is what is the best way to find f near a number and why
the above commands give various answers
thanks
nakisa
.
- Follow-Ups:
- Re: error with "if" !!!
- From: Gib Bogle
- Re: error with "if" !!!
- From: dpb
- Re: error with "if" !!!
- From: Giorgio Pastore
- Re: error with "if" !!!
- Prev by Date: Re: add a0 format to language to print trimmed character variables
- Next by Date: Re: utility to replace "end" with "end subroutine foo"
- Previous by thread: mpi & xlf
- Next by thread: Re: error with "if" !!!
- Index(es):
Relevant Pages
|