[seqfan] Subtract if prime, else add

Éric Angelini eric.angelini at skynet.be
Mon Aug 5 22:56:21 CEST 2019


Hello SeqFans,
Here is an idea for a seq S:
"If a(n) is prime, subtract the nth digit of S, 
else add it".

Starting S with a(1)=4 gives:

S = 4,8,16,17,11,10,17,16,17,16,16,17,10,11,5,
4,11,10,16,17,11,10,17,16,16,17,16,21,25,
26,27,28,28,29,23,22,...

Does S enter into a loop? Or slowly grow
forever? Are there integers that will
never appear in S (like 3 so far, for instance)?
What about a different start if a(1)=4 enters 
into a loop? Ultimately: do loops exist?
(S seems not to be in the OEIS, if I am not
wrong).
Best,
É.






More information about the SeqFan mailing list