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.

Previous Showing 11-20 of 27 results. Next

A059515 Square array T(k,n) by antidiagonals, where T(k,n) is number of ways of placing n identifiable nonnegative intervals with a total of exactly k starting and/or finishing points.

Original entry on oeis.org

1, 0, 0, 0, 1, 0, 0, 1, 1, 0, 0, 0, 7, 1, 0, 0, 0, 12, 25, 1, 0, 0, 0, 6, 138, 79, 1, 0, 0, 0, 0, 294, 1056, 241, 1, 0, 0, 0, 0, 270, 5298, 7050, 727, 1, 0, 0, 0, 0, 90, 12780, 70350, 44472, 2185, 1, 0, 0, 0, 0, 0, 16020, 334710, 817746, 273378, 6559, 1, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Henry Bottomley, Jan 19 2001

Keywords

Comments

See A300729 for a triangular version of this array. - Peter Bala, Jun 13 2019

Examples

			Rows are: 1,0,0,0,0,..., 0,1,1,0,0,..., 0,1,7,12,6,..., 0,1,25,138,294,..., etc. T(1,1)=1 since if a is starting point of interval and A is end point then only possibility is aA (zero length). T(2,1)=1 since possibility is a-A (positive length). T(3,2)=12 since possibilities are: aA-b-B, b-aA-B, b-B-aA, bB-a-A, a-bB-A, a-A-bB, ab-A-B, ab-B-A, a-b-AB, b-a-AB, a-bA-B, b-a-AB.
		

Crossrefs

Sum of rows gives A059516. Columns include A000007, A057427, A058481, A059117. Final positive number in each row is A000680.
Cf. A300729.

Formula

T(k, n) = T(k - 2, n - 1) * k * (k - 1)/2 + T(k - 1, n - 1) * k^2 + T(k, n - 1) * k * (k + 1)/2 with T(0, 0) = 1 = lambda(k, n) + lambda(k + 1, n) where lambda is A059117(k, n).

A132753 a(n) = 2^(n+1) - n + 1.

Original entry on oeis.org

3, 4, 7, 14, 29, 60, 123, 250, 505, 1016, 2039, 4086, 8181, 16372, 32755, 65522, 131057, 262128, 524271, 1048558, 2097133, 4194284, 8388587, 16777194, 33554409, 67108840, 134217703, 268435430, 536870885, 1073741796, 2147483619
Offset: 0

Views

Author

Gary W. Adamson, Aug 28 2007

Keywords

Comments

Apart from a(0): Row sums of triangle A132752 (old name).
Apart from a(0): Binomial transform of [1, 3, 0, 4, 0, 4, 0, 4, ...].

Examples

			a(3) = 14 = sum of row 3 terms of triangle A132752: (3 + 5 + 5 + 1).
a(3) = 14 = (1, 3, 3, 1) dot (1, 3, 0, 4) = (1 + 9 + 0 + 4).
		

Crossrefs

Programs

  • Magma
    [2^(n+1) -n+1: n in [0..40]]; // G. C. Greubel, Feb 16 2021
  • Maple
    A132753:= n-> 2^(n+1) -n+1; seq(A132753(n), n=0..40) # G. C. Greubel, Feb 16 2021
  • Mathematica
    Table[2^(n+1) -n+1, {n, 0, 30}] (* Bruno Berselli, Aug 31 2013 *)
  • PARI
    a(n)=2^(n+1)-n+1
    
  • PARI
    Vec( (3-8*x+6*x^2)/((1-x)^2*(1-2*x)) + O(x^40)) \\ Colin Barker, Mar 14 2014
    
  • Sage
    [2^(n+1) -n+1 for n in (0..40)] # G. C. Greubel, Feb 16 2021
    

Formula

From Colin Barker, Mar 14 2014: (Start)
a(n) = 4*a(n-1) - 5*a(n-2) + 2*a(n-3).
G.f.: (3 - 8*x + 6*x^2)/((1-x)^2 * (1-2*x)). (End)
E.g.f.: (1-x)*exp(x) + 2*exp(2*x). - G. C. Greubel, Feb 16 2021

Extensions

More terms Vladimir Joseph Stephan Orlovsky, Dec 25 2008
Changed first member, and better name from Ralf Stephan, Aug 31 2013

A238303 Triangle T(n,k), 0<=k<=n, read by rows given by T(n,0) = 1, T(n,k) = 2 if k>0.

Original entry on oeis.org

1, 1, 2, 1, 2, 2, 1, 2, 2, 2, 1, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2
Offset: 0

Views

Author

Philippe Deléham, Feb 24 2014

Keywords

Comments

