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.

A289435 The arithmetic function v_3(n,3).

Original entry on oeis.org

1, 0, 2, 2, 3, 2, 4, 2, 5, 4, 6, 4, 7, 6, 8, 6, 9, 6, 10, 6, 11, 8, 12, 10, 13, 8, 14, 10, 15, 10, 16, 12, 17, 14, 18, 12, 19, 12, 20, 14, 21, 14, 22, 18, 23, 16, 24, 16, 25, 18, 26, 18, 27, 22, 28, 18, 29, 20, 30, 20, 31, 20, 32, 26, 33, 22, 34, 24, 35
Offset: 2

Views

Author

N. J. A. Sloane, Jul 06 2017

Keywords

References

  • J. Butterworth, Examining the arithmetic function v_g(n,h). Research Papers in Mathematics, B. Bajnok, ed., Gettysburg College, Vol. 8 (2008).

Crossrefs

Cf. A211316 (equals v_1(n,3)).

Programs

  • Maple
    a:= n-> n*max(seq((floor((d-1-igcd(d, 3))/3)+1)
            /d, d=numtheory[divisors](n))):
    seq(a(n), n=2..100);  # Alois P. Heinz, Jul 07 2017
  • Mathematica
    a[n_]:=n*Max[Table[(Floor[(d - 1 - GCD[d, 3])/3] + 1)/d, {d, Divisors[n]}]]; Table[a[n], {n, 2, 100}] (* Indranil Ghosh, Jul 08 2017 *)
  • PARI
    v(g,n,h)={my(t=0);fordiv(n,d,t=max(t,((d-1-gcd(d,g))\h + 1)*(n/d)));t}
    a(n)=v(3,n,3); \\ Andrew Howroyd, Jul 07 2017
    
  • Python
    from sympy import divisors, floor, gcd
    def a(n): return n*max((floor((d - 1 - gcd(d, 3))/3) + 1)/d for d in divisors(n))
    print([a(n) for n in range(2, 101)]) # Indranil Ghosh, Jul 08 2017

Extensions

a(41)-a(70) from Andrew Howroyd, Jul 07 2017