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 25 results. Next

A153234 a(n) = floor(2^n/9).

Original entry on oeis.org

0, 0, 0, 0, 1, 3, 7, 14, 28, 56, 113, 227, 455, 910, 1820, 3640, 7281, 14563, 29127, 58254, 116508, 233016, 466033, 932067, 1864135, 3728270, 7456540, 14913080, 29826161, 59652323, 119304647, 238609294, 477218588, 954437176, 1908874353, 3817748707, 7635497415, 15270994830
Offset: 0

Views

Author

Paul Curtz, Dec 21 2008

Keywords

Comments

Partial sums of A113405. - Mircea Merca, Dec 28 2010
Dubickas proves that infinitely many terms of this sequence are composite. - Charles R Greathouse IV, Feb 04 2016
Parity from a(4) onward gives A088911 (Period 6: repeat [1, 1, 1, 0, 0, 0]). - Jeremy Gardiner, Nov 04 2020

Crossrefs

Cf. A113405.

Programs

Formula

a(n+1) - 2*a(n) = A088911(n+3).
a(n) + a(n+3) = 2^n - 1 = A000225(n), n > 0.
From Mircea Merca, Dec 28 2010: (Start)
a(n) = round((2*2^n-9)/18) = floor((2^n-1)/9) = ceiling((2^n-8)/9).
a(n) = a(n-6) + 7*2^(n-6), n > 5. (End)
a(n) = 3*a(n-1) - 2*a(n-2) - a(n-3) + 3*a(n-4) - 2*a(n-5).
G.f.: x^4 / ( (1-2*x)*(1-x^2)*(1-x+x^2) ).
a(n) + a(n+1) = A111927(n). - R. J. Mathar, Apr 08 2013

Extensions

More terms from Vincenzo Librandi, Jun 25 2011

A174341 a(n) = Numerator of Bernoulli(n, 1) + 1/(n+1).

Original entry on oeis.org

2, 1, 1, 1, 1, 1, 1, 1, 7, 1, 1, 1, -37, 1, 37, 1, -211, 1, 2311, 1, -407389, 1, 37153, 1, -1181819909, 1, 76977929, 1, -818946931, 1, 277930363757, 1, -84802531453217, 1, 90219075042851, 1, -711223555487930419, 1, 12696640293313423, 1, -6367871182840222481, 1, 35351107998094669831, 1, -83499808737903072705023, 1, 12690449182849194963361, 1
Offset: 0

Views

Author

Paul Curtz, Mar 16 2010

Keywords

Comments

a(n) is numerator of (A164555(n)/A027642(n) + 1/(n+1)).
1/(n+1) and Bernoulli(n,1) are autosequences in the sense that they remain the same (up to sign) under inverse binomial transform. This feature is kept for their sum, a(n)/A174342(n) = 2, 1, 1/2, 1/4, 1/6, 1/6, 1/6, 1/8, 7/90, 1/10, ...
Similar autosequences are also A000045, A001045, A113405, A000975 preceded by two zeros, and A140096.
Conjecture: the numerator of (A164555(n)/(n+1) + A027642(n)/(n+1)^2) is a(n) and the denominator of this fraction is equal to 1 if and only if n+1 is prime or 1. Cf. A309132. - Thomas Ordowski, Jul 09 2019
The "if" part of the conjecture is true: see the theorems in A309132 and A326690. The values of the numerator when n+1 is prime are A327033. - Jonathan Sondow, Aug 15 2019

Crossrefs

Programs

  • Magma
    [2,1] cat [Numerator(Bernoulli(n)+1/(n+1)): n in [2..40]]; // Vincenzo Librandi, Jul 18 2019
  • Maple
    A174341 := proc(n) bernoulli(n,1)+1/(n+1); numer(%) end proc: # R. J. Mathar, Nov 19 2010
  • Mathematica
    a[n_] := Numerator[BernoulliB[n, 1] + 1/(n + 1)];
    Table[a[n], {n, 0, 47}] (* Peter Luschny, Jul 13 2019 *)
  • PARI
    B(n)=if(n!=1, bernfrac(n), -bernfrac(n));
    a(n)=numerator(B(n) + 1/(n + 1));
    for(n=0, 50, print1(a(n),", ")) \\ Indranil Ghosh, Jun 19 2017
    
  • PARI
    a(n)=numerator(bernpol(n, 1) + 1/(n + 1)); \\ Michel Marcus, Jun 26 2025
    
  • Python
    from sympy import bernoulli, Integer
    def a(n): return (bernoulli(n) + 1/Integer(n + 1)).numerator # Indranil Ghosh, Jun 19 2017
    

