I am an engineering student and when I was doing some work on data visualisation I stumbled across an integer sequence after watching a video about sequences that produce interesting graphs. I submitted the sequence to the On-Line Encyclopedia of Integer Sequences A328225.
The sequence is as follows: a(1) = 1, a(n) = a(n-1) - prime(prime(n)) - prime(n-1) if this produces a positive integer not yet in the sequence, otherwise a(n) = a(n-1) + prime(prime(n)) - prime(n-1).
This sequence produces the following graph (up to n = 1000, n = 10000 and n = 6e6 respectively)
Graph of sequence up to n = 1e3
Graph of sequence up to n = 1e4
Graph of sequence up to n = 6e6
I'm would love to get a understanding of the underlying principles that give rise to the curves observed in the graphs. Additionally, I'm intrigued by the apparent upper limit observed along the y-axis.
I would greatly appreciate any insights, explanations, or conjectures regarding the origins of these curves and the factors contributing to the observed limits. Furthermore, any suggestions on how to further explore or analyse this sequence would be immensely valuable.
Here is a text file up to n = 1e6 if anyone wants to have a play around with the sequence. If anyone would like any additional information/resources from me, feel free to ask.