9E+99 (VB to C++... arduino...)

Good morning

I'm recreating a formula on Arduino that I already have on VB6. My var on var have a value of '9E+99' ... it means that I have 99 leading zeros... 9000000(0)...

How can I recreate it on Arduino?

Thanks on advance Best regards Pedro Ferrer

It's afternoon here. 8)

Cek this out: http://arduino.cc/playground/Main/Fscale using 9*10(pow(99))

I guess :drooling_face:

Hello (It's better... :) )

Thanks by your prompt answer! I'll test as soon as possible.

Thanks once again Best regards Pedro Ferrer

Without the use of a special library you can’t. The largest floating-point number that can be represented is…

#define FLT_MAX 3.40282347e+38F

'9E+99' ... it means that I have 99 leading zeros..

Those are trailing zeroes.

That number represents more than a billion time the number of fundamental particles in the observable universe.

Use the number with Arduino for mathematical purpose maybe..in order to predict future..WOW Waiting for the resutl!

Waiting for the resutl!

I suspect you will be disappointed.

Hello

What I miss?...

(...)

Well, so... I have to use '#define FLT_MAX 3.40282347e+38F' instead '9*10(pow(99))' ?

Please let me know Thanks on advance Best regards Pedro Ferrer

You missed the fact that you can't define a number that large, without using a library. That #define shows the largest float value that can be created, and 3.4e+38 is nowhere near 9e+99.

I would be interested in what the number represents, or is this a purely hypothetical exercise?

is this a purely hypothetical exercise?

Given that you could express the age of the universe in Planck Times many billions of times over in a number this large, I think it is safe to assume it is an exercise.

I'm sure it's a hypothetical number, similar to 9/9/99 as a dummy date (we used that a few years ago)

If there's a real problem around this, it's probably related to the fact that a double on Arduino is 32 bit only and thus the same as a (single) float.

Hello

The var is called 'Bogus'.. the name tells almost everything... It's used on comparison with other value... a Julian Date :)

So I have to use:

define bogus 3.4e+38

That's it

Thanks Best regards

So I have to use:

define bogus 3.4e+38

Or -1, since dates can't be negative.

1) what about 3e+33 It's beyond any real physical value ( in realistic units )

2) how can you safely compare dates with float ( or double ) numbers ?

Hello

michael_x: 2) how can you safely compare dates with float ( or double ) numbers ?

Please check this calculator... http://aa.usno.navy.mil/data/docs/JulianDate.php

Best regards Pedro Ferrer

how can you safely compare dates with float ( or double ) numbers ? Please check this calculator... http://aa.usno.navy.mil/data/docs/JulianDate.php

So you can't, on an Arduino, even if you stick to full days

The Julian date for CE 2012 May 23 00:00:00.0 UT is JD 2456070.500000

This is way beyond the accuracy of a 32 bit float

BTW: Curious about the used formula,why is a Julian Date related to a pacific timezone ?

Hello

Yes... if you want to retrieve seconds, minutes and hours from there, forget it with arduino (for now... with chipkit is possible, I think)... but days, months and years... are fine :)

Best regards Pedro Ferrer

Hello

That's why we don't use that kind of valour... but shorter... eg: Julian date year 2000... is shorter... about 41xxx.xxxx days... until now...

Bye Pedro Ferrer