Tuesday 20 December 2022

The Yellowstone Permutation

Before I discovered the "Yellowstone Permutation, I first came across the Enots Wolley sequence where Enots Wolley is Yellowstone with the letters in reverse order. Thus was I lead to the Yellowstone sequence that represents a permutation of the natural numbers and, like them, is infinite. It gets its name from the spiking, geyser like appearance when plotted (see Figure 1). The primes in the sequence appear in their natural order although this is a conjecture for which there is as yet no proof. The sequence is described as follows:


 A098550

The Yellowstone permutation: \(a(n) = n\) if \(n \leq 3\), otherwise the smallest number not occurring earlier having at least one common factor with \(a(n-2)\), but none with \(a(n-1)\).



The initial terms are:

1, 2, 3, 4, 9, 8, 15, 14, 5, 6, 25, 12, 35, 16, 7, 10, 21, 20, 27, 22, 39, 11, 13, 33, 26, 45, 28, 51, 32, 17, 18, 85, 24, 55, 34, 65, 36, 91, 30, 49, 38, 63, 19, 42, 95, 44, 57, 40, 69, 50, 23, 48, 115, 52, 75, 46, 81, 56, 87, 62, 29, 31, 58, 93, 64, 99, 68, 77, 54, 119, 60 

The plot of these points is shown in Figure 1:



Figure 1

The only fixed points seem to be 1, 2, 3, 4, 12, 50 and 86. This has been tested up to 100 million terms. To quote from the OEIS comments:
The first 250000 points lie on about 8 roughly straight lines, whose slopes are approximately 0.467, 0.957, 1.15, 1.43, 2.40, 3.38, 5.25 and 6.20. The first six lines seem well-established, but the two lines with highest slope at present are rather sparse. Presumably as the number of points increases, there will be more and more lines of ever-increasing slopes.

However, subsequently in the comments, it's stated that:

The eight roughly straight lines mentioned above are actually curves. A good fit for the "line" with slope \( \approx 1.15\) is:$$a(n) \approx n(1+1.0/\log(n/24.2))$$ and a good fit for the other "lines" is:$$a(n) \approx (c/2) \cdot n(1-0.5/\log(n/3.67))$$for \(c = 1,2,3,5,7,11,13\). The first of these curves consists of most of the odd terms in the sequence. The second family consists of the primes (\(c=1\)), even terms (\(c=2\)), and \(c \cdot \text{prime } (c=3,5,7,11,13, \cdots) \). 

Figure 2 shows the graph for the first 300,000 terms:

 
Figure 2

There is Python code provided at this site but I can't get it to run.  I'll deal with the Enots Wolley sequence in a later post.

No comments:

Post a Comment