login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A175075 Primes q with result 2 under iterations of {r mod (max prime p < r)} starting at r = q. 5
2, 5, 7, 13, 19, 31, 43, 61, 73, 103, 109, 139, 151, 181, 193, 199, 229, 241, 271, 283, 313, 349, 421, 433, 463, 523, 571, 601, 619, 643, 661, 811, 823, 829, 859, 883, 1021, 1033, 1051, 1063, 1093, 1153, 1231, 1279, 1291, 1303, 1321, 1429, 1453, 1483, 1489 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

COMMENTS

a(1) = 2, a(n) = A006512(n-1) for 2 <= n <= 82, a(83) = 2999. Sequence is the union of A006512 and A175080. Subsequence of A175072. Primes q with some results of {2, 28, 36, 52, 58, 66, ... } under first step of iteration of {r mod (max prime p < r)} starting at r = q, i.e. number 2 and primes q such that difference q and previous prime is equal to some of the values 2, 28, 36, 52, 58, 66, ...

Not the same as A094743: contains 2999, 3299, 5147, 5981, 8999, 9587, 10037, 10427, 10559, 10937, 11579, 12889, ... that are absent from that sequence. Up to 10^9, there are 3247366 terms in this sequence that are not in A094743, though every term from that sequence appears here. Is A094743 a subsequence of this sequence? - Charles R Greathouse IV, Jan 12 2022

It suffices to stop after the iterations yield a number less than 5 and check if the result is 2. Under this procedure, 2 takes 0 iterations, 5 is the first prime to take 1 iteration, 29 is the first to take 2 iterations, 2999 is the first to take 3 iterations, and 401429925999155063 is the first to take 4 iterations. - Charles R Greathouse IV, Jan 14 2022

LINKS

Charles R Greathouse IV, Table of n, a(n) for n = 1..10000

FORMULA

A175072 \ A175076. [A-number corrected by R. J. Mathar, Sep 25 2010] - Jaroslav Krizek, Jan 30 2010

EXAMPLE

Iteration procedure for a(5) = 19: 19 mod 17 = 2. Iteration procedure for a(83) = 2999: 2999 mod 2971 = 28, 28 mod 23 = 5, 5 mod 3 = 2.

MATHEMATICA

fQ[p_] := Block[{r = p}, While[r > 2, r = Mod[r, NextPrime[r, -1]]]; r == 2]; Select[ Prime@ Range@ 253, fQ] (* Robert G. Wilson v, Aug 09 2010 *)

PROG

(PARI) is(n)=if(!isprime(n), return(0)); while(n>4, n-=precprime(n-1)); n==2 \\ Charles R Greathouse IV, Jan 12 2022

(PARI) has(n)=while(n>4, n-=precprime(n-1)); n==2

list(lim)=my(v=List([2]), p=3); forprime(q=5, lim, if(has(q-p), listput(v, q)); p=q); Vec(v) \\ Charles R Greathouse IV, Jan 12 2022

CROSSREFS

Sequence in context: A069351 A275011 A094743 * A262392 A056985 A082182

Adjacent sequences:  A175072 A175073 A175074 * A175076 A175077 A175078

KEYWORD

nonn

AUTHOR

Jaroslav Krizek, Jan 23 2010

EXTENSIONS

More terms from Robert G. Wilson v, Aug 09 2010

A175080 inserted in comment - R. J. Mathar, Sep 25 2010

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 2 23:51 EDT 2022. Contains 357230 sequences. (Running on oeis4.)