Thursday, 20 December 2018

A Prime to Remember

Primes come and go but lately, as I keep a daily track of the number of my diurnal days, there has been more than usual. To illustrate, days 25447, 25453, 25457, 25463, 25469, and 25471 are all primes in a 6-4-6-6-2 pattern. After 25471 there will quite a drought because the next prime is 25523, a gap of 32.

Today I'm 25463 days old and I can't let it pass without recording some of its more interesting properties. One of these is that it is a member of OEIS A165572: the greater prime factor of successively better Golden Semiprimes. These semiprimes p*q, starting from 6=2*3, have the property that each successive value of q/p gives a better approximation of the Golden Ratio than the previous term where the $$ \text{Golden Ratio } \phi=\frac{1+\sqrt(5)}{2} \approx \, 1.61803398874989$$Here are the initial members of this sequence: 3, 5, 11, 31, 37, 47, 157, 571, 911, 1021, 1487, 2351, 3571, 24709, 25463. The corresponding semiprimes form OEIS A165570 and consist of 6, 15, 77, 589, 851, 1363, 15229, 201563, 512893, 644251, 1366553, 3416003, 7881197, 377331139, 400711231, 2963563859, 4035221017.

Here are the progressively better approximations as the larger factor of the semiprime is divided by the smaller:

3/2         1.50000000000000
        5/3         1.66666666666667
        11/7         1.57142857142857
    31/19         1.63157894736842
      37/23         1.60869565217391
     47/29         1.62068965517241
157/97         1.61855670103093
  571/353         1.61756373937677
    911/563         1.61811722912966
1021/631         1.61806656101426
1487/919         1.61806311207835
 2351/1453         1.61803165863730
  3571/2207         1.61803352967830
 24709/15271         1.61803418243730
25463/15737         1.61803393276991

Another property of 25463, albeit a base dependent one, is its membership in OEIS A156119: primes formed by rearranging five consecutive decimal digits (avoiding leading 0). No primes can be formed from {1,2,3,4,5} or {4,5,6,7,8} since they are divisible by three. Sequence is finite, ending with a(52)=96857. Initial members of sequence are: 10243, 12043, 20143, 20341, 20431, 23041, 24103, 25463.

Yet another property, again base dependent, is its membership of OEIS A124629: primes p such that their cubes are pandigital, meaning all digits from 0 to 9 must appear at least once; here 25463^3=16509301927847. The initial members of this sequence are: 5437, 6221, 7219, 8443, 10903, 11353, 15937, 17123, 18229, 19429, 20353, 20903, 20929, 21803, 21841, 21961, 22123, 22283, 22993, 23053, 23369, 23663, 24733, 25183, 25219, 25463.

Not base dependent is the property that 25463 shares as a member of OEIS A226154: smallest of four consecutive primes whose sum is a triangular number. Triangular numbers are of the form:$$ \binom{n}{2}= \frac{n \, (n-1)}{2}$$The initial members of this sequence are: 5, 23, 191, 389, 449, 2593, 3011, 5167, 5639, 5851, 8669, 18839, 25463. Here the four primes add to 101926 = 25463+25469+25471+25523 and this sum is a triangular number because: $$101926 = \binom{452}{2}=\frac{452 \times 451}{2}$$ 

Finally and again base independently, 25463 is a member of OEIS A022121: Fibonacci sequence beginning 3, 8. The initial members of this sequence are: 3, 8, 11, 19, 30, 49, 79, 128, 207, 335, 542, 877, 1419, 2296, 3715, 6011, 9726, 15737, 25463.

Random Walks

Let's consider the following situation. We start at the origin (0,0) and want to get to the point (4,4). However, we can only move one step at a time, either horizontally or vertically. We are constrained to move within the grid of points shown. Given this constraint, horizontal movement can be to the left or right and vertical movement can be up or down. However, we have no control over this step by step movement. It is completely random. On average, how many steps should be required to reach our destination?

FIGURE 1

I set up a program in SageMathCell to simulate this random walk over 1,000 trials. The result returned a median walk of 60 steps. What happens as the grid grows larger? I was interested in looking at the relationship between the size of the grid and the average number of steps required to reach the goal. Here are the results for grids with of size 1 to 21 and a graphical representation in FIGURE 2:

