Double.IsNegativeInfinity(Double) 메서드

정의

지정된 숫자가 음의 무한대로 계산되는지를 나타내는 값을 반환합니다.

public:
 static bool IsNegativeInfinity(double d);
public:
 static bool IsNegativeInfinity(double d) = System::Numerics::INumberBase<double>::IsNegativeInfinity;
public static bool IsNegativeInfinity (double d);
static member IsNegativeInfinity : double -> bool
Public Shared Function IsNegativeInfinity (d As Double) As Boolean

매개 변수

d
Double

배정밀도 부동 소수점 숫자입니다.

반환

dNegativeInfinity으로 계산되면 true이고, 그렇지 않으면 false입니다.

구현

예제

다음 코드 예제에서는 의 IsNegativeInfinity사용을 보여 줍니다.

// This will return S"true".
Console::WriteLine( "IsNegativeInfinity(-5.0 / 0) == {0}.", Double::IsNegativeInfinity(  -5.0 / zero ) ? (String^)"true" : "false" );
// This will return "true".
Console.WriteLine("IsNegativeInfinity(-5.0 / 0) == {0}.", Double.IsNegativeInfinity(-5.0 / 0) ? "true" : "false");
// This will return "true".
printfn $"IsNegativeInfinity(-5.0 / 0) = {Double.IsNegativeInfinity(-5. / 0.)}."
' This will return "True".
Console.Write("IsNegativeInfinity(-5.0 / 0) = ")
If Double.IsNegativeInfinity(-5 / 0) Then
    Console.WriteLine("True.")
Else
    Console.WriteLine("False.")
End If
if ( d > Double::MaxValue )
{
   Console::WriteLine( "Your number is bigger than a double." );
}
if (d > Double.MaxValue)
   Console.WriteLine("Your number is bigger than a double.");
if d > Double.MaxValue then
   printfn $"Your number is bigger than a double."
If D > Double.MaxValue Then
    Console.WriteLine("Your number is bigger than a double.")
End If
// This will equal Infinity.
Console::WriteLine( "10.0 minus NegativeInfinity equals {0}.", (10.0 - Double::NegativeInfinity) );
// This will equal Infinity.
Console.WriteLine("10.0 minus NegativeInfinity equals {0}.", (10.0 - Double.NegativeInfinity).ToString());
// This will equal Infinity.
printfn $"10.0 minus NegativeInfinity equals {10.0 - Double.NegativeInfinity}."
' This will equal Infinity.
Console.WriteLine("10.0 minus NegativeInfinity equals " + (10 - Double.NegativeInfinity).ToString() + ".")

설명

부동 소수점 연산이 반환 NegativeInfinity 되어 오버플로 조건을 신호로 보냅니다.

적용 대상

추가 정보