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.

User: Henry W. Gould

Henry W. Gould's wiki page.

Henry W. Gould has authored 4 sequences.

A227800 Number of different values the product p*q can have where p >= 1, q >= 1 with p+q < n.

Original entry on oeis.org

0, 0, 1, 2, 4, 5, 8, 10, 13, 16, 19, 21, 26, 29, 34, 39, 44, 48, 53, 58, 65, 71, 78, 83, 91, 97, 104, 111, 118, 124, 134, 141, 150, 158, 167, 176, 186, 194, 204, 213, 224, 232, 245, 254, 267, 278, 290, 301, 315, 328, 339, 351, 366, 376, 391, 404, 419, 432, 446
Offset: 1

Author

Henry W. Gould, Sep 23 2013

Keywords

Comments

Game played often with n = 10.

Programs

  • Maple
    A227800 := proc(n)
        local s, p, q ;
        s := {} ;
        for p from 1 to iquo(n-1, 2) do
        for q from p to n-1-p do
                s := s union {p*q} ;
        end do:
        end do:
        nops(s) ;
    end proc:
    seq(A227800(n), n=1..120) ; # R. J. Mathar, Nov 24 2013
  • Mathematica
    A227800[n_] := Module[{s, p, q}, s = {}; For[p = 1, p <= Quotient[n-1, 2], p++, For[q = p, q <= n-1-p, q++, s = s ~Union~ {p*q}]] ; Length[s]]; Table[A227800[n], {n, 1, 120}] (* Jean-François Alcover, Feb 27 2014, after R. J. Mathar *)

A003100 Decimal Gray code for n.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 19, 18, 17, 16, 15, 14, 13, 12, 11, 10, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 39, 38, 37, 36, 35, 34, 33, 32, 31, 30, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 79, 78, 77
Offset: 0

Keywords

Comments

This permutation of the nonnegative integers is not self-inverse, as previously claimed. The first exception is a(100) = 190, but a(190) = 109. - Franklin T. Adams-Watters, Mar 05 2010
a(n) = A118757(n) for n<=100, = a(100)=A118757(100)=190, but a(101)=191, A118757(101)=180. - Reinhard Zumkeller, May 01 2006

References

  • M. Gardner, Knotted Doughnuts and Other Mathematical Entertainments. Freeman, NY, 1986, p. 18.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Inverse is A174025.

Programs

  • Maple
    A003100 :=proc(n)
        local s,i:
        s:=[op(convert(n,base,10)),0]:
        add(piecewise(s[i+1] mod 2=0,s[i],9-s[i])*10^(i-1),i=1..nops(s)-1) :
    end proc:
    seq(A003100(j),j=0..100); # Pab Ter, Oct 14 2005

Extensions

More terms from Pab Ter (pabrlos2(AT)yahoo.com), Oct 14 2005
Incorrect comment replaced by Franklin T. Adams-Watters, Mar 05 2010

A003099 a(n) = Sum_{k=0..n} binomial(n,k^2).

Original entry on oeis.org

1, 2, 3, 4, 6, 11, 22, 43, 79, 137, 231, 397, 728, 1444, 3018, 6386, 13278, 26725, 51852, 97243, 177671, 320286, 579371, 1071226, 2053626, 4098627, 8451288, 17742649, 37352435, 77926452, 159899767, 321468048, 632531039, 1219295320, 2308910353, 4314168202
Offset: 0

Keywords

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Partial sums of A103198.

Programs

  • Magma
    [(&+[Binomial(n, j^2): j in [0..n]]): n in [0..50]]; // G. C. Greubel, Oct 26 2022
    
  • Mathematica
    Table[Sum[Binomial[n, k^2], {k, 0, Sqrt[n]}], {n, 0, 50}] (* T. D. Noe, Sep 10 2011 *)
  • PARI
    a(n)=sum(k=0,sqrtint(n),binomial(n,k^2)) \\ Charles R Greathouse IV, Mar 26 2013
    
  • SageMath
    def A003099(n): return sum( binomial(n,k^2) for k in range(isqrt(n)+1))
    [A003099(n) for n in range(50)] # G. C. Greubel, Oct 26 2022

Formula

a(n)*sqrt(n)/2^n is bounded: lim sup a(n)*sqrt(n)/2^n = 0.82... and lim inf a(n)*sqrt(n)/2^n = 0.58... - Benoit Cloitre, Nov 14 2003 [These constants are sqrt(2/Pi) * JacobiTheta3(0,exp(-4)) = 0.827112271364145742... and sqrt(2/Pi) * JacobiTheta2(0,exp(-4)) = 0.587247586271786487... - Vaclav Kotesovec, Jan 15 2023]
Binomial transform of the characteristic function of squares A010052. - Carl Najafi, Sep 09 2011
G.f.: (1/(1 - x)) * Sum_{k>=0} (x/(1 - x))^(k^2). - Ilya Gutkovskiy, Jan 22 2024