1234567891011
2143460108156224289388534587


12131415161718192021
76288411041270142016571785211424422693


FIGURE 2

Not surprisingly the graph seems to be that of a parabola and my best fit formula, based on the above data, gives its equation as \(y=5.2 \, x^2\). 

This type of walk can be extended to 3 dimensions so that from (0, 0, 0) we need to get to (2, 2, 2) for example:

FIGURE 3

Running a thousand trials again on SageMathCell again, we get a median of 40 steps with a minimum of 6 (the least possible) and a maximum of 344. What's surprising is the vastly different lengths of these random walks. For example, with a cube of side 10, a median of 3075 steps is returned from the thousand trials but the maximum is 46826 and the minimum is 114. Here are the results (the simulation was too slow for sides greater than 10):

12345678910
7401172544737931129178623903075

FIGURE 4

Although it looks parabolic, it's probably cubic and, if this is the case, then an equation of \(y=0.27 \, x^3 \) seems the best fit. In any case, this post is not meant to be definitive. It's just meant to clarify my thinking. I'll need to pursue this further and improve on the accuracy of these possible equations.

Saturday, 15 December 2018

Primitive Abundant Numbers

Preliminary note: I've written about odd primitive abundant numbers in an earlier, eponymous post from May 21st 2017, so some content from that post is repeated here but there is new content as well. Here is the link.

**************************

The sum of the proper divisors of an abundant number is greater than the number itself. The integer 12 is the first abundant number. Its proper divisors are 1, 2, 3, 4 and 6 for a total of 16. So what is a primitive abundant number?

To quote from Numbers Aplenty:
An abundant number is called primitive if none of its proper divisors is abundant. 
There are infinitely many such numbers, both even and odd. However Dickson proved that there are only a finite number of odd primitive abundant numbers with a given number of distinct prime factors. 
For example, there are only 8 odd primitive abundant numbers with 3 distinct prime factors, namely, 945, 1575, 2205, 7425, 78975, 131625, 342225, and 570375. 
The first primitive abundant numbers are 12, 18, 20, 30, 42, 56, 66, 70, 78, 88, 102, 104, 114, 138, 174, 186, 196 more terms. 
A second definition of primitive numbers excludes also those that have perfect proper divisors, like all multiples of 6. The first such numbers are 20, 70, 88, 104, 272, 304, 368, 464, 550, 572, 650, 748, 836, 945, 1184, 1312, 1376, 1430, 1504, 1575, 1696, 1870, 1888, 1952, 2002.
Here are some properties of primitive abundant numbers taken from Wikipedia:
Every multiple of a primitive abundant number is an abundant number. 
Every abundant number is a multiple of a primitive abundant number or a multiple of a perfect number. 
Every primitive abundant number is either a primitive semiperfect (also called primitive pseudoperfect) number or a weird number. 
There are an infinite number of primitive abundant numbers. 
The number of primitive abundant numbers less than or equal to \(n\) is \( o \left( \frac{n}{\log^2(n)} \right)\ \). 

A semiperfect or pseudoperfect number is a natural number that is equal to the sum of all or some of its proper divisors. A primitive semiperfect number (also called a primitive pseudoperfect number, irreducible semiperfect number or irreducible pseudoperfect number) is a semiperfect number that has no semiperfect proper divisor. The first few primitive semiperfect numbers are 6, 20, 28, 88, 104, 272, 304, 350, ... There are infinitely many odd primitive semiperfect numbers, the smallest being 945.

A weird number is a natural number that is abundant but not semiperfect or pseudoperfect. In other words, the sum of the proper divisors (divisors including 1 but not itself) of the number is greater than the number, but no subset of those divisors sums to the number itself. The first few weird numbers are 70, 836, 4030, 5830, 7192, 7912, 9272, 10430, 10570, 10792, 10990, 11410, 11690, 12110, 12530, 12670, 13370, 13510, 13790, 13930, 14770, ...

See my blog post titled Zumkellar, Half-Zumkellar, and Pseudoperfect Numbers and Odd Primitive Abundant Numbers.

Tuesday, 4 December 2018

Admirable Numbers and Compatible Numbers