Row sums are A005408(n).
Diagonals sums are A109613(n).
Sum_{k=0..n} T(n,k)*x^k = A033999(n), A000012(n), A005408(n), A036563(n+2), A058481(n+1), A083584(n), A137410(n), A233325(n), A233326(n), A233328(n), A211866(n+1), A165402(n+1) for x = -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 respectively.
Sum_{k=0..n} T(n,k)*x^(n-k) = A151575(n), A000012(n), A040000(n), A005408(n), A033484(n), A048473(n), A020989(n), A057651(n), A061801(n), A238275(n), A238276(n), A138894(n), A090843(n), A199023(n) for x = -2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11 respectively.
Sum_{k=0..n} T(n,k)^x = A000027(n+1), A005408(n), A016813(n), A017077(n) for x = 0, 1, 2, 3 respectively.
Sum_{k=0..n} k*T(n,k) = A002378(n).
Sum_{k=0..n} A000045(k)*T(n,k) = A019274(n+2).
Sum_{k=0..n} A000142(k)*T(n,k) = A066237(n+1).

Examples

			Triangle begins:
1;
1, 2;
1, 2, 2;
1, 2, 2, 2;
1, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2;
1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2;
...
		

Crossrefs

Cf. Diagonals: A040000.
Cf. Columns: A000012, A007395.
First differences of A001614.

Programs

Formula

T(n,0) = A000012(n) = 1, T(n+k,k) = A007395(n) = 2 for k>0.

Extensions

Data section extended to a(104) by Antti Karttunen, Jan 19 2025

A058482 Number of 3 X n binary matrices with no zero rows or columns.

Original entry on oeis.org

1, 25, 265, 2161, 16081, 115465, 816985, 5745121, 40294561, 282298105, 1976795305, 13839692881, 96884227441, 678208723945, 4747518463225, 33232801429441, 232630126566721, 1628412435648985, 11398891698588745, 79792255837258801, 558545832702224401
Offset: 1

Views

Author

Vladeta Jovovic, Nov 26 2000

Keywords

Crossrefs

Cf. A055602, A024206, A055609 (unlabeled case), A058481, column 3 of A183109 and A218695.

Programs

Formula

Number of m X n binary matrices with no zero rows or columns is Sum_{j=0..m}(-1)^j*C(m, j)*(2^(m-j)-1)^n.
a(n) = 7^n-3*3^n+3.
a(n) = 11*a(n-1)-31*a(n-2)+21*a(n-3). G.f.: -x*(21*x^2+14*x+1) / ((x-1)*(3*x-1)*(7*x-1)). - Colin Barker, Jul 10 2013

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Dec 04 2000
More terms from Colin Barker, Jul 10 2013

A080798 Largest prime factor of 3^n-2.

Original entry on oeis.org

7, 5, 79, 241, 727, 23, 937, 19681, 431, 499, 4703, 8093, 40193, 2869781, 483671, 94747, 4657, 232452293, 498112057, 2812679, 31381059607, 3765727153, 1364071, 44594137339, 125231, 13170403, 5353801183, 4159349, 46050353857, 294487079, 26892769, 29178816413, 3533781113
Offset: 2

Views

Author

Hugo Pfoertner, Mar 25 2003

Keywords

Crossrefs

