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-2 of 2 results.

A227041 Triangle of numerators of harmonic mean of n and m, 1 <= m <= n.

Original entry on oeis.org

1, 4, 2, 3, 12, 3, 8, 8, 24, 4, 5, 20, 15, 40, 5, 12, 3, 4, 24, 60, 6, 7, 28, 21, 56, 35, 84, 7, 16, 16, 48, 16, 80, 48, 112, 8, 9, 36, 9, 72, 45, 36, 63, 144, 9, 20, 10, 60, 40, 20, 15, 140, 80, 180, 10, 11, 44, 33, 88, 55, 132, 77, 176, 99, 220, 11
Offset: 1

Views

Author

Wolfdieter Lang, Jul 01 2013

Keywords

Comments

The harmonic mean H(n,m) is the reciprocal of the arithmetic mean of the reciprocals of n and m: H(n,m) = 1/((1/2)*(1/n +1/m)) = 2*n*m/(n+m). 1/H(n,m) marks the middle of the interval [1/n, 1/m] if m < n: 1/H(n,m) = 1/n + (1/2)*(1/m - 1/n). For m < n one has m < H(n,m) < n, and H(n,n) = n.
H(n,m) = H(m,n).
For the rationals H(n,m)/2 see A221918(n,m)/A221919(n,m). See the comments under A221918.

Examples

			The triangle of numerators of H(n,m), called a(n,m) begins:
n\m  1   2   3   4   5    6    7    8    9   10  11 ...
1:   1
2:   4   2
3:   3  12   3
4:   8   8  24   4
5:   5  20  15  40   5
6:  12   3   4  24  60    6
7:   7  28  21  56  35   84    7
8:  16  16  48  16  80   48  112    8
9:   9  36   9  72  45   36   63  144    9
10: 20  10  60  40  20   15  140   80  180   10
11: 11  44  33  88  55  132   77  176   99  220  11
...
a(4,3) = numerator(24/7) = 24 = 24/gcd(7,18).
The triangle of the rationals H(n,m) begins:
n\m    1      2     3     4      5      6      7      8   9
1:   1/1
2:   4/3    2/1
3:   3/2   12/5   3/1
4:   8/5    8/3  24/7   4/1
5:   5/3   20/7  15/4  40/9    5/1
6:  12/7    3/1   4/1  24/5  60/11    6/1
7:   7/4   28/9  21/5 56/11   35/6  84/13    7/1
8:  16/9   16/5 48/11  16/3  80/13   48/7 112/15    8/1
9:   9/5  36/11   9/2 72/13   45/7   36/5   63/8 144/17 9/1
...
H(4,3) = 2*4*3/(4 + 3) = 2*4*3/7 = 24/7.
		

Crossrefs

Cf. A227042, A022998 (m=1), A227043 (m=2), A227106 (m=3), A227107 (m=4), A221918/A221919.

Formula

a(n,m) = numerator(2*n*m/(n+m)), 1 <= m <= n.
a(n,m) = 2*n*m/gcd(n+m,2*n*m) = 2*n*m/gcd(n+m,2*m^2), n >= 0.

A227140 a(n) = n/gcd(n,2^5), n >= 0.

Original entry on oeis.org

0, 1, 1, 3, 1, 5, 3, 7, 1, 9, 5, 11, 3, 13, 7, 15, 1, 17, 9, 19, 5, 21, 11, 23, 3, 25, 13, 27, 7, 29, 15, 31, 1, 33, 17, 35, 9, 37, 19, 39, 5, 41, 21, 43, 11, 45, 23, 47, 3, 49, 25, 51, 13, 53, 27, 55, 7, 57, 29, 59, 15, 61, 31, 63, 2, 65, 33, 67, 17, 69, 35
Offset: 0

Views

Author

Wolfdieter Lang, Jul 04 2013

Keywords

Comments

H(n,4) = 2*n*4/(n+4) is the harmonic mean of n and 4. For n >= 4 the denominator of H(n,4) is (n+4)/gcd(8*n,n+4) = (n+4)/gcd(n+4,32). a(n+8) = A227042(n+4,4), n >= 0. The numerator of H(n,4) is given in A227107. Thus a(n) is related to denominator of the harmonic mean H(n-4, 4).
Note the difference from A000265(n) (odd part of n) = n/gcd(n,2^n), n >= 1, which differs for the first time for n = 64. a(64) = 2, not 1.
A multiplicative sequence. Also, a(n) is a strong divisibility sequence, that is, gcd(a(n),a(m)) = a(gcd(n,m)) for n >= 1, m >= 1. In particular, a(n) is a divisibility sequence: if n divides m then a(n) divides a(m). - Peter Bala, Feb 27 2019

Crossrefs

Programs

  • GAP
    List([0..80], n-> n/Gcd(n, 2^5)); # G. C. Greubel, Feb 27 2019
  • Magma
    [n/GCD(n, 2^5): n in [0..80]]; // G. C. Greubel, Feb 27 2019
    
  • Maple
    seq(n/igcd(n,32),n=0..70); # Muniru A Asiru, Feb 28 2019
  • Mathematica
    With[{c=2^5},Table[n/GCD[n,c],{n,0,70}]] (* Harvey P. Dale, Feb 16 2018 *)
  • PARI
    a(n)=n/gcd(n, 2^5); \\ Andrew Howroyd, Jul 23 2018
    
  • Sage
    [n/gcd(n,2^5) for n in (0..80)] # G. C. Greubel, Feb 27 2019
    

Formula

a(n) = n/gcd(n, 2^5).
a(n) = denominator(8*(n-4)/n), n >= 0 (with denominator(infinity) = 0).
From Peter Bala, Feb 27 2019: (Start)
a(n) = numerator(n/(n + 32)).
O.g.f.: F(x) - F(x^2) - F(x^4) - F(x^8) - F(x^16) - F(x^32), where F(x) = x/(1 - x)^2. Cf. A106617. (End)
From Bernard Schott, Mar 02 2019: (Start)
a(n) = 1 iff n is 1, 2, 4, 8, 16, 32 and a(2^n) = 2^(n-5) for n >= 5.
a(n) = n iff n is odd (A005408). (End)
From Amiram Eldar, Nov 25 2022: (Start)
Multiplicative with a(2^e) = 2^(e-min(e,5)), and a(p^e) = p^e for p > 2.
Dirichlet g.f.: zeta(s-1)*(1 - 1/2^s - 1/2^(2*s) - 1/2^(3*s) - 1/2^(4*s) - 1/2^(5*s)).
Sum_{k=1..n} a(k) ~ (683/2048) * n^2. (End)

Extensions

Keyword:mult added by Andrew Howroyd, Jul 23 2018
Showing 1-2 of 2 results.