Preprint
Article

This version is not peer-reviewed.

The Existence and Construction of Palindrome Numbers Divisible by 37

Submitted:

27 May 2024

Posted:

29 May 2024

You are already at the latest version

Abstract
The existence of palindrome numbers of arbitrary length greater than 2 that are divisible by the prime number 37 is proven in this paper. The method to construct such a palindrome is also described. It turns out that a palindrome number divisible by 37 is also divisible by 3 and, consequently, divisible by 111.
Keywords: 
;  ;  

Introduction

A palindrome number is an integer that has the same value after the digits in it are reversed. For example, 121 and 1221 are both palindrome numbers. Formally, let a 1 , a 2 , , a k { 0 , 1 , , 9 } be the digits of a k-digit decimal number denoted as a concatenation of digits as a 1 a 2 , a k . Then, the number a 1 a 2 a k is a palindrome number if and only if a i = a k + 1 i for all i. To eliminate the case of constructing new palindrome numbers simply by padding 0’s at the two ends of an existing one, it is required that a 1 = a k 0 throughout this paper.
Shown in the figure below is an ordinary calculator keypad. A total of 16 6-digit palindrome numbers can be constructed using the rows, columns and diagonals of this keypad, e.g., 123321 , 852258 , 951159 .
Preprints 107629 i001
An interesting fact about all these 16 palindrome numbers is that they are all divisible by 37 [1]. Inspired by this observation, this paper studies the existence and construction of palindrome numbers of arbitrary length that are divisible by 37, which is the 12th prime with many interesting properties [2,3]. An easy observation to make is that none in the set of 2-digit palindrome numbers, { 00 , 11 , 22 , 33 , 44 , 55 , 66 , 77 , 88 , 99 } , is divisible by 37. Thus, only palindrome numbers with 3 or more digits are considered here.
This paper is organized as follows. A lemma on the periodicity in taking powers of 10 modulo 37 is first proven in the next section. This lemma is critical in proving the results on palindrome numbers divisible by 37. Before applying this lemma on the general problem of palindrome numbers of arbitrary length divisible by 37, short palindrome numbers with 3, 4, and 5 digits divisible by 37 are shown to exist and constructed. Then, it is shown that this is also true for palindrome numbers of arbitrary longer length. Finally, conclusions are made on the existence and construction of palindrome numbers divisible by 37.

1. Powers of 10 Modulo 37

A k-digit palindrome number may have an even or odd number of digits. When k = 2 n for some n 2 , the palindrome number can be expressed as a 1 a n a n a 1 . The decimal value of this palindrome number is therefore a 1 a n a n a 1 = ( 10 2 n 1 + 1 ) a 1 + ( 10 2 n 2 + 10 ) a 2 + + ( 10 n + 10 n 1 ) a n , where the sums of pairs of powers of 10 in the parentheses are called coefficients. Similarly, when k = 2 n + 1 for some n 1 , the palindrome number can be expressed as a 1 a n m a n a 1 , where m { 0 , 1 , , 9 } stands for the digit in the middle. The decimal value of this palindrome number is therefore a 1 a n m a n a 1 = ( 10 n ) m + ( 10 2 n + 1 ) a 1 + ( 10 2 n 1 + 10 ) a 2 + + ( 10 n + 1 + 10 n 1 ) a n . It is not hard to see that the coefficients decide if the palindrome is divisible by 37 or not. This implies that it is worthwhile to look into how the set of different powers of 10 behave modulo 37. The following lemma shows an important property of powers of 10 modulo 37.
Lemma 1.1. 
10 i + 3 10 i ( mod 37 ) for all nonnegative integer i.
Proof. 
Note that 10 i + 3 10 i = ( 10 3 1 ) 10 i = ( 999 ) 10 i . Since 37 999 , 10 i + 3 10 i 0 ( mod 37 ) . □
As a consequence of this lemma, a power of 10 is congruent to only three possible distinct values modulo 37, namely 1, 10, and 26. In other words, the set of powers of 10, { 10 0 , 10 1 , 10 2 , 10 3 , } , is congruent to the set { 1 , 10 , 26 , 1 , 10 , 26 , } modulo 37.

2. Existence and Construction of Palindrome Numbers Divisible by 37

The problem of wether palindrome numbers divisible by 37 of arbitrary length greater than 2 exist and how to construct them if they do will be studied in this section. The case when k, the number of digits in the palindrome number, is small is discussed first.

