Properties

69 properties across 8 groups.

Classification

is_natural
Natural (boolean)

Is a natural number (positive integer)

is_integer
Integer (boolean)

Is an integer

is_rational
Rational (boolean)

Is a rational number

is_real
Real (boolean)

Is a real number

is_complex
Complex (boolean)

Is a complex number

is_even
Even (boolean)

An even number is an integer that is divisible by 2, i.e., there exists an integer k such that n = 2k.

is_odd
Odd (boolean)

An odd number is an integer that is NOT divisible by 2, i.e., there exists an integer k such that n = 2k + 1.

Derived Values

totient
Euler's Totient (numeric)

Euler's totient function φ(n) counts the positive integers up to n that are relatively prime to n (i.e., gcd(k, n) = 1 for 1 ≤ k ≤ n).

mobius
Möbius Function (numeric)

The Möbius function μ(n) is defined as:

radical
Radical (numeric)

The radical of a positive integer n, denoted rad(n), is the product of all distinct prime factors of n.

omega
Omega Function (Ω) (numeric)

The big omega function Ω(n) counts the prime factors of n with multiplicity.

little_omega
Little Omega Function (ω) (numeric)

The little omega function ω(n) counts the distinct prime factors of n.

Digital Properties

digit_count
Digit Count (numeric)

The digit count of a positive integer n is the number of digits in its decimal representation.

digit_sum
Digit Sum (numeric)

The digit sum of a non-negative integer is the sum of all its digits in its decimal representation.

digital_root
Digital Root (numeric)

The digital root of a positive integer is the single-digit value obtained by repeatedly summing the digits until only one digit remains.

is_palindrome
Palindromic Number (boolean)

A palindromic number is a number that remains the same when its digits are reversed.

is_repdigit
Repdigit (boolean)

A repdigit (repeated digit) is a positive integer composed entirely of the same digit.

is_automorphic
Automorphic (boolean)

An automorphic number (or circular number) is a number whose square ends with the number itself.

is_kaprekar
Kaprekar Number (boolean)

A Kaprekar number is a positive integer n such that when n² is split into two parts (left and right), the sum of those parts equals n.

persistence
Multiplicative Persistence (numeric)

The multiplicative persistence of a number n is the number of times you must multiply its digits together until you reach a single digit.

Divisibility

divisor_count
Divisor Count (numeric)

The divisor count (or divisor function τ(n), also written d(n)) counts the number of positive divisors of n, including 1 and n itself.

divisor_sum
Divisor Sum (numeric)

The divisor sum σ(n) is the sum of all positive divisors of n, including 1 and n itself.

proper_divisor_sum
Proper Divisor Sum (Aliquot Sum) (numeric)

The proper divisor sum (or aliquot sum) s(n) is the sum of all positive divisors of n excluding n itself.

is_abundant
Abundant Number (boolean)

An abundant number (or excessive number) is a positive integer n for which the sum of its proper divisors exceeds n itself.

is_perfect
Perfect Number (boolean)

A perfect number is a positive integer that equals the sum of its proper divisors (all divisors excluding itself).

is_deficient
Deficient Number (boolean)

A deficient number is a positive integer n for which the sum of its proper divisors is less than n.

is_highly_composite
Highly Composite (boolean)

A highly composite number (HCN) is a positive integer with more divisors than any smaller positive integer.

is_weird
Weird Number (boolean)

A weird number is a natural number that is: 1. Abundant: Sum of proper divisors > n 2. Not semiperfect: Cannot equal any subset sum of its proper divisors

is_untouchable
Untouchable Number (boolean)

An untouchable number is a positive integer that is NOT the sum of proper divisors of any number.

is_abundant_primitive
Primitive Abundant (boolean)

A primitive abundant number is an abundant number none of whose proper divisors are abundant.

Figurate Numbers

is_fibonacci
Fibonacci Number (boolean)

A Fibonacci number is any number that appears in the Fibonacci sequence, where each number is the sum of the two preceding ones.

is_triangular
Triangular Number (boolean)

A triangular number counts objects that can form an equilateral triangle. The nth triangular number is the sum of the first n positive integers:

is_square
Perfect Square (boolean)

A perfect square (or square number) is an integer that can be expressed as the square of another integer.

is_cube
Perfect Cube (boolean)

A perfect cube (or cube number) is an integer that can be expressed as the cube of another integer.

is_pentagonal
Pentagonal Number (boolean)

A pentagonal number counts objects that can form a regular pentagon pattern. The nth pentagonal number is:

is_hexagonal
Hexagonal Number (boolean)

A hexagonal number counts objects that can form a regular hexagon pattern. The nth hexagonal number is:

is_lucas
Lucas Number (boolean)

