# RhinoMath class

Namespace: [Rhino](https://developer.rhino3d.com/api/rhinocommon/namespace/rhino.md) · Assembly: [RhinoCommon](https://developer.rhino3d.com/api/rhinocommon/assembly/rhinocommon.md)

```cs
public static class RhinoMath
```

Provides constants and static methods that are additional to [Math](https://learn.microsoft.com/dotnet/api/system.math).

## Fields

- [DefaultAngleTolerance](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/defaultangletolerance.md): (static) Represents the default angle tolerance, used when no other values are provided. This is one degree, expressed in radians.
- [DefaultDistanceToleranceMillimeters](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/defaultdistancetolerancemillimeters.md): (static) Get Rhino's default distance tolerance in millimeters.
- [Epsilon](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/epsilon.md): (static) Gets the value of DBL_EPSILON, which is the smallest positive floating point number x such that 1 + x != 1. This is different than Double.Epsilon which is the smallest positive Double value that is greater than zero.
- [HalfPI](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/halfpi.md): (static) Quarter of a rotation. 90 degrees. 1.57...
- [InfiniteRadius](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/infiniteradius.md): (static) Value used to indicate a radius of curvature is infinite.
- [QuarterPI](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/quarterpi.md): (static) One eigth of a rotation. 45 degrees. 0.78...
- [SqrtEpsilon](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/sqrtepsilon.md): (static) Represents a default value that is used when comparing square roots. This value is several orders of magnitude larger than [RhinoMath.ZeroTolerance](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/zerotolerance.md).
- [Tau](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/tau.md): (static) Ratio of circumference divided by radius. Full rotation. 360 degrees. 6.28...
- [TwoPI](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/twopi.md): (static) Full rotation. 360 degrees. 6.28...
- [UnsetIntIndex](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/unsetintindex.md): (static) When signed int values are used in a context where 0 and small negative values are valid indices and there needs to be a value that indicates the index is not set.
- [UnsetSingle](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/unsetsingle.md): (static) Gets the single precision floating point number that is considered 'unset' in Rhino.
- [UnsetValue](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/unsetvalue.md): (static) Gets the Rhino standard Unset value. Use this value rather than Double.NaN when a bogus floating point value is required.
- [ZeroTolerance](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/zerotolerance.md): (static) Gets Rhino's Zero Tolerance constant, which is 2^-32. In cases when an absolute "zero" tolerance is required to compare model space coordinates, ZeroTolerance is used. The value of ZeroTolerance should be no smaller than [RhinoMath.Epsilon](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/epsilon.md) and should be several orders of magnitude smaller than [RhinoMath.SqrtEpsilon](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/sqrtepsilon.md).

## Methods

- [Clamp](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/clamp.md): (2 overloads, static) Limits a [double](https://learn.microsoft.com/dotnet/api/system.double) to be specified within an interval of two numbers, by specifying a fixed minimum and maximum.
- [CRC32](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/crc32.md): (3 overloads, static) Advances the cyclic redundancy check value remainder given a byte array. http://en.wikipedia.org/wiki/Cyclic_redundancy_check.
- [EpsilonEquals](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/epsilonequals.md): (2 overloads, static) Compare two doubles for equality within some "epsilon" range
- [EvaluateNormal](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/evaluatenormal.md): (static) Expert tool to evaluate surface unit normal.
- [EvaluateNormalPartials](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/evaluatenormalpartials.md): (static) Expert tool to evaluate partial derivatives of surface unit normal.
- [EvaluateSectionalCurvature](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/evaluatesectionalcurvature.md): (static) Expert tool to evaluate sectional curvature from surface derivatives and section plane normal.
- [Integrate](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/integrate.md): (8 overloads, static)
- [IntIndexToString](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/intindextostring.md): (static) Portrays an [int](https://learn.microsoft.com/dotnet/api/system.int32) index in text.
- [IsValidDouble](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/isvaliddouble.md): (static) Determines whether a [double](https://learn.microsoft.com/dotnet/api/system.double) value is valid within the RhinoCommon context. Rhino does not use Double.NaN by convention, so this test evaluates to true if: x is not equal to RhinoMath.UnsetValue System.Double.IsNaN(x) evaluates to false System.Double.IsInfinity(x) evaluates to false
- [IsValidSingle](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/isvalidsingle.md): (static) Determines whether a [float](https://learn.microsoft.com/dotnet/api/system.single) value is valid within the RhinoCommon context. Rhino does not use Single.NaN by convention, so this test evaluates to true if: x is not equal to RhinoMath.UnsetValue, System.Single.IsNaN(x) evaluates to false System.Single.IsInfinity(x) evaluates to false
- [MetersPerUnit](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/metersperunit.md): (static) Return number of meters per one unit of a given unit system
- [ParseNumber](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/parsenumber.md): (static) Evaluates command line math expression.
- [ToDegrees](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/todegrees.md): (static) Convert an angle from radians to degrees.
- [ToRadians](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/toradians.md): (static) Convert an angle from degrees to radians.
- [TryParseNumber](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/tryparsenumber.md): (static) Evaluates command line math expression.
- [UnitScale](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/unitscale.md): (2 overloads, static) Computes the scale factor for changing the measurements unit systems.
- [Wrap](https://developer.rhino3d.com/api/rhinocommon/type/rhino.rhinomath/wrap.md): (static) Limits a [double](https://learn.microsoft.com/dotnet/api/system.double) to be specified within an interval of two numbers by repeating the available interval cyclically.
