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.

Showing 1-3 of 3 results.

A112052 a(n) = 2*A112051(n)+1.

Original entry on oeis.org

3, 7, 23, 49, 121, 169, 289, 361, 529, 841, 961, 1369, 1681, 1849, 2209, 2809, 3481, 3721, 4489, 5041, 5329, 6241, 6889, 7921, 9409, 10201, 10609, 11449, 11881, 12769, 16129, 17161, 18769, 19321, 22201, 22801, 24649, 26569, 27889, 29929
Offset: 1

Views

Author

Antti Karttunen, Aug 27 2005

Keywords

Comments

From n>=4 onward seems to be squares of primes (A001248).

Crossrefs

Column 1 of A112070 (row 1 of A112071).

Formula

A112049 a(n) = position of A112046(n) in A000040.

Original entry on oeis.org

1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 3, 3, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 3, 4, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 4, 3, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 3, 3, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 4, 5, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 3, 3, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 3, 6, 1, 1, 2, 2, 1, 1, 2, 2, 1, 1, 4, 3, 1, 1, 2, 2, 1, 1
Offset: 1

Views

Author

Antti Karttunen, Aug 27 2005

Keywords

Comments

A112051 gives the first positions of distinct new values in this sequence, that seem also to be the positions of the first occurrence of each n, and thus the positions of the records. Compare also to A084921. - Antti Karttunen, May 26 2017

Crossrefs

Cf. A286579 (ordinal transform).

Programs

  • Mathematica
    a112046[n_]:=Block[{i=1},While[JacobiSymbol[i, 2n + 1]==1, i++]; i];a049084[n_]:=If[PrimeQ[n], PrimePi[n], 0]; Table[a049084[a112046[n]], {n, 102}] (* Indranil Ghosh, May 11 2017 *)
  • PARI
    A112049(n) = for(i=1, (2*n), if((kronecker(i, (n+n+1)) < 1), return(primepi(i)))); \\ Antti Karttunen, May 26 2017
    
  • Python
    from sympy import jacobi_symbol as J, isprime, primepi
    def a049084(n):
        return primepi(n) if isprime(n) else 0
    def a112046(n):
        i=1
        while True:
            if J(i, 2*n + 1)!=1: return i
            else: i+=1
    def a(n): return a049084(a112046(n))
    print([a(n) for n in range(1, 103)]) # Indranil Ghosh, May 11 2017

Formula

a(n) = A049084(A112046(n)).

Extensions

Unnecessary fallback-clause removed from the name by Antti Karttunen, May 26 2017

A112060 Square array A(x,y) = y-th natural number k for which A112049(k)=x and 0 if no such k exists; read by antidiagonals A(1,1), A(2,1), A(1,2), A(3,1), A(2,2), ...

Original entry on oeis.org

1, 2, 3, 5, 4, 11, 6, 7, 12, 24, 9, 8, 23, 35, 60, 10, 15, 36, 59, 155, 84, 13, 16, 47, 95, 275, 239, 144, 14, 19, 48, 119, 335, 575, 779, 180, 17, 20, 71, 120, 359, 659, 1499, 2855, 264, 18, 27, 72, 179, 419, 839, 1535, 4199, 5279, 420, 21, 28, 83, 204, 504
Offset: 1

Views

Author

Antti Karttunen, Aug 27 2005

Keywords

Comments

This is a permutation of natural numbers provided that the sequence A112046 contains only prime values [which is true] and every prime occurs infinitely many times there.

Examples

			The top left corner of the array:
   1,  2,  5,  6,  9, 10, ...
   3,  4,  7,  8, 15, 16, ...
  11, 12, 23, 36, 47, ...
		

Crossrefs

A112070(x, y) = 2*A(X, Y)+1. Transpose: A112061. Column 1: A112051. Row 1: A042963, Row 2: A112062, Row 3: A112063, Row 4: A112064, Row 5: A112065, Row 6: A112066, Row 7: A112067, Row 8: A112068, Row 9: A112069.
Cf. also A227196.
Showing 1-3 of 3 results.