The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A356374 a(n) is the first prime that starts a string of exactly n consecutive primes that are in A347702. 0
131, 41, 11, 178909, 304290583, 8345111009 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
a(n) is the first prime that starts a string of exactly n consecutive primes that are quasi-Niven numbers, i.e., have remainder 1 when divided by the sum of their digits.
a(7) > 3*10^11, if it exists. - Amiram Eldar, Aug 04 2022
LINKS
EXAMPLE
a(3) = 11 because [11, 13, 17] is the first string of exactly 3 consecutive primes that are quasi-Niven numbers: 11 mod (1+1) = 1, 13 mod (1+3) = 1 and 17 mod (1+7) = 1, while the preceding prime 7 and the next prime 23 are not quasi-Niven.
MAPLE
filter:= proc(n) n mod convert(convert(n, base, 10), `+`) = 1 end proc:
V:= Vector(5): count:= 0:
s:= 0: p:= 1:
while count < 5 do
p:= nextprime(p);
if filter(p) then
s:= s+1;
if s = 1 then p0:= p fi
elif s > 0 then
if s <= 5 and V[s] = 0 then V[s]:= p0; count:= count+1 fi;
s:= 0;
fi
od:
convert(V, list);
MATHEMATICA
seq[len_, pmax_] := Module[{s = Table[0, {len}], v = {}, p = 2, c = 0, pfirst = 2, i}, While[c < len && p < pmax, If[Divisible[p - 1, Plus @@ IntegerDigits[p]], AppendTo[v, p]; If[pfirst == 0, pfirst = p], i = Length[v]; v = {}; If[0 < i <= len && s[[i]] == 0, s[[i]] = pfirst]; pfirst = 0]; p = NextPrime[p]]; s]; seq[4, 10^6] (* Amiram Eldar, Aug 04 2022 *)
CROSSREFS
Sequence in context: A246242 A001331 A291620 * A145096 A210498 A050671
KEYWORD
nonn,base,more
AUTHOR
J. M. Bergot and Robert Israel, Aug 04 2022
EXTENSIONS
a(5)-a(6) from Amiram Eldar, Aug 04 2022
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 May 14 14:46 EDT 2024. Contains 372533 sequences. (Running on oeis4.)