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.

A022457 a(n) = prime(2n) mod prime(n).

Original entry on oeis.org

1, 1, 3, 5, 7, 11, 9, 15, 15, 13, 17, 15, 19, 21, 19, 25, 21, 29, 29, 31, 35, 35, 33, 45, 35, 37, 45, 49, 53, 55, 39, 49, 43, 59, 51, 57, 59, 57, 63, 63, 63, 71, 61, 71, 69, 81, 69, 57, 67, 83, 91, 91, 95, 91, 87, 87, 81, 99, 93, 97, 107, 97, 87, 97, 107, 109, 95
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Magma
    [NthPrime(2*n) mod NthPrime(n): n in [1..50]]; // G. C. Greubel, Feb 28 2018
  • Maple
    A022457 := proc(n)
        modp(ithprime(2*n),ithprime(n)) ;
    end proc:
    seq(A022457(n),n=1..67) ; # R. J. Mathar, Sep 02 2016
  • Mathematica
    Table[Mod[Prime[2*n], Prime[n]], {n, 1, 50}] (* G. C. Greubel, Feb 28 2018 *)
  • PARI
    a(n) = prime(2*n) % prime(n); \\ Michel Marcus, Sep 30 2013
    

Formula

a(n) = A031215(n) modulo A000040(n). - Michel Marcus, Sep 30 2013