Extensions

Reformulation of the name by Peter Luschny, Jul 13 2019

A131090 First differences of A131666.

Original entry on oeis.org

0, 1, 0, 1, 1, 4, 7, 15, 28, 57, 113, 228, 455, 911, 1820, 3641, 7281, 14564, 29127, 58255, 116508, 233017, 466033, 932068, 1864135, 3728271, 7456540, 14913081, 29826161, 59652324, 119304647, 238609295, 477218588, 954437177, 1908874353
Offset: 0

Views

Author

Paul Curtz, Sep 24 2007

Keywords

Comments

The first differences b(n)=a(n+1)-a(n) obey the recurrence b(n+1)-2b(n) = (-3,3,-2,3,-3,2), continued with period 6.
The 2nd differences c(n)=b(n+1)-b(n) obey the recurrence c(n+1)-2c(n) = (6,-5,5,-6,5,-5), periodically continued with period 6.
The hexaperiodic coefficients in these recurrences for A113405, A131666 and their higher order differences define a table,
0, 0, 1, 0, 0, -1 <- A113405
0, 1, -1, 0, -1, 1 <- A131666
1, -2, 1, -1, 2, -1 <- a(n)
-3, 3, -2, 3, -3, 2 <- b(n)
6, -5, 5, -6, 5, -5 <- c(n)
-11,10,-11, 11,-10, 11
21,-21,22,-21, 21,-22
...
in which the first three columns are A024495, A131708 and A024493, multiplied by a checkerboard pattern of signs.

Programs

  • Mathematica
    LinearRecurrence[{2,0,-1,2},{0,1,0,1},40] (* Harvey P. Dale, Jan 15 2016 *)

Formula

a(n) = A131666(n+1)-A131666(n).
a(n+1)-2a(n) = A131556(n), a sequence with period length 6.
G.f.: -(x-1)^2*x / ((x+1)*(2*x-1)*(x^2-x+1)). - Colin Barker, Mar 04 2013

Extensions

Edited by R. J. Mathar, Jun 28 2008

A242563 a(n) = 2*a(n-1) - a(n-3) + 2*a(n-4), a(0)=a(1)=0, a(2)=2, a(3)=3.

Original entry on oeis.org

0, 0, 2, 3, 6, 10, 21, 42, 86, 171, 342, 682, 1365, 2730, 5462, 10923, 21846, 43690, 87381, 174762, 349526, 699051, 1398102, 2796202, 5592405, 11184810, 22369622, 44739243, 89478486, 178956970, 357913941, 715827882, 1431655766, 2863311531, 5726623062, 11453246122
Offset: 0

Views

Author

Paul Curtz, May 17 2014

Keywords

Comments

Generally, a(n) is an autosequence if its inverse binomial transform is (-1)^n*a(n). It is of the first kind if the main diagonal is 0's and the first two upper diagonals (just above the main one) are the same. It is of the second kind if the main diagonal is equal to the first upper diagonal multiplied by 2. If the first upper diagonal is an autosequence, the sequence is a super autosequence. Example: A113405. The first upper diagonal is A001045(n). Another super autosequence: 0, 0, 0 followed by A059633(n). The first upper diagonal is A000045(n).
Difference table of a(n):
0, 0, 2, 3, 6, 10, 21, 42, ...
0, 2, 1, 3, 4, 11, 21, 44, ...
2, -1, 2, 1, 7, 10, 23, 41, ...
-3, 3, -1, 6, 3, 13, 18, 45, ... .
This is an autosequence of the second kind. The main diagonal is 2*A001045(n) = A078008(n). More precisely it is a super autosequence, companion of A113405(n).
a(n+1) mod 10 = period 12: repeat 0, 2, 3, 6, 0, 1, 2, 6, 1, 2, 2, 5.
It is shifted A081374(n+1) mod 10 =
period 12: repeat 1, 2, 2, 5, 0, 2, 3, 6, 0, 1, 2, 6.
a(n) mod 9 = period 18:
repeat 0, 0, 2, 3, 6, 1, 3, 6, 5, 0, 0, 7, 6, 3, 8, 6, 3, 4 = c(n).
c(n) + c(n+9) = 0, 0, 9, 9, 9, 9, 9, 9, 9.

Examples

			G.f. = 2*x^2 + 3*x^3 + 6*x^4 + 10*x^5 + 21*x^6 + 42*x^7 + 86*x^8 + ...
		

Crossrefs

