cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A109204 Minimal value of k>0 such that n^9 + k^2 is a semiprime.

Original entry on oeis.org

2, 3, 5, 10, 5, 2, 11, 4, 7, 2, 9, 4, 7, 5, 3, 2, 7, 16, 7, 2, 39, 2, 25, 12, 5, 7, 21, 2, 5, 3, 7, 16, 9, 17, 5, 24, 19, 4, 3, 20, 7, 6, 11, 4, 3, 4, 17, 12, 17, 2, 7, 70, 3, 3, 5, 2, 11, 16, 5, 42, 7, 4, 3, 26, 3, 9, 25, 26, 9, 5, 33, 6, 23, 12, 23, 2, 9, 6, 7, 2, 23, 4, 3, 16, 11, 16, 9, 2, 3
Offset: 0

Views

Author

Jonathan Vos Post, Jul 04 2005

Keywords

Examples

			a(0) = 2 because 0^9 + 1^2 = 1 is not semiprime, but 0^9 + 2^2 = 4 = 2^2 is.
a(1) = 3 because 1^9 + 1^2 and 1^9 + 2^2 are not semiprime, but 1^9 + 3^2 = 10 = 2 * 5 is semiprime.
a(2) = 5 because 2^9 + 5^2 = 537 = 3 * 179 is semiprime, but 2^9 plus no smaller square is.
a(51) = 70 because 51^9 + 70^2 = 2334165173095351 = 43063 * 54203496577 and for no smaller k>0 is 51^9 + k^2 a semiprime.
a(100) = 7 because 100^9 + 7^2 = 1000000000000000049 = 157 * 6369426751592357 and for no smaller k>0 is 100^9 + k^2 a semiprime.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := (For[k = 1, PrimeOmega[n^9 + k^2] != 2, k++]; k); a /@ Range[0, 88] (* Giovanni Resta, Jun 17 2016 *)
  • PARI
    a(n) = my(k=1); while(bigomega(n^9+k^2)!=2, k++); k \\ Felix Fröhlich, Jun 17 2016

Extensions

a(15) corrected by Giovanni Resta, Jun 17 2016