Click or drag to resize

PrimeNumberMathIsPrime Method

Determines whether x is a prime number.

Namespace: Altaxo.Calc
Assembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3448.0 (4.8.3448.0)
Syntax
C#
public static bool IsPrime(
	long x
)

Parameters

x  Int64
Number to test (must be > 0).

Return Value

Boolean
if x is prime; otherwise, .
Exceptions
ExceptionCondition
ArgumentOutOfRangeExceptionThrown if x is less than or equal to 0.
NotImplementedException Thrown if primality cannot be decided because the number requires trial division by primes greater than MaximumSupportedPrimeNumber.
See Also