Yesterday I turned 25446 days and this number was identified by Numbers Aplenty as an admirable number, defined as a number \(n\) for which there exists a divisor \(d\) of \(n\) such that \(2n = \sigma(n)-2d\). In other words, \(n\) is equal to the sum of its proper divisors, where one of them has a minus sign.

For 25446, the divisors are: 1, 2, 3, 6, 4241, 8482, 12723, 25446 and the sum of these divisors is 50904. However, 50904 - 2 x 6 = 50892 = 2 x 25446 and here the divisor 6 has been assigned the minus sign. The modified divisors (1, 2, 3, -6, 4241, 8482, 12723) now add to 25446. The previously mentioned website goes on to say that:
Clearly, admirable numbers are a subset of abundant numbers and they are infinite because, for example, all the numbers 6\(p\), with \(p\)>3 prime, are admirable. The largest number that cannot be written as a sum of admirable numbers is 1003. Pairs of consecutive admirable numbers are rarer than pairs of consecutive abundant numbers. Up to \(10^{12}\), there are only two such pairs, namely 29691198404, 29691198405 and 478012798575, 478012798576.
On the other hand, pairs of admirable numbers that differ by two are more common but still sparse. There are 72 such pairs up to 27000.
 

The smallest 3 x 3 magic square made up of admirable numbers is shown in Figure 1.

Figure 1: smallest possible magic square
made from admirable numbers

OEIS A111592 lists the initial admirable numbers:
12, 20, 24, 30, 40, 42, 54, 56, 66, 70, 78, 84, 88, 102, 104, 114, 120, 138, 140, 174, 186, 222, 224, 234, 246, 258, 270, 282, 308, 318, 354, 364, 366, 368, 402, 426, 438, 464, 474, 476, 498, 532, 534, 582, 606, 618, 642, 644, 650, 654, 672, 678, 762, 786, 812, ...
These numbers are related to Zumkellar, Half-Zumkellar and pseudoperfect numbers in that they all involve the divisors of the number. See my blog post on these sorts of numbers.

In the OEIS comments, we read that "the concept of admirable numbers was developed by educator Jerome Michael Sachs (1914-2012) for a television in-service training course in mathematics for elementary school teachers." Here is the link to the article that he wrote in The Arithmetic Teacher, Vol. 7, No. 6 (1960), pp. 293-295. However, in that article he allows more than one of the divisors of a number to be negative. For example, he writes 24 as being equal to the following algebraic sum of its divisors: 4+6+8+12-1-2-3. However, this is the same as 1+2+3+4+8+12-6 so it's not clear whether a sum involving multiple negative divisors is always equivalent to another sum involving a single negative divisor.

Sachs also introduces the notion of a compatible number pair as an extension or relaxation of the concept of an amicable number pair. For example, 220 and 284 are an amicable pair because the proper divisors of each add to the other number. The proper divisors of 220 are 1, 2, 4, 5, 10, 11, 20, 22, 44, 55 and 110 and these add to 284. The proper divisors of 284 are 1, 2, 4, 71 and 142 and these add to 220. In such cases, the smaller number is abundant and the larger number deficient.

Sach's proposal for a compatible number pair is two numbers such that the algebraic sums of their divisors each leads to the other number. For example:
  • 30 has divisors of 1, 2, 3, 5, 6, 10, 15
  • 40 has divisors of 1, 2, 4, 5, 8, 10 and 20
  • 40 = 2 + 3 + 5 + 6 + 10 + 15 - 1
  • 30 = 1 + 2 + 4 + 5 + 8 + 20 - 10
So he defines 30 and 40 as compatible numbers.

The smaller members of such pairs are listed in OEIS A109797 while the larger members are listed in OEIS A109798.

Here is the SageMath code to generate the admirable numbers between 25000 and 26000

Friday, 30 November 2018

The Apocryphal Diderot-Euler Encounter

There is an interesting story about an encounter between Diderot and Euler in the palace of Catherine the Great in St.Peterburg. I've come across two versions of the story, one in Bell's "Men of Mathematics" and the other in Hogben's "Mathematics for the Million". Both are essentially the same and there are many other slightly differing versions about. Here is the account by Hogben:

