In
number theory
Number theory (or arithmetic or higher arithmetic in older usage) is a branch of pure mathematics devoted primarily to the study of the integers and integer-valued functions. German mathematician Carl Friedrich Gauss (1777–1855) said, "Math ...
, a factorion in a given
number base is a
natural number
In mathematics, the natural numbers are those numbers used for counting (as in "there are ''six'' coins on the table") and ordering (as in "this is the ''third'' largest city in the country").
Numbers used for counting are called '' cardinal ...
that equals the sum of the
factorial
In mathematics, the factorial of a non-negative denoted is the product of all positive integers less than or equal The factorial also equals the product of n with the next smaller factorial:
\begin
n! &= n \times (n-1) \times (n-2) ...
s of its
digits.
The name factorion was coined by the author
Clifford A. Pickover.
Definition
Let
be a natural number. For a base
, we define the sum of the factorials of the digits
of
,
, to be the following:
:
where
is the number of digits in the number in base
,
is the
factorial
In mathematics, the factorial of a non-negative denoted is the product of all positive integers less than or equal The factorial also equals the product of n with the next smaller factorial:
\begin
n! &= n \times (n-1) \times (n-2) ...
of
and
:
is the value of the
th digit of the number. A natural number
is a
-factorion if it is a
fixed point for
, i.e. if
.
and
are fixed points for all bases
, and thus are trivial factorions for all
, and all other factorions are nontrivial factorions.
For example, the number 145 in base
is a factorion because
.
For
, the sum of the factorials of the digits is simply the number of digits
in the base 2 representation since
.
A natural number
is a sociable factorion if it is a
periodic point In mathematics, in the study of iterated functions and dynamical systems, a periodic point of a function is a point which the system returns to after a certain number of function iterations or a certain amount of time.
Iterated functions
Given ...
for
, where
for a positive
integer
An integer is the number zero (), a positive natural number (, , , etc.) or a negative integer with a minus sign ( −1, −2, −3, etc.). The negative numbers are the additive inverses of the corresponding positive numbers. In the language ...
, and forms a
cycle
Cycle, cycles, or cyclic may refer to:
Anthropology and social sciences
* Cyclic history, a theory of history
* Cyclical theory, a theory of American political history associated with Arthur Schlesinger, Sr.
* Social cycle, various cycles in soc ...
of period
. A factorion is a sociable factorion with
, and a amicable factorion is a sociable factorion with
.
All natural numbers
are
preperiodic points for
, regardless of the base. This is because all natural numbers of base
with
digits satisfy
. However, when
, then
for
, so any
will satisfy
until
. There are finitely many natural numbers less than
, so the number is guaranteed to reach a periodic point or a fixed point less than
, making it a preperiodic point. For
, the number of digits
for any number, once again, making it a preperiodic point. This means also that there are a finite number of factorions and
cycles for any given base
.
The number of iterations
needed for
to reach a fixed point is the
function's
persistence of
, and undefined if it never reaches a fixed point.
Factorions for
''b'' = (''k'' − 1)!
Let
be a positive integer and the number base
. Then:
*
is a factorion for
for all
*
is a factorion for
for all
.
''b'' = ''k''! − ''k'' + 1
Let
be a positive integer and the number base
. Then:
*
is a factorion for
for all
.
Table of factorions and cycles of
All numbers are represented in base
.
Programming example
The example below implements the sum of the factorials of the digits described in the definition above
to search for factorions and cycles in
Python.
def factorial(x: int) -> int:
total = 1
for i in range(0, x):
total = total * (i + 1)
return total
def sfd(x: int, b: int) -> int:
"""Sum of the factorials of the digits."""
total = 0
while x > 0:
total = total + factorial(x % b)
x = x // b
return total
def sfd_cycle(x: int, b: int) -> List nt
seen = []
while x not in seen:
seen.append(x)
x = sfd(x, b)
cycle = []
while x not in cycle:
cycle.append(x)
x = sfd(x, b)
return cycle
See also
*
Arithmetic dynamics Arithmetic dynamics is a field that amalgamates two areas of mathematics, dynamical systems and number theory. Classically, discrete dynamics refers to the study of the iteration of self-maps of the complex plane or real line. Arithmetic dynamics is ...
*
Dudeney number In number theory, a Dudeney number in a given number base b is a natural number equal to the perfect cube of another natural number such that the digit sum of the first natural number is equal to the second. The name derives from Henry Dudeney, ...
*
Happy number
In number theory, a happy number is a number which eventually reaches 1 when replaced by the sum of the square of each digit. For instance, 13 is a happy number because 1^2+3^2=10, and 1^2+0^2=1. On the other hand, 4 is not a happy number because ...
*
Kaprekar's constant
*
Kaprekar number
In mathematics, a natural number in a given number base is a p-Kaprekar number if the representation of its square in that base can be split into two parts, where the second part has p digits, that add up to the original number. The numbers are ...
*
Meertens number In number theory and mathematical logic, a Meertens number in a given number base b is a natural number that is its own Gödel number. It was named after Lambert Meertens by Richard S. Bird as a present during the celebration of his 25 years at t ...
*
Narcissistic number
In number theory, a narcissistic number 1 F_ : \mathbb \rightarrow \mathbb to be the following:
: F_(n) = \sum_^ d_i^k.
where k = \lfloor \log_ \rfloor + 1 is the number of digits in the number in base b, and
: d_i = \frac
is the value of each d ...
*
Perfect digit-to-digit invariant In number theory, a perfect digit-to-digit invariant (PDDI; also known as a Munchausen number) is a natural number in a given number base b that is equal to the sum of its digits each raised to the power of itself. An example in base 10 is 3435, be ...
*
Perfect digital invariant In number theory, a perfect digital invariant (PDI) is a number in a given number base (b) that is the sum of its own digits each raised to a given power (p). 0 F_ : \mathbb \rightarrow \mathbb is defined as:
:F_(n) = \sum_^ d_i^p.
where k = \lfl ...
*
Sum-product number
A sum-product number in a given number base b is a natural number that is equal to the product of the sum of its digits and the product of its digits.
There are a finite number of sum-product numbers in any given base b. 1 F_ : \mathbb \rightarr ...
References
External links
Factorion at Wolfram MathWorld
{{Classes of natural numbers
Arithmetic dynamics
Base-dependent integer sequences