# [seqfan] More about Grant Olson's sequence.A347113

Neil Sloane njasloane at gmail.com
Wed Nov 17 02:36:16 CET 2021

```Dear SeqFans, Now that - thanks to Robert Gerbicz - we know that A347113 is
a permutation

we can move on to analyzing its graph. The most interesting features are
the huge spikes that appear.

These can be explained as follows.

By the way, this sequence has similar properties to those of the
Yellowstone Permutation (A098550),

although in the end I think A347113 is simpler, in the sense that we can
more-or-less explain where the "geysers" appear and how high they go.

Michael De Vlieger has spent a lot of time studying this graph, and this
report is partly based on our conversations. I have also made use of a
table of the first 2^19 terms that Mike kindly provided.

There are three kinds of terms in the sequence.

1. Most of the terms lie on or close to the main diagonal, the line y=x, of
slope 1. That is, most of the terms satisfy a(n) approx= n.

The only terms not on the main diagonal are the primes and twice primes.

2. The primes all lie below the main diagonal, and appear to lie on or near
the lines y = k*x, where k is one of 1/3, 1/2, 2/3, 4/5, ....

(There are three exceptional primes, however, that lie very close to the
diagonaL

n    a(n)   a(n)/n

1423, 1327, 0.9325368939,

10686, 9967, 0.9327157028,

83051, 77647, 0.9349315481)

3. Numbers of the form 2*p, p prime, are all above the main diagonal, and
lie on the lines y=k*x,

where k = 2, 4, 8, 16, ... These are the spikes on the graph, analogous to
the geysers in the Yellowstone Permutation. The heights of the spikes are
controlled by Cunningham Chains, as follows.

Call a Cunningham Chain (or CC) a maximal string of primes p, 2p+1, 4p+3,
8p+7, 16p+15, ....

It is known that all CC's have finite length.

We allow length 1, so every prime belongs to a CC of some length.

The chains are the rows of the triangle in A075712, their lengths are in
A338945, and the initial terms of the chains are given by A059456.

The first few chains are:

{2, 5, 11, 23, 47},

{3, 7},

{13},

{17},

{19},

{29, 59},

{31},

{37},

{41, 83, 167},

{43},

{53, 107},

{61},

{67},

{71},

{73},

{79},

{89, 179, 359, 719, 1439, 2879},

{97}, ...

The key result is this: If p is the i-th member of its Cunningham Chain,
then 2*p lies on or near the line of slope 2^i.

For example, consider the CC {89, 179, 359, 719, 1439, 2879} of length 6.
The corresponding terms 2p are

2*89, 2*179, ..., 2*2879, which are terms

a(89), a(90), ..., a(94) in the sequence,

and the slopes are

2*89/89, 2*179/90, ..., 2*2879/94,

which are essentially

2, 4, 8, ..., 64

This explains the huge spike that can be seen in the first plot you see
when you click

the "graph" button in A347113.

I believe all this is easy to prove.

One loose end: for the primes themselves, which lie on lines with
fractional slope below the main diagonal, can one say which primes lie on
which slopes?

The first few primes (in order of appearance) and their slopes are:

[5, 0.7142857143], [2, 0.2500000000], [3, 0.2727272727], [13,
0.6842105263], [7, 0.3500000000], [11, 0.3928571429], [17, 0.4594594595],
[29, 0.6170212766], [19, 0.3725490196], [23, 0.4339622642], [41,
0.7068965517], [43, 0.6825396825], [53, 0.6543209877], [47, 0.4747474747],
[31, 0.3069306931], [73, 0.6347826087], [37, 0.3189655172], [59,
0.4338235294], [61, 0.4178082192], [101, 0.6688741722], [71, 0.4640522876],
[67, 0.4213836478], [109, 0.6449704142], [83, 0.4715909091], [139,
0.7393617021], [89, 0.4517766497], [79, 0.3708920188], [103, 0.4790697674],
[107, 0.4798206278], [113, 0.4913043478], [149, 0.6394849785], [137,
0.5372549020], [131, 0.4781021898], [127, 0.4601449275], [181,
0.6418439716], [97, 0.3211920530], [151, 0.4748427673], [163,
0.4780058651], [167, 0.4812680115], ...

There must be a pattern here, but it is hard to decipher.

```