Figure 1
This is nonsense because Diderot was an accomplished mathematician in his own right. He apparently didn't know how to respond and, embarrassed, made a quick exit. The next day he asked the Empress for safe passage back to Paris. Even though the story is apocryphal, the mathematical equation interested me (from a mathematical perspective not a theological one), so I thought I'd investigate it a little. Firstly though I imposed some restriction on a, b and n: they must be integers and all greater than zero. $$  \frac{a+b^n}{n}=x \text{   with }a, b, c >0 \text { and } a, b, c \, \in \, \, Z $$Let's consider the case where \(x=100\) and \( n=1\). We have simply:$$ a+b=100 \text{ and }b=100-a$$Thus \(a=1\) and \(b=99 \), \(a=2 \) and \(b=98 \), ..., \(a=99\) and \(b=1\) are the possible solutions.

Let's next consider the case where \(x=100\) but \(n=2\). In this case we get:$$ \frac{a+b^2}{2}=100 \text{ and }b=\sqrt{200-a}$$For this result, the values of a must be chosen so that \(\sqrt{200-a} \) is a square number. The square numbers between 0 and 200 are 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196 and correspond to \(b\) values of 1, 2, ..., 13, 14 with associated \(a\) values of 199, 196, ..., 31, 4.

In the case where \(x=100\) and \(n=3\) we get: $$ \frac{a+b^3}{3}=100 \text{ and }b=\sqrt[3]{300-a}$$Here, the values of a must be chosen so that we can find an integral cube root of the number under the cube root sign. The cubes that lie between 0 and 300 are 1, 8, 27, 64, 125 and 216 and so \(a\) values of 299, 292, 273, 236, 175 and 84 correspond to \(b\) values of 1, 2, 3, 4, 5 and 6.

As n increases, the possible values of \(a \) decrease:
  • fourth power (\(n=4\)) numbers less than 400 are 1, 16, 81 and 256
  • fifth power numbers (\(n=5\)) less than 500 are 1, 32 and 243
  • sixth power numbers (\(n=6\)) less than 600 are 1 and 64
  • seventh power numbers (\(n=7\)) less than 700 are 1 and 128
  • eighth power numbers (\(n=8\)) less than 800 are 1 and 256
  • ninth power numbers (\(n=9\)) less than 900 are 1 and 512
  • tenth power numbers (\(n=10\)) less than 1000 are 1 only
As can be seen, the multiples of 100 are soon overtaken. So just to check, let's take the case where n=9 and we want \(900-a=512\) and so \(a=388\) and \(b=2\). This means 100 can be written as:$$100=\frac{388+2^9}{9}$$From this analysis, it's clear that for any given integer \(x\) there are numerous ways to represent it in the form examined but their number is definitely finite. 

Wednesday, 28 November 2018

Hogben Numbers

Today I turned 25441 days and one of the properties of this number is that it's a Hogben number, the 160th such number in fact. I discovered this fact thanks to Numbers Aplenty in that site's description of the properties of this number. A link provided there contains the following information about these sorts of numbers:

The \(n\)-th Hogben number \(H_n\) is equal to \(n^2-n+1\).

Figure 1: SPIRAL ARRANGEMENT OF INTEGERS

In a spiral arrangement of the integers, Hogben numbers appear on the main diagonal (see Figure 1). Hogben numbers are often called central polygonal numbers. \(H_n\) is also the maximal number of ones that a \(n \times n\) {0,1} matrix can contain and still be invertible (that is an inverse matrix exists). The first Hogben numbers are 1, 3, 7, 13, 21, 31, 43, 57, 73, 91, 111, 133, 157, 183, 211, 241, 273, 307, 343, 381, ...

The Hogben numbers are listed in OEIS A002061 as the central polygonal numbers: \(a(n) = n^2 - n + 1\) with some interesting comments about where these Hogben numbers crop up. Let's consider some examples:

EXAMPLE 1
For n>1: a(n) is the maximum total number of queens that can coexist without attacking each other on an [n+1] x [n+1] chessboard. Specifically, this will be a lone queen of one colour placed in any position on the perimeter of the board, facing an opponent's "army" of size a(n)-1. 
The normal chess board consists of 8 x 8 = 64 squares, so the value of \(n^2-n+1\) when \(n=7\), namely 43, will give the maximum possible number of such queens. Figure 2 confirms this to be the case:

