Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Harshad number
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Definition == Stated mathematically, let {{mvar|X}} be a positive integer with {{mvar|m}} digits when written in base {{mvar|n}}, and let the digits be <math>a_i</math> (<math>i = 0, 1, \ldots, m-1</math>). (It follows that <math>a_i</math> must be either zero or a positive integer up to {{tmath|n-1}}.) {{mvar|X}} can be expressed as :<math>X=\sum_{i=0}^{m-1} a_i n^i.</math> {{mvar|X}} is a harshad number in base {{mvar|n}} if: :<math>X \equiv 0 \bmod {\sum_{i=0}^{m-1} a_i}.</math> {{anchor|all-harshad number}} A number which is a harshad number in every number base is called an '''all-harshad number''', or an '''all-Niven number'''. There are only four all-harshad numbers: [[1 (number)|1]], [[2 (number)|2]], [[4 (number)|4]], and [[6 (number)|6]]. The number [[12 (number)|12]] is a harshad number in all bases except [[octal]].
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)