2.1. k = 3 , 4 or 5

When k = 3 , the palindrome number can be expressed as a 1 m a 1 . According to the following lemma, 3-digit palindrome numbers divisible by 37 exist and can be easily constructed.
Lemma 2.1. 
A 3-digit palindrome number a 1 m a 1 is divisible by 37 if and only if m = a 1 .
Proof. 
Note that the decimal vale of the palindrome number a 1 m a 1 can be found as
a 1 m a 1 = ( 10 2 + 1 ) a 1 + ( 10 ) m ( 26 + 1 ) a 1 + 10 m ( mod 37 ) 10 ( a 1 m ) ( mod 37 ) .
Suppose that a 1 m a 1 0 ( mod 37 ) . Then, 10 ( a 1 m ) 0 ( mod 37 ) , or, equivalently, a 1 m 0 ( mod 37 ) . This implies m = a 1 .
The other direction can be easily shown simply by reversing the above steps. □
As a consequence of this lemma, all digits must be equal for a 3-digit palindrome number to be divisible by 37. Thus, there are nine nonzero palindrome numbers that are divisible by 37. Namely, they are 111, 222, 333, 444, 555, 666, 777, 888, 999. Notice that they are also divisible by 3 and 111.
Similarly, the following lemmas concern the cases when k = 4 and k = 5 .
Lemma 2.2. 
A 4-digit palindrome number a 1 a 2 a 2 a 1 is divisible by 37 if and only if 2 a 1 = a 2 .
Proof. 
Note that
a 1 a 2 a 2 a 1 = ( 10 3 + 1 ) a 1 + ( 10 2 + 10 ) a 2 ( 1 + 1 ) a 1 + ( 26 + 10 ) a 2 ( mod 37 ) 2 a 1 a 2 ( mod 37 ) .
Suppose that a 1 a 2 a 2 a 1 0 ( mod 37 ) . Then, 2 a 1 a 2 0 ( mod 37 ) . This implies 2 a 1 = a 2 .
The other direction can be easily shown simply by reversing the above steps. □
As a consequence of this lemma, there are only four 4-digit palindrome numbers that are divisible by 37. Namely, they are 1221, 2442, 3663, 4884. Notice that they are also divisible by 3 and 111.
Lemma 2.3. 
A 5-digit palindrome number a 1 a 2 m a 2 a 1 is divisible by 37 if and only if m = a 1 + a 2 .
Proof. 
Note that
a 1 a 2 m a 2 a 1 = ( 10 2 ) m + ( 10 4 + 1 ) a 1 + ( 10 3 + 10 ) a 2 ( 26 ) m + ( 10 + 1 ) a 1 + ( 1 + 10 ) a 2 ( mod 37 ) 11 m + 11 ( a 1 + a 2 ) ( mod 37 ) .
Suppose that a 1 a 2 m a 2 a 1 0 ( mod 37 ) . Then, 11 m + 11 ( a 1 + a 2 ) 0 ( mod 37 ) . This implies m = a 1 + a 2 .
The other direction can be easily shown simply by reversing the above steps. □
Notice that, since m = a 1 + a 2 , the sum of all digits in the palindrome number is 3 m . Thus, the palindrome number is also divisible by 3, and consequently, by 111.
The problem when k > 5 can be divided into two cases: even or odd number of digits in the palindrome number.

2.2. Even Number of Digits

