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).

This page as a plain text file.
%I A289435 #24 Apr 24 2020 09:44:57
%S A289435 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,
%T A289435 16,12,17,14,18,12,19,12,20,14,21,14,22,18,23,16,24,16,25,18,26,18,27,
%U A289435 22,28,18,29,20,30,20,31,20,32,26,33,22,34,24,35
%N A289435 The arithmetic function v_3(n,3).
%D A289435 J. Butterworth, Examining the arithmetic function v_g(n,h). Research Papers in Mathematics, B. Bajnok, ed., Gettysburg College, Vol. 8 (2008).
%H A289435 Bela Bajnok, <a href="https://arxiv.org/abs/1705.07444">Additive Combinatorics: A Menu of Research Problems</a>, arXiv:1705.07444 [math.NT], May 2017. See Table in Section 1.6.1.
%p A289435 a:= n-> n*max(seq((floor((d-1-igcd(d, 3))/3)+1)
%p A289435         /d, d=numtheory[divisors](n))):
%p A289435 seq(a(n), n=2..100);  # _Alois P. Heinz_, Jul 07 2017
%t A289435 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 *)
%o A289435 (PARI)
%o A289435 v(g,n,h)={my(t=0);fordiv(n,d,t=max(t,((d-1-gcd(d,g))\h + 1)*(n/d)));t}
%o A289435 a(n)=v(3,n,3); \\ _Andrew Howroyd_, Jul 07 2017
%o A289435 (Python)
%o A289435 from sympy import divisors, floor, gcd
%o A289435 def a(n): return n*max((floor((d - 1 - gcd(d, 3))/3) + 1)/d for d in divisors(n))
%o A289435 print([a(n) for n in range(2, 101)]) # _Indranil Ghosh_, Jul 08 2017
%Y A289435 Cf. A211316 (equals v_1(n,3)).
%K A289435 nonn
%O A289435 2,3
%A A289435 _N. J. A. Sloane_, Jul 06 2017
%E A289435 a(41)-a(70) from _Andrew Howroyd_, Jul 07 2017