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.

A301378 a(n) = 10*A007605(n) - 9*A007652(n).

Original entry on oeis.org

2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97, 11, 13, 17, 19, 23, 37, 41, 47, 49, 59, 61, 67, 73, 77, 83, 89, 91, 101, 103, 107, 109, 31, 43, 47, 49, 53, 59, 61, 71, 77, 83, 89, 91, 97, 101, 103, 113, 37, 41, 43, 47, 61
Offset: 1

Views

Author

Edmund Algeo, Mar 19 2018

Keywords

Comments

Equivalently, a(n) is the sum of all but the last digit of the n-th prime, concatenated with that last digit.
It appears that as the prime number xyzd transformed by (x+y+z)*10 +d; the larger the prime the less frequent the result is prime....

Examples

			For p=1571 (prime), 1+5+7 = 13; 13*10 = 130; 130+1 = 131 (prime).
		

Crossrefs

Programs

  • Maple
    map(t -> 10*convert(convert(t,base,10),`+`)-9*(t mod 10), [seq(ithprime(i),i=1..100)]); # Robert Israel, Mar 25 2018
  • Mathematica
    Array[10 Total@ # - 9 Last@ # &@ IntegerDigits[Prime@ #] &, 67] (* Michael De Vlieger, Apr 27 2018 *)
  • PARI
    a(n) = my(p=prime(n); d=p % 10); sumdigits(p-d)*10+d; \\ Michel Marcus, Mar 23 2018

Formula

Let ...xyzd represent the decimal expansion of prime(n); then a(n) = (... + x + y + z)*10 + d.
a(n) = 10*A007605(n) - 9*A007652(n). - Robert Israel, Mar 25 2018