Class RadMath
Provides static mathematical functions and constants.
Inheritance
Inherited Members
Namespace: Telerik.Charting
Assembly: Telerik.WinControls.dll
Syntax
public static class RadMath
Fields
DegToRadFactor
The factor used to convert degrees to their radians equivalent.
Declaration
public const double DegToRadFactor = 0.017453292519943295
Field Value
System.Double
|
Epsilon
Smallest unit such that 1.0+DBL_EPSILON != 1.0.
Declaration
public const double Epsilon = 2.2204460492503131E-09
Field Value
System.Double
|
RadToDegFactor
The factor used to convert radians to their degree equivalent.
Declaration
public const double RadToDegFactor = 57.295779513082323
Field Value
System.Double
|
Methods
AreClose(Double, Double)
Determines whether the two specified values are close within the order of EPSILON.
Declaration
public static bool AreClose(double value1, double value2)
Parameters
System.Double
value1
|
System.Double
value2
|
Returns
System.Boolean
|
AreClose(Double, Double, Double)
Determines whether the two specified values are close within the order of tolerance.
Declaration
public static bool AreClose(double value1, double value2, double tolerance)
Parameters
System.Double
value1
|
System.Double
value2
|
System.Double
tolerance
|
Returns
System.Boolean
|
CalculateHorizontalLineIntersectionPoint(Double, Double, Double, Double, Double)
Declaration
public static double CalculateHorizontalLineIntersectionPoint(double x1, double y1, double x2, double y2, double horizontalLineY)
Parameters
System.Double
x1
|
System.Double
y1
|
System.Double
x2
|
System.Double
y2
|
System.Double
horizontalLineY
|
Returns
System.Double
|
CalculateVerticalLineIntersectionPoint(Double, Double, Double, Double, Double)
Declaration
public static double CalculateVerticalLineIntersectionPoint(double x1, double y1, double x2, double y2, double verticalLineX)
Parameters
System.Double
x1
|
System.Double
y1
|
System.Double
x2
|
System.Double
y2
|
System.Double
verticalLineX
|
Returns
System.Double
|
Coerce(Double, Double, Double)
Declaration
public static double Coerce(double value, double min, double max)
Parameters
System.Double
value
|
System.Double
min
|
System.Double
max
|
Returns
System.Double
|
GetArcPoint(Double, RadPoint, Double)
Gets the point that lies on the arc segment of the ellipse, described by the center and radius parameters.
Declaration
public static RadPoint GetArcPoint(double angle, RadPoint center, double radius)
Parameters
System.Double
angle
|
RadPoint
center
|
System.Double
radius
|
Returns
RadPoint
|
GetPointDistance(Double, Double, Double, Double)
Gets the distance between two points in a plane.
Declaration
public static double GetPointDistance(double x1, double x2, double y1, double y2)
Parameters
System.Double
x1
The x-coordinate of the first point. |
System.Double
x2
The x-coordinate of the second point. |
System.Double
y1
The y-coordinate of the first point. |
System.Double
y2
The y-coordinate of the second point. |
Returns
System.Double
|
IsOne(Decimal)
Determines whether the specified value is close to 1 within the order of EPSILON.
Declaration
public static bool IsOne(decimal value)
Parameters
System.Decimal
value
|
Returns
System.Boolean
|
IsOne(Double)
Determines whether the specified value is close to 1 within the order of EPSILON.
Declaration
public static bool IsOne(double value)
Parameters
System.Double
value
|
Returns
System.Boolean
|
IsZero(Decimal)
Determines whether the specified value is close to 0 within the order of EPSILON.
Declaration
public static bool IsZero(decimal value)
Parameters
System.Decimal
value
|
Returns
System.Boolean
|
IsZero(Double)
Determines whether the specified value is close to 0 within the order of EPSILON.
Declaration
public static bool IsZero(double value)
Parameters
System.Double
value
|
Returns
System.Boolean
|