number theory calculators

Divisibility Test Calculator

Test whether a specific number is divisible by a chosen divisor, or count all divisors up to a custom limit. Useful for simplifying fractions, factoring integers, and classroom exercises.

About this calculator

Divisibility testing relies on the modulo operation: an integer n is divisible by d if n mod d = 0, meaning d divides n with no remainder. For a single test the check is simply number % divisor === 0, returning 'Divisible' or 'Not Divisible'. In range mode the calculator loops i from 1 to max_divisor, incrementing a counter each time number % i = 0, effectively counting all divisors of the number up to that bound. The total divisor count relates to the prime factorization: if n = p₁^a₁ · p₂^a₂ · … then the total number of divisors is (a₁+1)(a₂+1)…. Knowing all divisors is the first step toward computing GCD, LCM, or determining primality.

How to use

Single test: enter number = 144, divisor = 12. The calculator checks 144 % 12 = 0, so the result is Divisible. Range test: enter number = 144, max_divisor = 144. The calculator loops from i = 1 to 144, finding 1, 2, 3, 4, 6, 8, 9, 12, 16, 18, 24, 36, 48, 72, 144 — fifteen divisors in total. The output reads 'Found 15 divisors', matching the formula (4+1)(2+1) = 15 from the prime factorization 144 = 2⁴ × 3².

Frequently asked questions

What is the difference between the divisibility rules checker and the divisibility test calculator?

The divisibility rules checker focuses on educational explanations of the classic shortcut rules (digit-sum tricks, last-digit tests) for divisors 2 through 13 or a custom single value. The divisibility test calculator is more computational: it performs a direct modulo test for any divisor and also supports a range mode that counts all divisors of a number up to a specified limit. Use the rules checker to learn why divisibility works; use the test calculator when you need a quick, flexible arithmetic answer.

How do I find all divisors of a large number using this calculator?

Switch to range mode, enter your number, and set max_divisor equal to the number itself. The calculator will iterate from 1 to that limit and collect every value of i where number % i = 0. For very large numbers this may take a moment since the algorithm runs in O(n) time. If you only need divisors up to the square root — which is sufficient to reconstruct all pairs — you can enter max_divisor as the integer square root of your number and manually pair each result with its complement.

Why does knowing a number's divisors matter in everyday math?

Divisors underpin fraction simplification: to reduce 56/84 you need to know that 28 divides both. They are central to finding the GCD and LCM, which appear in scheduling problems (when do two events coincide?), unit conversions, and recipe scaling. In cryptography, the difficulty of factoring large numbers into their prime divisors is the security foundation of RSA encryption. Even in simple tasks like splitting items into equal groups, you are implicitly checking divisibility.