So, I'm working on a little science project:
Output: Infinity
I'm getting "Infinity" instead of the actual value.
How can I handle such big numbers? Any suggestions?
I'm not a math wizzard...
B4X:
Dim G = 6.67 * Power(10, -11) as Float
Dim Earth_Mass = 5.97 * Power(10, 24) as Float 'in kilograms
Dim Sun_Mass = 1.99 * Power(10, 30) as Float 'in kilograms
Dim Distance = 1.5 * power(10, 11) as Float 'in meters
B4X:
Dim Gravitational_Force = (G * Sun_Mass * Earth_Mass) / Power(Distance, 2) as Float
Log(Gravitational_Force)
I'm getting "Infinity" instead of the actual value.
How can I handle such big numbers? Any suggestions?
I'm not a math wizzard...