Figure 2: one against 42

EXAMPLE 2
Since \( (n+1)^2 - (n+1) + 1 = n^2 + n + 1 \) then from 7 onwards these are also exactly the numbers that are represented as 111 in all number bases: \(111_2=7 \), \(111_3=13 \), ... 
This is quite an interesting property and so we have the result that:

111 in base 2 is 7
111 in base 3 is 13
111 in base 4 is 21
111 in base 5 is 31
111 in base 6 is 43
111 in base 7 is 57
111 in base 8 is 73
111 in base 9 is 91
111 in base 10 is 111
111 in base 11 is 133
111 in base 12 is 157
111 in base 13 is 183
111 in base 14 is 211
111 in base 15 is 241
111 in base 16 is 273

The next example is taken from this source:

EXAMPLE 3

Figure 3: Hogben numbers within an isosceles triangle of numbers

This is a nice visual result and reveals an easy way to generate these numbers in a manner similar to Pascal's triangle.

So what about Lancelot Thomas Hogben after whom these numbers were named. He turns out to have been quite an interesting character. To quote from his Wikipedia entry:
Lancelot Thomas Hogben (9 December 1895 – 22 August 1975) was a British experimental zoologist and medical statistician. He developed the African clawed frog (Xenopus laevis) as a model organism for biological research in his early career, attacked the eugenics movement in the middle of his career, and popularised books on science, mathematics and language in his later career.
It is in his very popular 1936 book about Mathematics titled "Mathematics for the Million" that he presumably deals with numbers of the form \(n^2-n+1\). I have a copy of this book in electronic format in my library of ebooks but I couldn't find anything that sheds further light on these particular numbers. Here is a quote from the introduction to his book:


Figure 4: Lancelot Thomas Hogben 
Hogben was a conscientious objector in World War 1 and was imprisoned for a time. He was fiercely opposed to the Eugenics movement that was very active in the 1920s and 1930s. In World War 2, he was responsible for the British Army's medical statistics. He is quoted as saying:
"I like Scandinavians, skiing, swimming and socialists who realise it is our business to promote social progress by peaceful methods. I dislike football, economists, eugenicists, Fascists, Stalinists, and Scottish conservatives. I think that sex is necessary and bankers are not".
In addition to his extensive writing, he edited The "Loom of Language" by his friend Frederick Bodmer. This was a book that I borrowed from the library in Pontefract, Yorkshire, when I lived there in 1983-4, and which I read and very much enjoyed.

Monday, 26 November 2018

Augustus De Morgan

Augustus De Morgan was a British mathematician and logician. He formulated De Morgan's laws and introduced the term mathematical induction, making its idea rigorous. He famously stated that he was \(x\) years old in the year \(x^2\), leaving us to surmise when he was born. A definite answer is possible once we know that he was born in the 19th century. This is a laughably simple problem and I am not suggesting that it has any mathematical significance but it popped up as an exercise in a book that I just started reading titled "Elementary Number Theory with Applications" by Thomas Koshy. It inclined me to find out a little more about this mathematician but first let's deal with the problem, simple as it might be.

One approach is to find a number between 1801 and 1900 that is a square number. There is only one such number and that is \(1849=43^2\). Thus we can say that he was born in 1806 and indeed he was born on the 27th of June 1806 and died on the 18th March 1871). This leads us to ask what in the next birth year that would allow its natives to make a similar claim. Well, those who were 44 years old in 1936 could make such a claim since \(1936=44^2\) and all would have been born in the 1892. Similarly, anyone born in 1980 will turn 45 in the year \(2025=45^2\).

The same approach could be taken with the cube of the year. If one were 12 years old in 1728, the claim could be made that one was \(x\) years old in the year \(x^3\). One would have be 13 years old in 2197 to make the same claim. The years that are perfect cubes will obviously be much farther apart than the perfect squares.