Suppose that there are k = 2 n digits in the palindrome numbers for some integer n 3 . The palindrome can then be expressed as a 1 a n a n a 1 . The decimal value of this palindrome number can be found as ( 10 2 n 1 + 10 0 ) a 1 + ( 10 2 n 2 + 10 1 ) a 2 + + ( 10 n + 10 n 1 ) a n . Note that all coefficients are sums of two powers of 10. Using lemma 1.1, these coefficients are congruent to one of the following three sets of values:
{ 26 + 1 , 10 + 10 , 1 + 26 , 26 + 1 , 10 + 10 , } { 10 , 20 , 10 , 10 , 20 , } for n = 3 j , j = 1 , 2 , ,
{ 10 + 1 , 1 + 10 , 26 + 26 , 10 + 1 , 1 + 10 , } { 11 , 11 , 22 , 11 , 11 , } for n = 3 j + 1 , j = 1 , 2 , , and
{ 1 + 1 , 26 + 10 , 10 + 26 , 1 + 1 , 26 + 10 , } { 2 , 1 , 1 , 2 , 1 , } for n = 3 j + 2 , j = 1 , 2 , .
The following observations can be made to all three sets: there are only two distinct values in each set, the two distinct values have opposite signs, and the absolute value of one of the two distinct values is twice the other. All these guarantee the existence of 2 n -digit palindrome numbers divisible by 37 for all n 3 . The following theorem, which is already proven, summarizes this result.
Theorem 2.4. 
There always exist 2 n -digit palindrome numbers, denoted as a 1 a n a n a 1 , that are divisible by 37 for all n 3 . To construct such a number, there are following three cases:
Case 1: When n = 3 j for j = 1 , 2 , , the 2 n -digit palindrome number is divisible by 37 if and only if the digits satisfy the identity 2 i = 1 n 3 a 3 i 1 = i = 1 n 3 a 3 i 2 + i = 1 n 3 a 3 i .
Case 2: When n = 3 j + 1 for j = 1 , 2 , , the 2 n -digit palindrome number is divisible by 37 if and only if the digits satisfy the identity 2 i = 1 n 3 a 3 i = i = 1 n 3 a 3 i 2 + i = 1 n 3 a 3 i 1 .
Case 3: When n = 3 j + 2 for j = 1 , 2 , , the 2 n -digit palindrome number is divisible by 37 if and only if the digits satisfy the identity 2 i = 1 n 3 a 3 i 2 = i = 1 n 3 a 3 i 1 + i = 1 n 3 a 3 i .
Example: Consider 6-digit palindrome numbers.
Since n = 3 , using case 1 in the theorem, the 3 digits, a 1 , a 2 , a 3 , in the palindrome number must satisfy the identity 2 a 2 = a 1 + a 3 such that it is divisible by 37. This implies that a 2 must be an average of a 1 and a 3 . This explains why all 16 palindrome numbers constructed from the calculator keypad are divisible by 37.
Example: Construct a 16-digit palindrome number divisible by 37.
Since n = 8 , the palindrome number looks like a 1 a 2 a 7 a 8 a 8 a 7 a 2 a 1 . Using case 3 in the theorem, a 1 , , a 8 must satisfy the identity 2 ( a 1 + a 4 + a 7 ) = ( a 2 + a 5 + a 8 ) + ( a 3 + a 6 ) . Let a 2 = 2 , a 3 = 3 , a 5 = 4 , a 6 = 7 , a 8 = 6 and a 1 = 4 , a 4 = 5 , a 7 = 2 . Then, 4235472662745324 0 ( mod 37 ) .

2.3. Odd Number of Digits

Suppose that there are k = 2 n + 1 digits in the palindrome numbers for some integer n 3 . The palindrome can then be expressed as a 1 a n m a n a 1 , where m { 0 , 1 , , 9 } is the digit in the middle. The decimal value of this palindrome number is therefore ( 10 n ) m + ( 10 2 n + 1 ) a 1 + ( 10 2 n 1 + 10 ) a 2 + + ( 10 n + 1 + 10 n 1 ) a n .
Again, the coefficients decide if the palindrome number is divisible by 37 or not. Using lemma 1.1, this set of coefficients is congruent to one of the following three sets of values:
{ 1 , 1 + 1 , 26 + 10 , 10 + 26 , 1 + 1 , 26 + 10 , } { 1 , 2 , 1 , 1 , 2 , 1 , 1 , } for n = 3 j , j = 1 , 2 , ,
{ 10 , 26 + 1 , 10 + 10 , 1 + 26 , 26 + 1 , 10 + 10 , } { 10 , 10 , 20 , 10 , 10 , 20 , 10 , } for n = 3 j + 1 , j = 1 , 2 , , and
{ 26 , 10 + 1 , 1 + 10 , 26 + 26 , 10 + 1 , 1 + 10 , } { 11 , 11 , 11 , 22 , 11 , 11 , 22 , } for n = 3 j + 2 , j = 1 , 2 , .
Ignoring the first coefficient for m in each set, these sets show exactly the same structures, and thus, have the same properties as those in the previous section. Adding the coefficient of m to the sets does add a new distinct value to them. However, it does not add any new distinct absolute value to the sets. This guarantees the existence of 2 n + 1 -digit palindrome numbers that are divisible by 37. The following theorem, which is already proven, summarizes this result:
Theorem 2.5. 
There always exist ( 2 n + 1 ) -digit palindrome numbers, denoted as a 1 a n m a n a 1 , that are divisible by 37 for all n 3 . To construct such a palindrome number, there are following three cases:
Case 1: When n = 3 j , j = 1 , 2 , , the ( 2 n + 1 ) -digit palindrome number is divisible by 37 if and only if m and digits a 1 , , a n satisfy the identity m + 2 i = 1 n 3 a 3 i 2 = i = 1 n 3 a 3 i 1 + i = 1 n 3 a 3 i .
Case 2: When n = 3 j + 1 , j = 1 , 2 , , the ( 2 n + 1 ) -digit palindrome number is divisible by 37 if and only if m and digits a 1 , , a n satisfy the identity m + 2 i = 1 n 3 a 3 i 1 = i = 1 n 3 a 3 i 2 + i = 1 n 3 a 3 i .
Case 3: When n = 3 j + 2 , j = 1 , 2 , , the ( 2 n + 1 ) -digit palindrome number is divisible by 37 if and only if m and digits a 1 , , a n satisfy the identity m + 2 i = 1 n 3 a 3 i = i = 1 n 3 a 3 i 1 + i = 1 n 3 a 3 i 2 .
Example: Construct a 15-digit palindrome number divisible by 37.
Since n = 7 , the palindrome number looks like a 1 a 2 a 6 a 7 m a 7 a 6 a 2 a 1 . Using case 2 in the theorem, m and a 1 , , a 8 must satisfy the identity m + 2 ( a 2 + a 5 ) = ( a 1 + a 4 + a 7 ) + ( a 3 + a 6 ) . Let m = 3 , a 2 = 5 , a 5 = 7 and a 1 = 7 , a 3 = 9 , a 4 = 0 , a 6 = 8 , a 7 = 3 . Then, 759078333870957 0 ( mod 37 ) .

