Package-level declarations

Types

Link copied to clipboard
data class BezoutCoefficientsWithGCD<T>(val first: T, val second: T, val gcd: T)

Container for Bézout coefficients and GCD.

Functions

Link copied to clipboard
fun gcd(vararg values: Int): Int
fun gcd(vararg values: Long): Long
fun gcd(values: Iterable<Int>): Int
fun gcd(values: Iterable<Long>): Long
tailrec fun gcd(a: Int, b: Int): Int
tailrec fun gcd(a: Long, b: Long): Long

Computes Greatest Common Divisor of a and b.

Link copied to clipboard

Test for not primality of this.

Link copied to clipboard

Trivial primality test by checking its divisibility by every integer between its square root and 2.

Link copied to clipboard
fun kroneckerSymbol(a: Int, b: Int): Int

Computes Kronecker symbol of entries a and b.