Programs

  • Magma
    [Max(PrimeDivisors(3^n-2)):n in [2..30]]; // Marius A. Burtea, Jul 12 2019
  • Mathematica
    FactorInteger[#][[-1,1]]&/@(3^Range[2,30]-2) (* Harvey P. Dale, Apr 07 2022 *)
  • PARI
    a(n) = vecmax(factor(3^n-2)[,1]); \\ Michel Marcus, Jul 12 2019
    

Formula

a(n) = A006530(A058481(n)). - Michel Marcus, Jul 12 2019

A137410 a(n) = (5^n - 3)/2.

Original entry on oeis.org

-1, 1, 11, 61, 311, 1561, 7811, 39061, 195311, 976561, 4882811, 24414061, 122070311, 610351561, 3051757811, 15258789061, 76293945311, 381469726561, 1907348632811, 9536743164061, 47683715820311, 238418579101561, 1192092895507811, 5960464477539061, 29802322387695311, 149011611938476561
Offset: 0

Views

Author

Ctibor O. Zizka, Apr 15 2008

Keywords

Comments

Sequence is a(n) = a(n;5,3,1) where a(n;A,B,r) = (A^n - B^r)/(A - B) for arbitrary integers A, B, r with A != B.
Primes of this form are sometimes of interest, examples:
A=2, B=1, r=1 gives A000225 and subsequence of primes: A001348,
A=3, B=1, r=1 gives A003462 and subsequence of primes: A028491,
A=3, B=2, r=1 gives A058481 and subsequence of primes: A014224,
A=4, B=1, r=1 gives A002450,
A=4, B=2, r=1 gives A083420,
A=4, B=2, r=2 gives A002446,
A=5, B=1, r=1 gives A003463 and subsequence of primes: A004061,
A=5, B=2, r=1 gives A037577.
Sum of n-th row of triangle of powers of 5: 1; 5 1 5; 25 5 1 5 25; 125 25 5 1 5 25 125; ... (cf. Examples). - Philippe Deléham, Feb 24 2014
Integer solutions to x^5 - (x+1)^5 -(x+2)^5 +(x+3)^5 = 5^m + 5^n (see Campbell and Zujev). - Michel Marcus, Mar 02 2016

Examples

			From _Philippe Deléham_, Feb 24 2014: (Start)
a(1) = 1;
a(2) = 5 + 1 + 5 = 11;
a(3) = 25 + 5 + 1 + 5 + 25 = 61;
a(4) = 125 + 25 + 5 + 1 + 5 + 25 + 125 = 311;
etc. (End)
		

Crossrefs

Programs

Formula

a(n) = (5^n - 3)/2.
From Colin Barker, May 01 2012: (Start)
a(n) = 6*a(n-1) - 5*a(n-2).
G.f.: (-1+7*x)/((1-x)*(1-5*x)). (End)
a(n) = 5*a(n-1) + 6, a(1) = 1. - Philippe Deléham, Feb 24 2014
From Elmo R. Oliveira, Dec 11 2023: (Start)
a(n) = A024049(n)/2 - 1 = A125831(n) - 1.
E.g.f.: (1/2)*(exp(5*x) - 3*exp(x)). (End)

Extensions

More terms from Michel Marcus, Mar 02 2016
Edited and missing term a(0) inserted by M. F. Hasler, Jul 10 2018

A168589 a(n) = (2 - 3^n)*(-1)^n.

Original entry on oeis.org

1, 1, -7, 25, -79, 241, -727, 2185, -6559, 19681, -59047, 177145, -531439, 1594321, -4782967, 14348905, -43046719, 129140161, -387420487, 1162261465, -3486784399, 10460353201, -31381059607, 94143178825, -282429536479
Offset: 0

Views

Author

Klaus Brockhaus, Nov 30 2009

Keywords

Comments

A signed version of A058481 preceded by 1.

Crossrefs

Cf. A058481 (3^n-2).

Programs

  • Magma
    [ (2-3^n)*(-1)^n: n in [0..25] ];
    
  • Mathematica
    Table[(2 - 3^n)*(-1)^n, {n,0,50}] (* G. C. Greubel, Jul 26 2016 *)
  • PARI
    a(n)=(2-3^n)*(-1)^n \\ Charles R Greathouse IV, Jul 26 2016

Formula

a(n) = -4*a(n-1) - 3*a(n-2) for n > 1; a(0) = 1, a(1) = 1.
G.f.: (1 + 5*x)/((1+x)*(1+3*x)).
E.g.f.: 2*exp(-x) - exp(-3*x). - G. C. Greubel, Jul 26 2016

A002000 a(n+1) = a(n)*(a(n)^2 - 3) with a(0) = 7.

Original entry on oeis.org

7, 322, 33385282, 37210469265847998489922, 51522323599677629496737990329528638956583548304378053615581043535682
Offset: 0

Views

Author

Keywords

References

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

Crossrefs

Programs

  • Magma
    [n eq 1 select 7 else Self(n-1)^3 - 3*Self(n-1): n in [1..6]]; // Vincenzo Librandi, Feb 09 2017
  • Maple
    a := proc(n) option remember; if n = 0 then 7 else a(n-1)^3 - 3*a(n-1) end if; end;
    seq(a(n), n = 0..4); # Peter Bala, Nov 15 2022
  • Mathematica
    RecurrenceTable[{a[0] == 7, a[n] == a[n - 1]^3 - 3 a[n - 1]}, a, {n, 0, 8}]
    (* Vincenzo Librandi, Feb 09 2017 *)
    NestList[#(#^2-3)&,7,4] (* Harvey P. Dale, Aug 11 2021 *)

Formula

From Peter Bala, Feb 01 2017: (Start)
a(n) = ((7 + sqrt(45))/2)^(3^n) + ((7 - sqrt(45))/2)^(3^n).
a(n) = 2*T(3^n,7/2), where T(n,x) denotes the n-th Chebyshev polynomial of the first kind.
Product_{n >= 0} (1 + 2/(a(n) - 1)) = 3*sqrt(5)/5.
Cf. A001999 and A219161. (End)
From Peter Bala, Nov 15 2022: (Start)
a(n) = Lucas(4*(3^n)).
a(n+1) == a(n) (mod 3^(n+1)) (a particular case of the Gauss congruences for the Lucas numbers).
Conjecture: a(n+1) == a(n) (mod 3^(n+r+2)) for n >= r.
The least positive residue of a(n) mod(3^n) = 3^n - 2 = A058481(n). In the ring of 3-adic integers the limit_{n -> oo} a(n) exists and is equal to -2.
Product_{k = 0..n} (a(k) - 1) = (1/3)*Lucas(6*(3^n)). (End)

A108470 Table read by antidiagonals: T(n,k) = number of labeled partitions of (n,k) into pairs (i,j).

Original entry on oeis.org

1, 1, 1, 1, 3, 1, 1, 7, 7, 1, 1, 15, 25, 15, 1, 1, 31, 79, 79, 31, 1, 1, 63, 241, 339, 241, 63, 1, 1, 127, 727, 1351, 1351, 727, 127, 1, 1, 255, 2185, 5235, 6721, 5235, 2185, 255, 1, 1, 511, 6559, 20119, 31831, 31831, 20119, 6559, 511, 1, 1, 1023, 19681, 77379
Offset: 1

Views

Author

Christian G. Bower, Jun 03 2005

Keywords

Comments

Partitions of n black objects labeled 1..n and n white objects labeled 1..n. Each partition must have at least one black object and at least one white object.

Examples

			1 1 1 1 1 ...
1 3 7 15 31 ...
1 7 25 79 241 ...
1 15 79 339 1351 ...
1 31 241 1351 6721 ...
		

Crossrefs

Cf. A108461. Columns 1-3: A000012, A000225, A058481. Main diagonal: A023997.

Programs

  • Maxima
    T(n,k):=sum(m!*stirling2(k,m)*stirling2(n-k+1,m),m,1,min(k,n-k+1)); /* Vladimir Kruchinin, Apr 11 2015 */
    
  • PARI
    antidiag(nn) = {for (n=1, nn, for (k=1, n, print1(sum(m=1, min(k, n-k+1), m!*stirling(k, m, 2)*stirling(n-k+1, m, 2)), ", "); ); print(););} \\ Michel Marcus, Apr 11 2015
    
  • PARI
    tabl(nn) = {default(seriesprecision, nn); for (n=1, nn, for (k=1, nn, print1(k!*polcoeff(polcoeff(n!*exp((exp(x)-1)*(exp(y)-1))+O(x^(n+1)), n, x), k, y), ", "); ); print(););} \\ Michel Marcus, Apr 11 2015

Formula

Double e.g.f.: exp((exp(x)-1)*(exp(y)-1)).
T(n,k) = Sum{m=1..min(k,n-k+1)} m!*stirling2(k,m)*stirling2(n-k+1,m). - Vladimir Kruchinin, Apr 11 2015

A193871 Square array T(n,k) = k^n - k + 1 read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 3, 1, 1, 7, 7, 1, 1, 15, 25, 13, 1, 1, 31, 79, 61, 21, 1, 1, 63, 241, 253, 121, 31, 1, 1, 127, 727, 1021, 621, 211, 43, 1, 1, 255, 2185, 4093, 3121, 1291, 337, 57, 1, 1, 511, 6559, 16381, 15621, 7771, 2395, 505, 73, 1, 1, 1023, 19681, 65533, 78121, 46651, 16801, 4089, 721, 91, 1
Offset: 1

Views

Author

Omar E. Pol, Aug 21 2011

Keywords

Comments

The columns give 1^n-0, 2^n-1, 3^n-2, 4^n-3, 5^n-4, etc.
The main diagonal gives A006091, which is a sequence related to the famous "coconuts" problem.

Examples

			Array begins:
  1,   1,    1,     1,     1,    1,    1,   1,   1,   1
  1,   3,    7,    13,    21,   31,   43,  57,  73
  1,   7,   25,    61,   121,  211,  337, 505
  1,  15,   79,   253,   621, 1291, 2395
  1,  31,  241,  1021,  3121, 7771
  1,  63,  727,  4093, 15621
  1, 127, 2185, 16381
  1, 255, 6559
  1, 511
  1
		

Crossrefs

Row 1: A000012. Rows 2,3: A002061, A061600 but both without repetitions.
Cf. A276135.

Programs

  • Mathematica
    Table[k^# - k + 1 &[n - k + 1], {n, 11}, {k, n}] // Flatten (* Michael De Vlieger, Nov 16 2016 *)
Previous Showing 11-20 of 27 results. Next