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

A103438 Square array T(m,n) read by antidiagonals: Sum_{k=1..n} k^m.

Original entry on oeis.org

0, 0, 1, 0, 1, 2, 0, 1, 3, 3, 0, 1, 5, 6, 4, 0, 1, 9, 14, 10, 5, 0, 1, 17, 36, 30, 15, 6, 0, 1, 33, 98, 100, 55, 21, 7, 0, 1, 65, 276, 354, 225, 91, 28, 8, 0, 1, 129, 794, 1300, 979, 441, 140, 36, 9, 0, 1, 257, 2316, 4890, 4425, 2275, 784, 204, 45, 10
Offset: 0

Views

Author

Ralf Stephan, Feb 11 2005

Keywords

Comments

For the o.g.f.s of the column sequences for this array, see A196837 and the link given there. - Wolfdieter Lang, Oct 15 2011
T(m,n)/n is the m-th moment of the discrete uniform distribution on {1,2,...,n}. - Geoffrey Critzer, Dec 31 2018
T(1,n) divides T(m,n) for odd m. - Franz Vrabec, Dec 23 2020

Examples

			Square array begins:
  0, 1,  2,   3,    4,     5,     6,      7,      8,      9, ... A001477;
  0, 1,  3,   6,   10,    15,    21,     28,     36,     45, ... A000217;
  0, 1,  5,  14,   30,    55,    91,    140,    204,    285, ... A000330;
  0, 1,  9,  36,  100,   225,   441,    784,   1296,   2025, ... A000537;
  0, 1, 17,  98,  354,   979,  2275,   4676,   8772,  15333, ... A000538;
  0, 1, 33, 276, 1300,  4425, 12201,  29008,  61776, 120825, ... A000539;
  0, 1, 65, 794, 4890, 20515, 67171, 184820, 446964, 978405, ... A000540;
Antidiagonal triangle begins as:
  0;
  0, 1;
  0, 1,  2;
  0, 1,  3,  3;
  0, 1,  5,  6,  4;
  0, 1,  9, 14, 10,  5;
  0, 1, 17, 36, 30, 15, 6;
		

References

  • J. Faulhaber, Academia Algebrae, Darinnen die miraculosische inventiones zu den höchsten Cossen weiters continuirt und profitirt werden, Augspurg, bey Johann Ulrich Schönigs, 1631.

Crossrefs

Diagonals include A076015 and A031971.
Antidiagonal sums are in A103439.
Antidiagonals are the rows of triangle A192001.

Programs

  • Magma
    T:= func< n,k | n eq 0 select k else (&+[j^n: j in [0..k]]) >;
    [T(n-k,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Dec 22 2021
    
  • Maple
    seq(print(seq(Zeta(0,-k,1)-Zeta(0,-k,n+1),n=0..9)),k=0..6);
    # (Produces the square array from the example.) Peter Luschny, Nov 16 2008
    # alternative
    A103438 := proc(m,n)
        (bernoulli(m+1,n+1)-bernoulli(m+1))/(m+1) ;
        if m = 0 then
            %-1 ;
        else
            % ;
        end if;
    end proc: # R. J. Mathar, May 10 2013
    # simpler:
    A103438 := proc(m,n)
        (bernoulli(m+1,n+1)-bernoulli(m+1,1))/(m+1) ;
    end proc: # Peter Luschny, Mar 20 2024
  • Mathematica
    T[m_, n_]:= HarmonicNumber[m, -n]; Flatten[Table[T[m-n, n], {m, 0, 11}, {n, m, 0, -1}]] (* Jean-François Alcover, May 11 2012 *)
  • PARI
    T(m,n)=sum(k=0,n,k^m)
    
  • Python
    from itertools import count, islice
    from math import comb
    from fractions import Fraction
    from sympy import bernoulli
    def A103438_T(m,n): return sum(k**m for k in range(1,n+1)) if n<=m else int(sum(comb(m+1,i)*(bernoulli(i) if i!=1 else Fraction(1,2))*n**(m-i+1) for i in range(m+1))/(m+1))
    def A103438_gen(): # generator of terms
        for m in count(0):
            for n in range(m+1):
                yield A103438_T(m-n,n)
    A103438_list = list(islice(A103438_gen(),100)) # Chai Wah Wu, Oct 23 2024
  • SageMath
    def T(n,k): return (bernoulli_polynomial(k+1, n+1) - bernoulli_polynomial(1, n+1)) /(n+1)
    flatten([[T(n-k,k) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Dec 22 2021
    

Formula

E.g.f.: e^x*(e^(x*y)-1)/(e^x-1).
T(m, n) = Zeta(-n, 1) - Zeta(-n, m + 1), for m >= 0 and n >= 0, where Zeta(z, v) is the Hurwitz zeta function. - Peter Luschny, Nov 16 2008
T(m, n) = HarmonicNumber(m, -n). - Jean-François Alcover, May 11 2012
T(m, n) = (Bernoulli(m + 1, n + 1) - Bernoulli(m + 1, 1)) / (m + 1). - Peter Luschny, Mar 20 2024
T(m, n) = Sum_{k=0...m-n} B(k)*(-1)^k*binomial(m-n,k)*n^(m-n-k+1)/(m-n-k+1), where B(k) = Bernoulli number A027641(k) / A027642(k). - Robert B Fowler, Aug 20 2024
T(m, n) = Sum_{i=1..n} J_m(i)*floor(n/i), where J_m is the m-th Jordan totient function. - Ridouane Oudra, Jul 19 2025

A056739 Numbers k such that k | 10^k + 9^k + 8^k + 7^k + 6^k + 5^k + 4^k + 3^k + 2^k + 1^k.

Original entry on oeis.org

1, 5, 11, 25, 55, 121, 125, 275, 365, 605, 625, 925, 1331, 1375, 2365, 3025, 3125, 6655, 6875, 14641, 15125, 15625, 22625, 27565, 32125, 33275, 34375, 73205, 75625, 78125, 123365, 161051, 166375, 171875, 366025, 378125, 390625, 541717, 660605
Offset: 1

Views

Author

Robert G. Wilson v, Aug 25 2000

Keywords

Comments

Contains A003598. In general n=p^i * q^j => n | Sum_{k=1..2*p} k^n, where p and q=2*p+1 are prime (see Meyer ref).
All terms == 1 or 5 (mod 6). The only prime terms are 5 and 11. - Robert Israel, Jun 25 2025

Crossrefs

Programs

  • Maple
    filter:= n ->   10 &^n + 9 &^ n + 8 &^ n + 7 &^ n + 6&^ n + 5&^n + 4&^n + 3&^n + 2&^n + 1 mod n = 0:
    select(filter, [seq(seq(6*i + j, j=[1,5]),i=0..10^6)]); # Robert Israel, Jun 25 2025
  • Mathematica
    Do[ If[ Mod[ PowerMod[ 10, n, n ] + PowerMod[ 9, n, n ] + PowerMod[ 8, n, n ] + PowerMod[ 7, n, n ] + PowerMod[ 6, n, n ] + PowerMod[ 5, n, n ] + PowerMod[ 4, n, n ] + PowerMod[ 3, n, n ] + PowerMod[ 2, n, n ] + 1, n ] == 0, Print[ n ] ], {n, 1, 10^6} ]
    Select[Range[700000],Divisible[Total[Range[10]^#],#]&] (* Harvey P. Dale, Nov 24 2014 *)
    Select[Range[700000],Mod[Total[PowerMod[Range[10],#,#]],#]==0&] (* Harvey P. Dale, Feb 23 2023 *)

A192001 Triangle with sums of nonnegative integer powers of positive first n integers in the columns.

Original entry on oeis.org

1, 2, 1, 3, 3, 1, 4, 6, 5, 1, 5, 10, 14, 9, 1, 6, 15, 30, 36, 17, 1, 7, 21, 55, 100, 98, 33, 1, 8, 28, 91, 225, 354, 276, 65, 1, 9, 36, 140, 441, 979, 1300, 794, 129, 1, 10, 45, 204, 784, 2275, 4425, 4890, 2316, 257, 1
Offset: 1

Views

Author

Wolfdieter Lang, Jun 25 2011

Keywords

Comments

This is the Abramowitz-Stegun table on p. 813, call it s(m,n), with an extra column n=0 with values n added, and read by antidiagonals. a(n,m) = s(n-m,m), n+1 >= m >= 0.
O.g.f. for column no. m >= 0: (x^(m+1)/(1-x)^(m+2))*E(m;x) with the row polynomials E(m;x) = Sum_{p=0..m} A173018(m,p)*x^p of the Eulerian number triangle (proof via the Worpitzky identity). See the Graham et al. reference p. 253-8 for Eulerian numbers, and the Worpitzky identity (6.37) on p. 255.
E.g.f. for diagonals (starting with k=0 for the main diagonal): g(k,x) = exp(x)*(exp((k+1)*x)-1)/(1-exp(x)).
Compare with (7.77) on p. 353 of the Graham et al. reference.
O.g.f. for diagonals (starting with k=0 for the main diagonal): G(k,z) =(Psi(1/z+1)-Psi(1/z-k-1))/z - 1.
with the digamma function Psi(z):=(log(Gamma(z)))'.
Compare with Graham et al., p. 352, eq.(7.76), where H_z=Psi(z+1)+gamma, with the Euler-Mascheroni constant gamma.
The diagonal sequences are, for k=0..9: A000012, A000051, A001550-A001557.
The negative k-diagonal, -a(k+m+1,m), yields the Sheffer z-sequence Shz(k+1;m) for the Sheffer arrays |S1|(k+1) defined in a comment to A094646.
See also A196837 with a W. Lang link, where the o.g.f.s for the diagonals, numbered with k >= 1, are given as G(k,x) = Sum_{m=0..k} (k-m)*S1(k+1,k+1-m)*x^m / Product_{j=1..k} (1-j*x), with S1 the Stirling numbers of the first kind, A048994. - Wolfdieter Lang, Nov 01 2011

Examples

			The triangle a(n,m) begins:
n\m    0   1   2    3    4     5     6     7    8   9  10 ...
n=1:   1
n=2:   2   1
n=3:   3   3   1
n=4:   4   6   5    1
n=5:   5  10  14    9    1
n=6:   6  15  30   36   17     1
n=7:   7  21  55  100   98    33     1
n=8:   8  28  91  225  354   276    65     1
n=9:   9  36 140  441  979  1300   794   129    1
n=10: 10  45 204  784 2275  4425  4890  2316  257   1
n=11: 11  55 285 1296 4676 12201 20515 18700 6818 513   1
...  Reformatted and extended by _Wolfdieter Lang_, Jan 12 2013
a(4,2)= 5 = s(2,2) = 1^2 + 2^2.
Recurrence: 55 = a(7,2) = (7-2)*a(6,1) - (a(2,1) + a(3,1) + a(4,1) + a(5,1)) = 5*15 - (1 + 3 + 6 + 10) = 55. - _Wolfdieter Lang_, Jan 12 2013
The first column, m=0 holds the integers 1,2,3,..., equal to the sums of 0th powers of the n first integers. The second column is 1, 1+2, 1+2+3, ... = A000217. The third column are the sums of squares, 1^2, 1^2+2^2, 1^2+2^2+3^3, ... = A000330, etc. - _M. F. Hasler_, Jan 13 2013
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964. Tenth printing, Wiley, 2002 (also electronically available, see the link), p. 813.
  • Mohammad K. Azarian, Problem 1218, Pi Mu Epsilon Journal, Vol. 13, No. 2, Spring 2010, p. 116. Solution published in Vol. 13, No. 3, Fall 2010, pp. 183-185.
  • Ronald L. Graham, Donald E. Knuth and Oren Patashnik, Concrete Mathematics, Addison-Wesley, 1991.

Crossrefs

Cf. A103438 (omitting the first column of zeros, reversed).

Programs

Formula

a(n,m) = s(n-m,m), n-1 >= m >= 0, n >= 1, else 0, with s(n,m) := Sum_{k=1..n} k^m.
O.g.f. column no. m: see a comment above.
O.g.f.s and e.g.f.s for diagonals k >= 0: see a comment above.
Recurrence known by Ibn al-Haytham (see a comment and link under A000537, and comments by Bruno Berselli under the A-numbers of the first column sequences):
a(n,m) = (n-m)*a(n-1,m-1) - Sum_{j=m..n-2} a(j,m-1), n >= 1, n-1 >= m >= 1. a(n,0) = n. - Wolfdieter Lang, Jan 12 2013
Showing 1-3 of 3 results.