What about De Morgan himself? The Wikipedia article seems to give the most comprehensive account of his life. I was reminded that I had a copy of E. T. Bell's "Men of Mathematics" but De Morgan doesn't get a mention in that. He was a confirmed athiest:
His mother was an active and ardent member of the Church of England, and desired that her son should become a clergyman, but by this time De Morgan had begun to show his non-conforming disposition. 
As he himself said in 1838:
There is a word in our language with which I shall not confuse this subject, both on account of the dishonourable use which is frequently made of it, as an imputation thrown by one sect upon another, and of the variety of significations attached to it. I shall use the word Anti-Deism to signify the opinion that there does not exist a Creator who made and sustains the Universe. 
Even though he obtained a Bachelor of Arts degree at Cambridge, he could not progress to a Master's degree because that involved a theological test to which De Morgan would not subject himself to (even though he had been brought up in the Church of England).
As no career was open to him at his own university, he decided to go to the Bar, and took up residence in London; but he much preferred teaching mathematics to reading law. About this time the movement for founding London University (now University College London) took shape. The two ancient universities of Oxford and Cambridge were so guarded by theological tests that no Jew or Dissenter outside the Church of England could enter as a student, still less be appointed to any office. A body of liberal-minded men resolved to meet the difficulty by establishing in London a University on the principle of religious neutrality. De Morgan, then 22 years of age, was appointed professor of mathematics.
The theological test for Oxford and Cambridge was abolished in 1875. De Morgan was an outstanding teacher of Mathematics as well as a brilliant and witty writer. He was a lifelong friend of the Irish mathematician William Rowan Hamilton who discovered the Quaternions.

Of his childhood:
Augustus De Morgan was born in Madurai, India in 1806.[a] His father was Lieut.-Colonel John De Morgan (1772–1816), who held various appointments in the service of the East India Company. His mother, Elizabeth Dodson (1776–1856), was a descendant of James Dodson, who computed a table of anti-logarithms, that is, the numbers corresponding to exact logarithms. Augustus De Morgan became blind in one eye a month or two after he was born. The family moved to England when Augustus was seven months old. As his father and grandfather had both been born in India, De Morgan used to say that he was neither English, nor Scottish, nor Irish, but a Briton "unattached", using the technical term applied to an undergraduate of Oxford or Cambridge who is not a member of any one of the Colleges.
In Autumn of 1837, he married Sophia Elizabeth Frend (1809–1892). Of his family:
De Morgan had three sons and four daughters, including fairytale author Mary de Morgan. His eldest son was the potter William De Morgan. His second son George acquired distinction in mathematics at University College and the University of London. He and another like-minded alumnus conceived the idea of founding a mathematical society in London, where mathematical papers would be not only received (as by the Royal Society) but actually read and discussed. The first meeting was held in University College; De Morgan was the first president, his son the first secretary. It was the beginning of the London Mathematical Society. 
Unfortunately, his son George (the previously mentioned first secretary of the London Mathematical Society) died and not long after a daughter. After this, his health deteriorated and he died of "nervous prostration" at age 64.

De Morgan also promoted the work of the self-taught Indian mathematician Ramchundra. Here is an excerpt from the Wikipedia article about Ramchundra:
Ramchundra (1821–1880) was a British Indian mathematician. His book, Treatise on Problems of Maxima and Minima, was promoted by the prominent mathematician Augustus De Morgan. In his introduction to Ramchundra's book, De Morgan says that he was born in 1821 in Panipat to Sunder Lal, a Kayasth of Delhi. De Morgan came to know of Ramchundra when, in 1850, he was sent by a friend to work on maxima and minima by the 29-year-old self-taught mathematician. Ramchundra had published his book at his own expense in Calcutta in that year. De Morgan arranged for the book to be republished in London under his own supervision. De Morgan was so impressed that he undertook to bring Ramchundra's work to the notice of scientific men of Europe. Charles Muses, in an article in the Mathematical Intelligencer (1998) called Ramchundra "De Morgan's Ramanujan". He was mystified why, in spite of De Morgan's efforts to make this "remarkable Hindu algebraist known, he does not appear in most texts on history of mathematics." Ramchundra was teacher of science in Delhi College for some time. In 1858, he was native head master in Thomason Civil Engineering College (now Indian Institute of Technology, Roorkee) at Roorkee. Later that year, he was appointed head master of a school in Delhi.