Extensions

More terms from Carl Najafi, Sep 09 2011

A003101 a(n) = Sum_{k = 1..n} (n - k + 1)^k.

Original entry on oeis.org

0, 1, 3, 8, 22, 65, 209, 732, 2780, 11377, 49863, 232768, 1151914, 6018785, 33087205, 190780212, 1150653920, 7241710929, 47454745803, 323154696184, 2282779990494, 16700904488705, 126356632390297, 987303454928972, 7957133905608836, 66071772829247409
Offset: 0

Keywords

Comments

For n > 0: a(n) = sum of row n of triangles A051129 and A247358. - Reinhard Zumkeller, Sep 14 2014
a(n-1) is the number of set partitions of [n] into two or more blocks such that all absolute differences between least elements of consecutive blocks are 1. a(3) = 8: 134|2, 13|24, 14|23, 1|234, 14|2|3, 1|24|3, 1|2|34, 1|2|3|4. - Alois P. Heinz, May 22 2017
Min_{n >= 1} a(n+1)/a(n) = 8/3. This is the answer to the 4th problem proposed during the first day of the final round of the 16th Austrian Mathematical Olympiad in 1985 (see link IMO Compendium). - Bernard Schott, Jan 07 2019
If n rings of different internal diameter can fit close together on a tapering column, a(n) is the number of different arrangements of at least one ring. For example, if the rings increasing in size are 1, 2 and 3, then a(3) = 8 corresponding to the possible arrangements from the point on the column of smallest diameter (1XX), (X2X), (XX3), (12X), (32X), (1X3), (X23) and (123), where X denotes a space on the column. - Ian Duff, Jun 23 2025

Examples

			For n = 3 we get a(3) = 3^1 + 2^2 + 1^3 = 8. For n = 4 we get a(4) = 4^1 + 3^2 + 2^3 + 1^4 = 22.
		

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

First differences are in A047970.

Programs

  • Haskell
    a003101 n = sum $ zipWith (^) [0 ..] [n + 1, n .. 1]
    -- Reinhard Zumkeller, Sep 14 2014
    
  • Magma
    [n eq 0 select 0 else (&+[(n-j+1)^j: j in [1..n]]): n in [0..50]]; // G. C. Greubel, Oct 26 2022
    
  • Maple
    A003101 := n->add((n-k+1)^k, k=1..n);
    a:= n-> add((n-j+1)^j, j=1..n): seq(a(n), n=0..30); # Zerinvary Lajos, Jun 07 2008
  • Mathematica
    Table[Sum[(n-k+1)^k,{k,n}],{n,0,25}] (* Harvey P. Dale, Aug 14 2011 *)
  • PARI
    a(n)=sum(k=1,n,(n-k+1)^k) \\ Charles R Greathouse IV, Oct 31 2011
    
  • SageMath
    def A003101(n): return sum( (n-k+1)^k for k in range(1,n+1))
    [A003101(n) for n in range(50)] # G. C. Greubel, Oct 26 2022

Formula

a(n) = A026898(n) - 1.
G.f.: G(0)/x-1/(1-x)/x where G(k) = 1 + x*(2*k*x-1)/((2*k*x+x-1) - x*(2*k*x+x-1)^2/(x*(2*k*x+x-1) + (2*k*x+2*x-1)/G(k+1) )); (recursively defined continued fraction). - Sergei N. Gladkovskii, Jan 26 2013
G.f.: Sum_{k>=1} x^k/(1 - (k + 1)*x). - Ilya Gutkovskiy, Oct 09 2018
a(n) = n^1 + (n-1)^2 + (n-2)^3 + ... + 3^(n-2) + 2^(n-1) + 1^n. - Bernard Schott, Jan 07 2019
log(a(n)) ~ (1 - 1/LambertW(exp(1)*n)) * n * log(1 + n/LambertW(exp(1)*n)). - Vaclav Kotesovec, Jun 15 2021
a(n) ~ sqrt(2*Pi/(n+1 + w(n))) * w(n)^(n+2 - w(n)), where w(n) = (n+1)/LambertW(exp(1)*(n+1)). - Vaclav Kotesovec, Jun 25 2021, after user "leonbloy", see Mathematics Stack Exchange link.