Cf. A000032, 1/(n+1), A164555/A027642 (all autosequences of 2nd kind). A007283, A175805.

Programs

  • Mathematica
    a[n_] := (m = Mod[n, 6]; 1/3*(2^n + (-1)^n + 1/120*(m-6)*(m+1)*(m^3-29*m+40))); Table[a[n], {n, 0, 35}] (* Jean-François Alcover, May 19 2014, a non-recursive formula, after Mathematica's RSolve *)
    LinearRecurrence[{2, 0, -1, 2}, {0, 0, 2, 3},50] (* G. C. Greubel, Feb 21 2017 *)
  • PARI
    concat([0,0], Vec(x^2*(x-2)/((x+1)*(2*x-1)*(x^2-x+1)) + O(x^100))) \\ Colin Barker, May 18 2014

Formula

a(n+3) = 3*2^n - a(n), a(0)=a(1)=0, a(2)=2.
a(n) = 2*A113405(n+1) - A113405(n).
a(n+1) = 2*a(n) + period 6: repeat 0, 2, -1, 0, -2, 1. a(0)=0.
a(n) = 2^n - A081374(n+1).
a(n+3) = a(n+1) + A130755(n).
G.f.: x^2*(x-2) / ((x+1)*(2*x-1)*(x^2-x+1)). - Colin Barker, May 18 2014
a(n) = A024495(n) + A131531(n).
a(n+6) = a(n) + 21*2^n, a(0)=a(1)=0, a(2)=2, a(3)=3, a(4)=6, a(5)=10.
a(n) = A001045(n) - A092220(n).
a(n+12) = a(n) + 1365*2^n. First 12 values in the Data. (A024495(n+12) = A024495(n) + 1365*2^n).
a(3n) = A132805(n) = 3*A015565(n).
a(3n+1) = A132804(n) = 6*A015565(n).
a(3n+2) = A132397(n) = 2*A082311(n).
a(n) = 1/3*((-1)^n - 2*cos((n*Pi)/3) + 2^n). - Alexander R. Povolotsky, Jun 02 2014

Extensions

More terms from Colin Barker, May 18 2014

A191597 Expansion of x*(1+3*x)/ ( (1-4*x)*(1+x+x^2)).

Original entry on oeis.org

0, 1, 6, 21, 85, 342, 1365, 5461, 21846, 87381, 349525, 1398102, 5592405, 22369621, 89478486, 357913941, 1431655765, 5726623062, 22906492245, 91625968981, 366503875926, 1466015503701, 5864062014805, 23456248059222, 93824992236885, 375299968947541
Offset: 0

Views

Author

Paul Curtz, Jun 08 2011

Keywords

Comments

a(n) and successive differences define a square array T(0,k) = a(k), T(n,k) = T(n-1,k+1) - T(n-1,k):
0, 1, 6, 21, 85, 342,...
1, 5, 15, 64, 257, 1023,...
4, 10, 49, 193, 766, 3073,...
As with any sequence which obeys a homogeneous linear recurrence (we say it once, only once and we shall not repeat it), the recurrence is also valid for the rows of such arrays of higher order differences.

Programs

Formula

a(n) = 3*a(n-1) + 3*a(n-2) + 4*a(n-3), n >= 3.
a(n) = A024495(2*n).
a(n) = A113405(2*n) + A113405(2*n+1).
a(n+1) - 4*a(n) = A132677(n).
a(n+3) - a(n) = 21*4^n.
a(n) = A178872(n) + 3*A178872(n-1) = (4^n-A061347(n+1))/3. - R. J. Mathar, Jun 08 2011

A348405 a(0) = 1, a(n) + a(n+1) = round(2^n/9), n >= 0.

Original entry on oeis.org

1, -1, 1, -1, 2, 0, 4, 3, 11, 17, 40, 74, 154, 301, 609, 1211, 2430, 4852, 9712, 19415, 38839, 77669, 155348, 310686, 621382, 1242753, 2485517, 4971023, 9942058, 19884104, 39768220, 79536427, 159072867, 318145721, 636291456, 1272582898, 2545165810
Offset: 0

Views

Author

Paul Curtz, Oct 17 2021

Keywords

Crossrefs

Cf. A139797 (a(n) + a(n+1) = round(2^n/9) too, but a(0) = 0).

Programs

  • Mathematica
    CoefficientList[ Series[(x^4-x^3+2x-1)/((2*x^3-3*x^2+3*x-1)*(x+1)^2), {x, 0, 40}], x] (* Thomas Scheuerle, Oct 17 2021 *)
    nxt[{n_,a_}]:={n+1,Round[(2^n)/9]-a}; NestList[nxt,{0,1},40][[All,2]] (* or *) LinearRecurrence[{1,2,-1,1,2},{1,-1,1,-1,2},40] (* Harvey P. Dale, Apr 28 2022 *)

Formula

a(n+1) = 2*a(n) - A104581(n+6).
a(n) + a(n+1) = A113405(n).
a(n) + a(n+3) = A001045(n).
a(n+2) = a(n) + A131666(n).
From Thomas Scheuerle, Oct 18 2021: (Start)
G.f.: (x^4-x^3+2x-1)/((2*x^3-3*x^2+3*x-1)*(x+1)^2).
A172481(n) = Sum_{k=0..n} (-1)^(n-k)*binomial(n, k)*a(2*n-k). With negative sign for ...*a(1+2*n-k) and ...*a(3+2*n-k) too.
A175656(n) = Sum_{k=0..n} (-1)^(n-k)*binomial(n, k)*a(2+2*n-k).
A136298(n+1) = Sum_{k=0..n} (-1)^(n-k)*binomial(n, k)*a(4+2*n-k).
A348407(n) = Sum_{k=0..n} (-1)^(n-k)*binomial(n, k)*(a(2+2*n-k) - 2*a(1+2*n-k) - a(2*n-k)).
(End)

Extensions

a(22)-a(36) from Thomas Scheuerle, Oct 17 2021

A132780 a(0)=1. a(n+1)=2*a(n)-A130151(n).

Original entry on oeis.org

1, 1, 1, 1, 3, 7, 15, 29, 57, 113, 227, 455, 911, 1821, 3641, 7281, 14563, 29127, 58255, 116509, 233017, 466033, 932067, 1864135, 3728271, 7456541, 14913081, 29826161, 59652323, 119304647, 238609295, 477218589, 954437177, 1908874353, 3817748707
Offset: 0

Views

Author

Paul Curtz, Nov 17 2007

Keywords

Comments

The first member of the sequences of the d'-th differences (that is, the diagonal of the pyramidal arrangement of repeated differences and essentially the binomial transform of 2*A113405) has the same absolute value as the first differences themselves, cf. the comment in A113405.

Programs

  • Mathematica
    nxt[{n_,a_}]:={n+1,If[MemberQ[{1,2,3},Mod[n+1,6]],2a-1,2a+1]}; NestList[ nxt, {0,1},40][[All,2]] (* Harvey P. Dale, Jul 06 2019 *)

Formula

First differences: a(n+1)-a(n)= 2*A113405(n).
O.g.f.: (1-x-x^2)/((1+x)(1-x+x^2)(1-2x)). - R. J. Mathar, Jul 16 2008

Extensions

Edited and extended by R. J. Mathar, Jul 16 2008

A135258 Inverse binomial transform of A131666 after removing A131666(0) = 0.

Original entry on oeis.org

0, 1, -1, 2, -3, 7, -14, 29, -57, 114, -227, 455, -910, 1821, -3641, 7282, -14563, 29127, -58254, 116509, -233017, 466034, -932067, 1864135, -3728270, 7456541, -14913081, 29826162, -59652323, 119304647, -238609294, 477218589, -954437177, 1908874354
Offset: 0

Views

Author

Paul Curtz, Dec 01 2007

Keywords

Comments

The inverse binomial transform generally equals the sequence of first terms of the iterated differences (i.e., equals the diagonal of the arrangement in the standard hand-written display of the differences).

Crossrefs

Cf. A113405.

Programs

  • Mathematica
    LinearRecurrence[{-2, 0, 1, 2}, {0, 1, -1, 2}, 50] (* G. C. Greubel, Oct 04 2016 *)
  • PARI
    concat(0, Vec(x*(1 + x)/((x^2 +x +1)*(1 +2*x)*(1-x)) + O(x^50))) \\ Michel Marcus, Oct 05 2016

Formula

O.g.f.: x*(1 + x)/((x^2 +x +1)*(1 +2*x)*(1-x)). - R. J. Mathar, Jul 22 2008
a(n) = -2*a(n-1) + a(n-3) + 2*a(n-4). - G. C. Greubel, Oct 04 2016

Extensions

Edited and corrected by R. J. Mathar, Jul 22 2008

A166578 a(n) = a(n-3) + 2^(n-4) with a(1) = 1, a(2) = 2, a(3) = 1.

Original entry on oeis.org

1, 2, 1, 2, 4, 5, 10, 20, 37, 74, 148, 293, 586, 1172, 2341, 4682, 9364, 18725, 37450, 74900, 149797, 299594, 599188, 1198373, 2396746, 4793492, 9586981, 19173962, 38347924, 76695845, 153391690, 306783380, 613566757, 1227133514, 2454267028
Offset: 0

Views

Author

Paul Curtz, Oct 17 2009

Keywords

Comments

a(n) and successive differences: 1,1,2,1,2,4,5,10,20,37; 0,1,-1,1,2,1,5,10,17,37; 1,-2,2,1,-1,4,5,7,20,37; -3,4,-1,-2,5,1,2,13,17,34; 7,-5,-1,7,-4,1,11,4,17,43; -12,4,8,-11,5,10,-7,13,26,25; Rows must be taken by pairs (companions because a(n)-a(n-3) alternatively gives A131577 and A011782 also companions). Note a(3n+2)=2*a(3n+1)=4*a(3n), n positive; see A113405. Sum of consecutive three terms of even rows gives 0,4,32,256.

Programs

  • Mathematica
    RecurrenceTable[{a[1]==1,a[2]==2,a[3]==1,a[n]==a[n-3]+2^(n-4)},a[n],{n,40}] (* or *) LinearRecurrence[{2,0,1,-2},{1,2,1,2},40] (* Harvey P. Dale, Sep 14 2011 *)
  • PARI
    Vec((1-3*x^2-x^3)/(1-2*x-x^3+2*x^4)+O(x^99)) \\ Charles R Greathouse IV, Jan 25 2012

Formula

For n > 4, a(n) = 2a(n-1) + a(n-3) - 2a(n-4).
a(3n) = (8^n - 8)/14 + 1, a(3n-1) = (8^n - 8)/28 + 2, a(3n-2) = (8^n - 8)/56 + 1.
G.f.: (1-3*x^2-x^3)/(1-2*x-x^3+2*x^4). - Colin Barker, Jan 25 2012

Extensions

Edited by Charles R Greathouse IV, Nov 04 2009

A191370 a(n) = 2*(1+(-1)^n)/3 + 2*A010892(n-1).

Original entry on oeis.org

1, 2, 4, 2, 4, 8, 22, 44, 88, 170, 340, 680, 1366, 2732, 5464, 10922, 21844, 43688, 87382, 174764, 349528, 699050, 1398100, 2796200, 5592406, 11184812, 22369624, 44739242
Offset: 0

Views

Author

Paul Curtz, Jun 01 2011

Keywords

Comments

a(n) and successive differences define an infinite array:
1, 2, 4, 2, 4, 8, ...
1, 2, -2, 2, 4, 14, ...
1, -4, 4, 2, 10, 8, ...
-5, 8, -2, 8, -2, 14, ...
13, -10, 10, -10, 16, 2, ...
-23, 20, -20, 26, -14, 32, ...
...
Its main diagonal consists of the powers 2^n. The first upper diagonal is a signed sequence of 2's. The second upper diagonal contains essentially A135440.

Crossrefs

Programs

  • Maple
    A010892 := proc(n) op( 1+(n mod 6),[1,1,0,-1,-1,0]) ; end proc:
    A191370 := proc(n) 2^n/3+2*(-1)^n/3+2*A010892(n-1) ; end proc:
    seq(A191370(n),n=0..30) ; # R. J. Mathar, Jun 06 2011
  • Mathematica
    LinearRecurrence[{2,0,-1,2},{1,2,4,2},30] (* Harvey P. Dale, Sep 06 2022 *)

Formula

a(n+3) = 3*2^n - a(n), n >= 0.
a(n+1) - 2*a(n) = -6*A131531(n+1).
a(3*n) = A007613(n), a(1+3*n) = 2*A007613(n), a(2+3*n) = 4*A007613(n).
a(n+6) = a(n) + 21*2^n.
a(n) = ((2^n + 2*(-1)^n)*2^n - 2*i*sqrt(3)*((1+i*sqrt(3))^n - (1-i*sqrt(3))^n))/(3*2^n), where i=sqrt(-1); a(n+1) = 2*(A001045(n) + A010892(n)). - Bruno Berselli, Jun 06 2011
G.f.: ( -1+5*x^3 ) / ( (2*x-1)*(1+x)*(x^2-x+1) ). - R. J. Mathar, Jun 06 2011
a(n) = 2*a(n-1) - a(n-3) + 2*a(n-4). - Paul Curtz, Jun 07 2011
a(n) = A113405(n+3) - 5*A113405(n). - R. J. Mathar, Jun 24 2011
Previous Showing 11-20 of 25 results. Next