Click or drag to resize

isPrimeisProbablyPrime Method (Int64, RandomGenerator)

Performs a statistical trial to check for primality.

Namespace:  NumberStone
Assembly:  WhetStone (in WhetStone.dll) Version: 1.0.4.0 (1.0.0.0)
Syntax
C#
public static bool isProbablyPrime(
	this long x,
	RandomGenerator generator
)

Parameters

x
Type: SystemInt64
The number to check.
generator
Type: WhetStone.RandomRandomGenerator
The RandomGenerator to get the trial seeds from.

Return Value

Type: Boolean

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Int64. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
Remarks

means that x is definitely not prime, means the number is prime to 0.5 certainty.

See Also