ComponentOne Bitmap for WPF
NearEqual Method

C1.WPF.DX.4 Assembly > C1.Util.DX Namespace > DXUtil Class : NearEqual Method
The left value to compare.
The right value to compare.
Checks if a and b are almost equals, taking into account the magnitude of floating point numbers. See Remarks. See remarks.
Syntax
'Declaration
 
Public Shared Function NearEqual( _
   ByVal a As System.Single, _
   ByVal b As System.Single _
) As System.Boolean
public static System.bool NearEqual( 
   System.float a,
   System.float b
)

Parameters

a
The left value to compare.
b
The right value to compare.

Return Value

true if a almost equal to b, false otherwise
Remarks
The code is using the technique described by Bruce Dawson in Comparing Floating point numbers 2012 edition.
See Also

Reference

DXUtil Class
DXUtil Members