A number m is a Lucas number if it appears in the Lucas sequence, defined by:

is_tetrahedral
Tetrahedral Number (boolean)

A tetrahedral number Teₙ is a figurate number that represents a tetrahedron (triangular pyramid). It equals the sum of the first n triangular numbers:

is_pell
Pell Number (boolean)

A number m is a Pell number if it appears in the Pell sequence defined by:

is_tribonacci
Tribonacci Number (boolean)

A number m is a Tribonacci number if it appears in the Tribonacci sequence:

is_pronic
Pronic Number (boolean)

A pronic number (or oblong/heteromecic number) is the product of two consecutive integers:

Primality

is_prime
Prime (boolean)

A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself.

is_composite
Composite Number (boolean)

A composite number is a positive integer greater than 1 that has at least one positive divisor other than 1 and itself.

is_semiprime
Semiprime (boolean)

A semiprime (also called biprime or 2-almost prime) is a natural number that is the product of exactly two prime numbers (not necessarily distinct).

is_squarefree
Squarefree Number (boolean)

A squarefree number is a positive integer that is not divisible by any perfect square other than 1.

is_prime_power
Prime Power (boolean)

A prime power is a positive integer that can be expressed as p^k where p is a prime and k ≥ 1.

prime_factorization
Prime Factorization (json)

The prime factorization of a positive integer is its unique representation as a product of prime powers.

is_twin_prime
Twin Prime (boolean)

A twin prime is a prime number that is part of a twin prime pair — two primes that differ by exactly 2.

is_mersenne_prime
Mersenne Prime (boolean)

A Mersenne prime is a prime number of the form 2^p - 1, where p itself must be prime.

is_sophie_germain
Sophie Germain Prime (boolean)

A Sophie Germain prime is a prime p such that 2p + 1 is also prime.

is_safe_prime
Safe Prime (boolean)

A safe prime is a prime q of the form q = 2p + 1, where p is also prime.

is_powerful
Powerful Number (boolean)

A powerful number (or squareful number) is a positive integer n such that for every prime p dividing n, p² also divides n.

is_achilles
Achilles Number (boolean)

An Achilles number is a positive integer that is: 1. Powerful — every prime factor appears with exponent ≥ 2 2. Not a perfect power — cannot be written as m^k for any m, k ≥ 2

prime_index
Prime Index (numeric)

The prime index or prime-counting function π(n) gives the number of primes less than or equal to n.

is_perfect_power
Perfect Power (boolean)

A perfect power is a positive integer n that can be expressed as m^k where m ≥ 1 and k ≥ 2.

is_smooth
Smooth Number (boolean)

A B-smooth number (or B-friable number) is a positive integer whose prime factors are all at most B.

is_carmichael
Carmichael Number (boolean)

A Carmichael number is a composite number n that satisfies Fermat's Little Theorem for ALL bases coprime to n:

Recreational

is_happy
Happy Number (boolean)

A happy number is a positive integer that eventually reaches 1 when replaced repeatedly by the sum of the squares of its digits.

is_harshad
Harshad Number (boolean)

A Harshad number (or Niven number) is a positive integer that is divisible by the sum of its digits.

is_narcissistic
Narcissistic Number (boolean)

A narcissistic number (also called Armstrong number or pluperfect digital invariant) is a number that equals the sum of its digits each raised to the power of the number of digits.

collatz_steps
Collatz Steps (numeric)

The Collatz steps (or total stopping time) of a positive integer n is the number of iterations needed to reach 1 using the Collatz function:

is_smith
Smith Number (boolean)

A Smith number is a composite number where the sum of its digits equals the sum of the digits of its prime factorization (with multiplicity).

is_vampire
Vampire Number (boolean)

A vampire number is a composite natural number with an even number of digits, that can be factored into two integers (called "fangs") each with half as many digits, where the digits of the original number can be rearranged to form the fangs.

Special

is_factorial
Factorial (boolean)

A number n is a factorial number if n = k! for some non-negative integer k.

is_catalan
Catalan Number (boolean)

A number m is a Catalan number if m = Cₙ for some non-negative integer n, where:

is_bell
Bell Number (boolean)

A number m is a Bell number if m = Bₙ for some non-negative integer n, where Bₙ counts the number of ways to partition a set of n elements into non-empty subsets.

is_motzkin
Motzkin Number (boolean)

A number m is a Motzkin number if m = Mₙ for some n, where Mₙ counts: - Lattice paths from (0,0) to (n,0) using up, down, and flat steps - Non-intersecting chord diagrams on n points (with unpaired points allowed)

is_lucky
Lucky Number (boolean)

Lucky numbers are generated by a sieve similar to Eratosthenes, but using position-based elimination:

is_primorial
Primorial (boolean)

A number m is a primorial if m = p