January 2010

Sun Mon Tue Wed Thu Fri Sat
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31            

Blogroll

Blog powered by Typepad
Member since 07/2003

« Mathematica 6 out this week? | Main | Verizon FIOS TV and TiVo »

Comments

dm.v.g.

Same story with Java:
Double.MAX_VALUE; // 1.7976931348623157e+308; 0x1.fffffffffffffP+1023

Double.MIN_VALUE; // 4.9e-324; 0x0.0000000000001P-1022

However (a little ad compain for floating point users :-)

1) no floating point exceptions, unlike in C or C++ (Java will be upset only in the rare case of integer division by zero, which is presumably a bug easy to avoid.)

2) you can always catch an intermediate Double.NaN or Double.POSITIVE_INFINITY or Double.NEGATIVE_INFINITY
(Double.isInfinite(value) or Double.isNaN(value)) in case things transcended beyond tangible. Since NaNs or Infinities can be reliably caught, you can always backtrack.
For instance in an iterative process it is typically possible to analyze intermediate vector's norm (cheap computation: once an INFINITY or NAN kicks in, it is propagated and cannot be cancelled 0 * POSITIVE_INFINITY == NAN, etc.)

We recently ran (for fun) parallel postorder traversal... parallel Java on 8-processor was mucho faster than single-threaded C :-) hardware... and certainly more fun than PThreads or MPI :-)

Some times I wonder why folks admire C++ so much ? :-) No thread support, no network programming support (socket programming), somewhat murky/deep waters STL :-)

The comments to this entry are closed.