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.

A317627 a(n) = A317253 - floor(8*n/3).

Original entry on oeis.org

2, 3, 1, 1, 3, 1, 2, 1, -1, 1, 3, 1, 2, 3, 1, 1, 1, -1, 2, 1, -1, 1, 3, 1, 2, 3, 1, 1, 3, 1, 2, 1, -1, 1, 1, -1, 2, 3, 1, 1, 1, -1, 2, 1, -1, 1, 3, 1, 2, 3, 1, 1, 3, 1, 2, 1, -1, 1, 3, 1, 2, 3, 1, 1, 1, -1, 2, 1, -1, 1, 1, -1, 2, 3, 1, 1, 3, 1, 2
Offset: 1

Views

Author

A.H.M. Smeets, Aug 02 2018

Keywords

Crossrefs

Programs

  • Python
    n,f,i,p,q,base = 1,1,0,0,1,3
    while i < 100000:
        i,p,q = i+1,p*base,q*base
        if i == f:
            p,n = p+1,n+1
            f = f*n
    n,a,j = 0,0,0
    while p%q > 0:
        a,f,p,q = a+1,p//q,q,p%q
        if f == 1:
            n = n+1
            print(n,a-1-(8*n//3))

Formula

a(3*n+1) = 2 - (n mod 2) for n >= 0, a(6*n+2) = 3 - 2*(n mod 2) and a(6*n+5) = a(3*n+2) for n >= 0, a(6*n+3) = 1 - 2*(n mod 2) and a(6*n+6) = a(3*n+3) for n >= 0.
a(3*n+1) = A000034(n+1) for n >= 0.
a(3*n+2) = A089607(n) for n > 1.
a(3*n+2) = 2*A014577(n-1)+1 for n > 0.
a(3*n+3) = A034947(n) = 2*A014577(n-1)-1 for n > 0.