Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Single v Double
#9
According to the description: Abs is often used, for example in approximation algorithms, where it is important to stop the calculation above a certain level of accuracy. It doesn't matter whether the calculated value is larger or smaller than the comparison value.

Code: (Select All)
Dim As Double a, c, d
Dim b As Single

a = .12345678
Print a
b = Abs(a * 10000000)
Print a; b

Print
c = Abs(a * 10000000)
Print c

Print
c = .12345678
d = Abs(c * 10000000)
Print "c = ";: Print c
Print "d = ";: Print d
Reply


Messages In This Thread
Single v Double - by Dimster - 11-05-2022, 04:44 PM
RE: Single v Double - by Jack - 11-05-2022, 05:14 PM
RE: Single v Double - by Pete - 11-05-2022, 05:31 PM
RE: Single v Double - by mnrvovrfc - 11-05-2022, 05:43 PM
RE: Single v Double - by Jack - 11-05-2022, 06:00 PM
RE: Single v Double - by Dimster - 11-05-2022, 06:11 PM
RE: Single v Double - by Pete - 11-05-2022, 06:32 PM
RE: Single v Double - by Jack - 11-05-2022, 07:00 PM
RE: Single v Double - by Kernelpanic - 11-05-2022, 09:56 PM
RE: Single v Double - by mnrvovrfc - 11-05-2022, 10:10 PM
RE: Single v Double - by Pete - 11-05-2022, 10:48 PM
RE: Single v Double - by Jack - 11-05-2022, 11:46 PM
RE: Single v Double - by Kernelpanic - 11-05-2022, 11:50 PM
RE: Single v Double - by Pete - 11-05-2022, 11:59 PM
RE: Single v Double - by Jack - 11-06-2022, 12:35 AM
RE: Single v Double - by Pete - 11-06-2022, 12:38 AM
RE: Single v Double - by Kernelpanic - 11-06-2022, 02:03 AM
RE: Single v Double - by Richard - 11-06-2022, 12:42 AM
RE: Single v Double - by Pete - 11-06-2022, 02:07 AM



Users browsing this thread: 2 Guest(s)