[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Rounds a double-precision floating-point value to the nearest integral value.
Assembly: mscorlib (in mscorlib.dll)
- Type: System..::..Double
A double-precision floating-point number to be rounded.
This method is equivalent to calling the method with a mode argument of . The behavior of this method follows IEEE Standard 754, section 4. This kind of rounding is sometimes called rounding to nearest, or banker's rounding. It minimizes rounding errors that result from consistently rounding a midpoint value in a single direction.
To control the type of rounding used by the method, call the overload.
If the value of d is Double..::..NaN, the method returns Double..::..NaN. If the value of d is Double..::..PositiveInfinity or Double..::..NegativeInfinity, the method returns Double..::..PositiveInfinity or Double..::..NegativeInfinity, respectively.
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.