Harshad Number Checker

n mod digitSum(n) = 0

CalculatorsFreeNo Signup
4.7(608 reviews)
All Tools

Loading tool...

About Harshad Number Checker

A Harshad number checker determining if n is divisible by its digit sum. Shows digit sum, quotient, and lists Harshad numbers in a range. Also checks for strong Harshad and multi-Harshad properties. All calculations are client-side.

Harshad Number Checker Features

  • Harshad check
  • Digit sum
  • Strong Harshad
  • Range scan
  • Table
Harshad (Niven) number: n divisible by sum of its digits. Example: 18 → 1+8=9, 18÷9=2 ✓. Named from Sanskrit 'harsha' (joy). All single-digit numbers are Harshad. Strong Harshad: n/digitSum(n) is also prime.

How to Use

Enter n:

  • Harshad: n mod digitSum = 0
  • Digit sum: Sum of digits
  • Quotient: n/digitSum

Properties

  • All 1-digit numbers are Harshad
  • 1 to 10000: about 11% are Harshad
  • Consecutive Harshad: (1,2,...,9), (110,111,112)
  • No 21-consecutive Harshad numbers (base 10)

Strong Harshad

n is strong Harshad if n/digitSum(n) is prime. Used in Moran numbers: n/digitSum(n) is a prime AND that prime is unique to its digit sum value.

Step-by-Step Instructions

  1. 1Enter n.
  2. 2Check Harshad.
  3. 3View digit sum.
  4. 4Check strong Harshad.
  5. 5Scan range.

Harshad Number Checker — Frequently Asked Questions

What percentage of numbers are Harshad?+

Roughly 11% of numbers up to 10000 are Harshad. The density decreases as numbers get larger because digit sums grow slower than the numbers themselves. For n-digit numbers, the probability is approximately 1/4.5·ln(10).

Can there be many consecutive Harshad numbers?+

The maximum run of consecutive Harshad numbers in base 10 is 20 (starting at certain values). It's proven that there cannot be 21 consecutive Harshad numbers in base 10. In base b, the maximum run is 2b.

What is a strong Harshad number?+

n is strong Harshad if n/digitSum(n) is prime. Example: 18 → 18/9 = 2 (prime) ✓. Strong Harshad numbers were used by Curtis Cooper in the study of Moran numbers: numbers n where n/digitSum(n) is a new prime not previously seen.

Share this tool: