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-10 of 20 results. Next

A027444 a(n) = n^3 + n^2 + n.

Original entry on oeis.org

0, 3, 14, 39, 84, 155, 258, 399, 584, 819, 1110, 1463, 1884, 2379, 2954, 3615, 4368, 5219, 6174, 7239, 8420, 9723, 11154, 12719, 14424, 16275, 18278, 20439, 22764, 25259, 27930, 30783, 33824, 37059, 40494, 44135, 47988, 52059, 56354, 60879, 65640, 70643, 75894
Offset: 0

Views

Author

Patrick De Geest and Mark Milhet (mm992395(AT)shellus.com)

Keywords

Comments

For n>1, a(n) is the volume of a truncated square pyramid with height n and base lengths n+2 and n-1. - Wesley Ivan Hurt, Apr 05 2016

Examples

			For n = 4, 4^3 + 4^2 + 4 = 64 + 16 + 4 = 84.
		

Crossrefs

Column k=3 of A228275.
Cf. A270109.

Programs

Formula

O.g.f.: x*(3 + 2*x + x^2)/(1 - x)^4. - R. J. Mathar, Feb 04 2008
a(n) = 4*a(n-1) - 6*a(n-2) + 4*a(n-3) - a(n-4) for n>3. - Wesley Ivan Hurt, Apr 05 2016

A080674 a(n) = (4/3)*(4^n - 1).

Original entry on oeis.org

0, 4, 20, 84, 340, 1364, 5460, 21844, 87380, 349524, 1398100, 5592404, 22369620, 89478484, 357913940, 1431655764, 5726623060, 22906492244, 91625968980, 366503875924, 1466015503700, 5864062014804, 23456248059220, 93824992236884, 375299968947540, 1501199875790164
Offset: 0

Views

Author

N. J. A. Sloane, Mar 02 2003

Keywords

Comments

a(n) is the number of steps which are made when generating all n-step random walks that begin in a given point P on a two-dimensional square lattice. To make one step means to move along one edge on the lattice. - Pawel P. Mazur (Pawel.Mazur(AT)pwr.wroc.pl), Mar 10 2005
Conjectured to be the number of integers from 0 to (10^n)-1 that lack 0, 1, 2, 3, 4 and 5 as a digit. - Alexandre Wajnberg, Apr 25 2005
Gives the values of m such that binomial(4*m + 4,m) is odd. Cf. A002450, A020988 and A263132. - Peter Bala, Oct 11 2015
Also the partial sums of 4^n for n>0, cf. A000302. - Robert G. Wilson v, Sep 18 2016

Crossrefs

Programs

Formula

a(n) = 2*A020988(n) = A002450(n+1) - 1 = 4*A002450(n).
a(n) = Sum_{i = 1..n} 4^i. - Adam McDougall (mcdougal(AT)stolaf.edu), Sep 29 2004
a(n) = 4*a(n-1) + 4. - Alexandre Wajnberg, Apr 25 2005
a(n) = 4^n + a(n-1) (with a(0) = 0). - Vincenzo Librandi, Aug 08 2010
From Colin Barker, Oct 12 2015: (Start)
a(n) = 5*a(n-1) - 4*a(n-2).
G.f.: 4*x / ((x-1)*(4*x-1)). (End)
E.g.f.: 4*exp(x)*(exp(3*x) - 1)/3. - Elmo R. Oliveira, Dec 17 2023

A060072 a(n) = (n^(n-1) - 1)/(n-1) for n>1, a(1) = 0.

Original entry on oeis.org

0, 1, 4, 21, 156, 1555, 19608, 299593, 5380840, 111111111, 2593742460, 67546215517, 1941507093540, 61054982558011, 2085209001813616, 76861433640456465, 3041324492229179280, 128583032925805678351, 5784852794328402307380, 275941052631578947368421
Offset: 1

Views

Author

Henry Bottomley, Feb 21 2001

Keywords

Comments

(n-1)-digit repunits in base n written in decimal.

Examples

			a(10)=111111111; i.e., just nine 1's (converted from base 10 to decimal).
		

Crossrefs

Cf. other sequences of generalized repunits, such as A053696, A055129, A031973, A125598, A173468, A023037, A119598, A085104, and A162861.

Programs

  • Magma
    [0] cat [ (n^(n-1) -1)/(n-1) : n in [2..25]]; // G. C. Greubel, Aug 15 2022
    
  • Mathematica
    Join[{0},Array[(#^(#-1)-1)/(#-1)&,20,2]] (* Harvey P. Dale, Jun 04 2013 *)
  • PARI
    a(n) = if (n==1, 0, (n^(n - 1) - 1)/(n - 1)); \\ Harry J. Smith, Jul 01 2009
    
  • SageMath
    [0]+[(n^(n-1) -1)/(n-1) for n in (2..25)] # G. C. Greubel, Aug 15 2022

Formula

a(n+1) = Sum_{k=1..n} n^(k-1)*C(n, k). - Olivier Gérard, Jun 26 2001 [Corrected by Mathew Englander, Dec 15 2020]
a(n) = Sum_{j=2..n} n^(n-j). - Zerinvary Lajos, Sep 11 2006
a(n+1) = A125118(n,n). - Reinhard Zumkeller, Nov 21 2006
a(n) = Integral_{x=1/n..1} 1/x^n dx. - Francesco Daddi, Aug 01 2011
a(n) = A037205(n-1)/(n-1) = A060073(n)*(n-1) = A023037(n) - A000169(n).
a(n) = [x^n] x^2/((1 - x)*(1 - n*x)). - Ilya Gutkovskiy, Oct 04 2017
a(n) = 1 + A228275(n, n-2) for n >= 2. - Mathew Englander, Dec 14 2020

Extensions

Name edited by Michel Marcus, Dec 14 2020

A052386 Number of integers from 1 to 10^n-1 that lack 0 as a digit.

Original entry on oeis.org

0, 9, 90, 819, 7380, 66429, 597870, 5380839, 48427560, 435848049, 3922632450, 35303692059, 317733228540, 2859599056869, 25736391511830, 231627523606479, 2084647712458320, 18761829412124889, 168856464709124010, 1519708182382116099, 13677373641439044900
Offset: 0

Views

Author

Odimar Fabeny, Mar 10 2000

Keywords

Examples

			For n=2, the numbers from 1 to 99 which *have* 0 as a digit are the 9 numbers 10, 20, 30, ..., 90. So a(1) = 99 - 9 = 90.
		

Crossrefs

Row n=9 of A228275.

Programs

Formula

a(n) = 9*a(n-1) + 9.
a(n) = 9*(9^n-1)/8 = sum_{j=1..n} 9^j = a(n-1)+9^n = 9*A002452(n) = A002452(n+1)-1; write A000918(n+1) in base 2 and read as if written in base 9. - Henry Bottomley, Aug 30 2001
a(n) = 10*a(n-1)-9*a(n-2). G.f.: 9*x / ((x-1)*(9*x-1)). - Colin Barker, Sep 26 2013

Extensions

More terms and revised description from James Sellers, Mar 13 2000
More terms and revised description from Robert G. Wilson v, Apr 14 2003
More terms from Colin Barker, Sep 26 2013

A027445 a(n) = n^4 + n^3 + n^2 + n^1.

Original entry on oeis.org

0, 4, 30, 120, 340, 780, 1554, 2800, 4680, 7380, 11110, 16104, 22620, 30940, 41370, 54240, 69904, 88740, 111150, 137560, 168420, 204204, 245410, 292560, 346200, 406900, 475254, 551880, 637420, 732540, 837930, 954304, 1082400, 1222980, 1376830, 1544760, 1727604
Offset: 0

Views

Author

Keywords

Comments

a(A047203(n)) mod 10 = 0; a(A016861(n)) mod 10 = 4. - Reinhard Zumkeller, Oct 23 2006

Crossrefs

Equals 2 * A071237(n).
Column k=4 of A228275.

Programs

A031972 a(n) = Sum_{k=1..n} n^k.

Original entry on oeis.org

0, 1, 6, 39, 340, 3905, 55986, 960799, 19173960, 435848049, 11111111110, 313842837671, 9726655034460, 328114698808273, 11966776581370170, 469172025408063615, 19676527011956855056, 878942778254232811937, 41660902667961039785742, 2088331858752553232964199
Offset: 0

Views

Author

N. J. A. Sloane, Dec 11 1999

Keywords

Comments

Sum of lengths of longest ending contiguous subsequences with the same value over all s in {1,...,n}^n: a(n) = Sum_{k=1..n} k*A228273(n,k). a(2) = 6 = 2+1+1+2: [1,1], [1,2], [2,1], [2,2]. - Alois P. Heinz, Aug 19 2013
a(n) is the expected wait time to see the contiguous subword 11...1 (n copies of 1) over all infinite sequences on alphabet {1,2,...,n}. - Geoffrey Critzer, May 19 2014
a(n) is the number of sequences of k elements from {1,2,...,n}, where 1<=k<=n. For example, a(2) = 6, counting the sequences, [1], [2], [1,1], [1,2], [2,1], [2,2]. Equivalently, a(n) is the number of bar graphs having a height and width of at most n. - Emeric Deutsch, Jan 24 2017.
In base n, a(n) has n+1 digits: n 1's followed by a 0. - Mathew Englander, Oct 20 2020

Crossrefs

Main diagonal of A228275.

Programs

Formula

a(1)=1; for n!=1 a(n) = (n^(n+1)-1)/(n-1) - 1. - Benoit Cloitre, Aug 17 2002
a(n) = A031973(n)-1 for n>0. - Robert G. Wilson v, Apr 15 2015
a(n) = n*A023037(n) = n^n - 1 + A023037(n). - Mathew Englander, Oct 20 2020

Extensions

a(0)=0 prepended by Alois P. Heinz, Oct 22 2019

A105279 a(0)=0; a(n) = 10*a(n-1) + 10.

Original entry on oeis.org

0, 10, 110, 1110, 11110, 111110, 1111110, 11111110, 111111110, 1111111110, 11111111110, 111111111110, 1111111111110, 11111111111110, 111111111111110, 1111111111111110, 11111111111111110, 111111111111111110, 1111111111111111110, 11111111111111111110, 111111111111111111110
Offset: 0

Views

Author

Alexandre Wajnberg, Apr 25 2005

Keywords

Comments

a(n) is the smallest even number with digits in {0,1} having digit sum n; in other words, the base 10 reading of the binary string of A000918(n). Cf. A069532. - Jason Kimberley, Nov 02 2011
Also, except for a(0), the binary representation of the diagonal from the corner to the origin of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 645", based on the 5-celled von Neumann neighborhood, initialized with a single black (ON) cell at stage zero. - Robert Price, Jul 19 2017

References

  • S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 170.

Crossrefs

Row n=10 of A228275.
Partial sums of A178500.

Programs

  • Haskell
    a105279 n = a105279_list !! n
    a105279_list = iterate ((* 10) . (+ 1)) 0
    -- Reinhard Zumkeller, Feb 05 2012
  • Magma
    [-10/9+(10/9)*10^n: n in [0..20]]; // Vincenzo Librandi, Jul 04 2011
    
  • Mathematica
    NestList[10*(# + 1) &, 0, 25] (* Paolo Xausa, Jul 17 2024 *)

Formula

a(n) = (10/9)*(10^n - 1), with n>=0.
a(n) = Sum_{k=1..n} 10^k.
Repunits times 10: a(n) = 10 * A002275(n). - Reinhard Zumkeller, Feb 05 2012
From Stefano Spezia, Sep 15 2023: (Start)
O.g.f.: 10*x/((1 - x)*(1 - 10*x)).
E.g.f.: 10*exp(x)*(exp(9*x) - 1)/9. (End)
From Elmo R. Oliveira, Jun 18 2025: (Start)
a(n) = 11*a(n-1) - 10*a(n-2).
a(n) = A124166(n)/10.
a(n) = A161770(n)/100 for n >= 1. (End)

A226238 a(n) = (n^n - n)/(n - 1).

Original entry on oeis.org

2, 12, 84, 780, 9330, 137256, 2396744, 48427560, 1111111110, 28531167060, 810554586204, 25239592216020, 854769755812154, 31278135027204240, 1229782938247303440, 51702516367896047760, 2314494592664502210318, 109912203092239643840220
Offset: 2

Views

Author

Ralf Stephan, Aug 25 2013

Keywords

Comments

a(n) expressed in base n is written with (n-1) ones followed by a zero. - Michel Marcus, Aug 25 2013

Crossrefs

A diagonal of A228275.

Programs

  • Mathematica
    Array[(#^# - #)/(# - 1) &, 18, 2] (* Michael De Vlieger, May 24 2023 *)
  • PARI
    a(n)=(n^n-n)/(n-1)
    
  • Python
    def A226238(n): return (n**n-n)//(n-1) # Chai Wah Wu, Sep 28 2023

Formula

a(n) = Sum_{k=1..n-1} n^k.
a(n) = A023037(n) - 1, for n>1. - Michel Marcus, Aug 25 2013

A152031 a(n) = n^5 + n^4 + n^3 + n^2 + n.

Original entry on oeis.org

0, 5, 62, 363, 1364, 3905, 9330, 19607, 37448, 66429, 111110, 177155, 271452, 402233, 579194, 813615, 1118480, 1508597, 2000718, 2613659, 3368420, 4288305, 5399042, 6728903, 8308824, 10172525, 12356630, 14900787, 17847788, 21243689, 25137930, 29583455
Offset: 0

Views

Author

Keywords

Crossrefs

Column k=5 of A228275.
Cf. A053699.

Programs

  • Maple
    a:= n-> `if`(n=1, 5, (n^6-n)/(n-1)):
    seq(a(n), n=0..35);  # Alois P. Heinz, Aug 20 2013
  • Mathematica
    lst={};Do[AppendTo[lst,n^5+n^4+n^3+n^2+n],{n,0,5!}];lst
    (* Other programs: *)
    Table[Total[n^Range@ 5], {n, 0, 31}] (* or *)
    CoefficientList[Series[x (5 + 32 x + 66 x^2 + 16 x^3 + x^4)/(x - 1)^6, {x, 0, 31}], x] (* Michael De Vlieger, Apr 05 2017 *)
  • PARI
    a(n) = n^5 + n^4 + n^3 + n^2 + n; \\ Joerg Arndt, Sep 03 2013
    
  • Python
    def a(n): return n**5 + n**4 + n**2 + n # Indranil Ghosh, Apr 05 2017
  • R
    a <- c(0, 5, 62, 363, 1364, 3905)
    for(n in (length(a)+1):40) a[n] <- 6*a[n-1] -15*a[n-2] +20*a[n-3] -15*a[n-4] +6*a[n-5] -a[n-6]
    a
    [Yosu Yurramendi, Sep 03 2013]
    

Formula

a(n) = 6*a(n-1)-15*a(n-2)+20*a(n-3)-15*a(n-4)+6*a(n-5)-a(n-6) n>5, a(0)=0, a(1)=5, a(2)=62, a(3)=363, a(4)=1364, a(5)=3905. [Yosu Yurramendi, Sep 03 2013]
From Indranil Ghosh, Apr 05 2017: (Start)
G.f.: x*(5 + 32x + 66x^2 + 16x^3 + x^4)/(x - 1)^6.
E.g.f.: exp(x)*x*(5 + 26x + 32x^2 + 11x^3 + x^4).
(End)
a(n) = n*A053699(n). - Michel Marcus, Apr 05 2017

A104891 a(0) = 0; a(n) = 5*a(n-1) + 5.

Original entry on oeis.org

0, 5, 30, 155, 780, 3905, 19530, 97655, 488280, 2441405, 12207030, 61035155, 305175780, 1525878905, 7629394530, 38146972655, 190734863280, 953674316405, 4768371582030, 23841857910155, 119209289550780, 596046447753905, 2980232238769530, 14901161193847655
Offset: 0

Views

Author

Alexandre Wajnberg, Apr 24 2005

Keywords

Comments

Number of integers from 0 to (10^n)-1 that lack 0, 1, 2, 3 and 4 as a digit.
Number of monic irreducible polynomials of degree 1 in GF(5)[x1,...,xn]. - Max Alekseyev, Jan 23 2006

Examples

			a(3) = 5*a(2) + 5 = 5*30 + 5 = 155.
		

Crossrefs

Programs

  • Magma
    [5*(5^n -1)/4: n in [0..30]]; // G. C. Greubel, Jun 15 2021
    
  • Maple
    a:=n->add(5^j,j=1..n): seq(a(n),n=0..30); # Zerinvary Lajos, Jun 27 2007
  • Mathematica
    RecurrenceTable[{a[n]==5*a[n-1]+5, a[0]==0}, a, {n, 0, 30}] (* Vaclav Kotesovec, Jul 25 2014 *)
    NestList[5#+5&,0,30] (* Harvey P. Dale, Oct 04 2019 *)
  • PARI
    concat(0, Vec(5*x/((x-1)*(5*x-1)) + O(x^30))) \\ Colin Barker, Jul 25 2014
    
  • Sage
    [5*(5^n -1)/4 for n in (0..30)] # G. C. Greubel, Jun 15 2021

Formula

a(n) = 5*(5^n - 1)/4. - Max Alekseyev, Jan 23 2006
a(n) = a(n-1) + 5^n with a(0)=0. - Vincenzo Librandi, Nov 13 2010
From Colin Barker, Jul 25 2014: (Start)
a(n) = 6*a(n-1) - 5*a(n-2).
G.f.: 5*x / ((1-x)*(1-5*x)). (End)
E.g.f.: (5/4)*(exp(5*x) - exp(x)). - G. C. Greubel, Jun 15 2021
Showing 1-10 of 20 results. Next