3. Properties of Palindrome Numbers Divisible by 37

Corollary 3.0.1. 
If a palindrome number is divisible by 37, then it is also divisible by 3.
Proof. 
It is already shown to be true for k = 3 , 4 and 5.
When the palindrome number has k = 2 n , n 3 , digits, these digits must satisfy identities in the format of 2 S 1 = S 2 , where S 1 is the sum of a certain group of digits and S 2 is the sum of the remaining digits. Since there exist two copies of the same digit in the palindrome, the sum of all the digits in it is 2 ( S 1 + S 2 ) = 2 S 1 + 2 S 2 = S 2 + 2 S 2 = 3 S 2 . Therefore, the palindrome number is divisible by 3.
When the palindrome number has k = 2 n + 1 , n 3 , digits, with middle digit m, these digits must satisfy identities in the format of m + 2 S 1 = S 2 . Since there exist two copies of the same digit in the palindrome except the digit m, the sum of all the digits in it is m + 2 ( S 1 + S 2 ) = m + 2 S 1 + 2 S 2 = 3 S 2 . Therefore, the palindrome number is also divisible by 3. □
Corollary 3.0.2. 
If a palindrome number is divisible by 37, then it is also divisible by 111.
Proof. 
By Corollary 3.0.1, a palindrome number divisible by 37 is also divisible by 3. Therefore, it is divisible by 3 × 37 = 111 . □

4. Conclusions

The prime number 37 has a lot of interesting properties. Another property of it is presented in this paper. That is, there always exist palindrome numbers of arbitrary length greater than 2 that are divisible by 37. A systematic method to construct such a palindrome number is also described in this paper. It turns out that a palindrome number divisible by 37 is also divisible by 3, and consequently divisible by 111, which is a palindrome number too. More properties of these palindrome numbers may be discovered from future work. A way to enumerate them is still lacking and may warrant further investigation.

References

  1. Digital Genius, "It’s just a coincidence". Available online: https://www.youtube.com/watch?v=5OzZqJcltpM.
  2. Wikipedia contributors, "37 (number)," Wikipedia, The Free Encyclopedia. Available online: https://en.wikipedia.org/w/index.php?title=37_(number)&oldid=1224293983.
  3. Veritasium, "Why is this number everywhere?". Available online: https://www.youtube.com/watch?v=d6iQrh2TK98&t=237s.
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.
Prerpints.org logo

Preprints.org is a free preprint server supported by MDPI in Basel, Switzerland.

Subscribe

Disclaimer

Terms of Use

Privacy Policy

Privacy Settings

© 2025 MDPI (Basel, Switzerland) unless otherwise stated