|
-
February 4th, 2003, 10:00 AM
#1
1.#inf
Hi,
I am getting a weird error. While printing the contents of a float array, some of the entries are printed as 1.#INF
Is this divide by zero or infinity error??
Also, this only happens when I declare the array as float, it is all right when I declare the array as double.
Any ideas?
Xargon
-
February 4th, 2003, 10:14 AM
#2
this only happens when I declare the array as float, it is all right when I declare the array as double
Sounds like you have exceeded the limits of a float for some of the stored elements in your array.
A float can hold values in the range of 3.4E +/- 38 (7 digits), and a double in the range of 1.7E +/- 308 (15 digits).
If you need to keep the values as they currently are, you would be better off to continue to use the array of doubles to hold them.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|