login
A359122
Index of prime(n) in A068811, or -1 if prime(n) is missing from A068811.
3
-1, 1, 2, 3, 4, -1, 5, -1, -1, 6, -1, -1, 7, -1, 8, 9, 10, -1, -1, 11, -1, -1, 12, 13, 14, -1, -1, -1, -1, 15, -1, -1, 16, -1, -1, -1, -1, -1, -1, 17, 18, -1, 19, -1, -1, -1, -1, -1, 20, -1, -1, 21, -1, -1, 22, -1, -1, -1, -1, 23, -1, -1, -1, -1, -1, 24, -1, -1, 25, -1, 26, 27, -1
OFFSET
1,3
LINKS
Michael De Vlieger, Raster showing a(n) > 0 in black else white, n = 1..10^6, in rows of 1000 pixels.
EXAMPLE
Prime(4) = 7 is the third term in A068811, so a(4) = 3.
Prime(6) = 13 is missing from A068811, so a(6) = -1.
MATHEMATICA
c = 1; Reap[Do[Sow@ If[PrimeQ[10^(1 + Floor@ Log10[#]) - #], c++, -1] &[Prime[n]], {n, 73}]][[-1, -1]] (* or, generate nn <= 10^6 terms of this sequence from the bitmap: *)
Block[{nn = 10^4, s = Flatten@ ImageData[Import["https://oeis.org/A359122/a359122.png"]] /. {1. -> 0, 0. -> 1}, c}, c = 1; Map[If[# == 0, -1, c++] &, s[[1 ;; nn]]]] (* Michael De Vlieger, Dec 18 2022 *)
CROSSREFS
Sequence in context: A117742 A117716 A211234 * A240185 A292032 A097150
KEYWORD
sign
AUTHOR
N. J. A. Sloane, Dec 18 2022
STATUS
approved