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.

A241534 Number of integer arithmetic means of 2 distinct divisors of n.

Original entry on oeis.org

0, 0, 1, 1, 1, 2, 1, 3, 3, 2, 1, 7, 1, 2, 6, 6, 1, 6, 1, 7, 6, 2, 1, 16, 3, 2, 6, 7, 1, 12, 1, 10, 6, 2, 6, 18, 1, 2, 6, 16, 1, 12, 1, 7, 15, 2, 1, 29, 3, 6, 6, 7, 1, 12, 6, 16, 6, 2, 1, 34, 1, 2, 15, 15, 6, 12, 1, 7, 6, 12, 1, 39, 1, 2, 15, 7, 6, 12, 1, 29
Offset: 1

Views

Author

Keywords

Examples

			Triangle T(n, k) starts for n > 2:
2,
3,
3,
2, 4,
4,
3, 5, 6,
2, 5, 6;
where T(n, k) = the values of k such that 2k = q + g; q, g are distinct divisors of n.
a(20) = 7 because (1,5), (2,4), (2,10), (2,20), (4,10), (4,20) and (10,20) are the 7 values of (g,q) such that (g+q)/2 is an integer. - _Colin Barker_, May 10 2014
		

Crossrefs

Cf. A027750.

Programs

  • Mathematica
    Table[Sum[Sum[(1 - Ceiling[(i + k)/2] + Floor[(i + k)/2]) (1 - Ceiling[n/k] + Floor[n/k]) (1 - Ceiling[n/i] + Floor[n/i]), {i, k - 1}], {k, n}], {n, 100}] (* Wesley Ivan Hurt, Oct 06 2020 *)
  • PARI
    a(n) = c=0; fordiv(n, g, fordiv(n, q, if(gColin Barker, May 10 2014

Formula

a(n) = Sum_{d1|n, d2|n, d1 < d2} (1 - ceiling((d1+d2)/2) + floor((d1+d2)/2)). - Wesley Ivan Hurt, Oct 06 2020

Extensions

Several incorrect terms corrected, and more terms added by Colin Barker, May 10 2014