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

A130487 a(n) = Sum_{k=0..n} (k mod 9) (Partial sums of A010878).

Original entry on oeis.org

0, 1, 3, 6, 10, 15, 21, 28, 36, 36, 37, 39, 42, 46, 51, 57, 64, 72, 72, 73, 75, 78, 82, 87, 93, 100, 108, 108, 109, 111, 114, 118, 123, 129, 136, 144, 144, 145, 147, 150, 154, 159, 165, 172, 180, 180, 181, 183, 186, 190, 195, 201, 208, 216, 216, 217, 219, 222, 226
Offset: 0

Views

Author

Hieronymus Fischer, May 31 2007

Keywords

Comments

Let A be the Hessenberg n X n matrix defined by A[1,j]=j mod 9, A[i,i]:=1, A[i,i-1]=-1. Then, for n >= 1, a(n)=det(A). - Milan Janjic, Jan 24 2010

Crossrefs

Programs

  • GAP
    a:=[0,1,3,6,10,15,21,28,36,36];; for n in [11..71] do a[n]:=a[n-1]+a[n-9]-a[n-10]; od; a; # G. C. Greubel, Aug 31 2019
  • Magma
    I:=[0,1,3,6,10,15,21,28,36,36]; [n le 10 select I[n] else Self(n-1) + Self(n-9) - Self(n-10): n in [1..71]]; // G. C. Greubel, Aug 31 2019
    
  • Maple
    seq(coeff(series(x*(1-9*x^8+8*x^9)/((1-x^9)*(1-x)^3), x, n+1), x, n), n = 0 .. 70); # G. C. Greubel, Aug 31 2019
  • Mathematica
    Accumulate[PadRight[{},120,Range[0,8]]] (* Harvey P. Dale, Dec 19 2018 *)
    Accumulate[Mod[Range[0,100],9]] (* Harvey P. Dale, Oct 16 2021 *)
  • PARI
    a(n) = sum(k=0, n, k % 9); \\ Michel Marcus, Apr 28 2018
    
  • Sage
    def A130487_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P(x*(1-9*x^8+8*x^9)/((1-x^9)*(1-x)^3)).list()
    A130487_list(70) # G. C. Greubel, Aug 31 2019
    

Formula

a(n) = 36*floor(n/9) + A010878(n)*(A010878(n) + 1)/2.
G.f.: (Sum_{k=1..8} k*x^k)/((1-x^9)*(1-x)).
G.f.: x*(1 - 9*x^8 + 8*x^9)/((1-x^9)*(1-x)^3).

A010883 Simple periodic sequence: repeat 1,2,3,4.

Original entry on oeis.org

1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1
Offset: 0

Views

Author

Keywords

Comments

Partial sums are given by A130482(n) + n + 1. - Hieronymus Fischer, Jun 08 2007
1234/9999 = 0.123412341234... - Eric Desbiaux, Nov 03 2008

Crossrefs

Cf. A177037 (decimal expansion of (9+2*sqrt(39))/15). - Klaus Brockhaus, May 01 2010

Programs

Formula

a(n) = 1 + (n mod 4). - Paolo P. Lava, Nov 21 2006
From Hieronymus Fischer, Jun 08 2007: (Start)
a(n) = A010873(n) + 1.
Also a(n) = (1/2)*(5 - (-1)^n - 2*(-1)^((2*n - 1 + (-1)^n)/4)).
G.f.: g(x) = (4*x^3 + 3*x^2 + 2*x + 1)/(1 - x^4) = (4*x^5 - 5*x^4 + 1)/((1 - x^4)*(1-x)^2). (End)
a(n) = 5/2 - cos(Pi*n/2) - sin(Pi*n/2) - (-1)^n/2. - R. J. Mathar, Oct 08 2011

A099548 Odd part of n modulo 7.

Original entry on oeis.org

1, 1, 3, 1, 5, 3, 0, 1, 2, 5, 4, 3, 6, 0, 1, 1, 3, 2, 5, 5, 0, 4, 2, 3, 4, 6, 6, 0, 1, 1, 3, 1, 5, 3, 0, 2, 2, 5, 4, 5, 6, 0, 1, 4, 3, 2, 5, 3, 0, 4, 2, 6, 4, 6, 6, 0, 1, 1, 3, 1, 5, 3, 0, 1, 2, 5, 4, 3, 6, 0, 1, 2, 3, 2, 5, 5, 0, 4, 2, 5, 4, 6, 6, 0, 1, 1, 3, 4, 5, 3, 0, 2, 2, 5, 4, 3, 6, 0, 1, 4, 3, 2
Offset: 1

Views

Author

Ralf Stephan, Oct 23 2004

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Mod[n / 2^IntegerExponent[n, 2], 7]; Array[a, 100] (* Amiram Eldar, Aug 29 2024 *)
  • PARI
    a(n) = (n>>valuation(n, 2))%7 \\Charles R Greathouse IV, May 14 2014

Formula

a(n) = A010876(A000265(n)).
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = 3. - Amiram Eldar, Aug 29 2024

A130488 a(n) = Sum_{k=0..n} (k mod 10) (Partial sums of A010879).

Original entry on oeis.org

0, 1, 3, 6, 10, 15, 21, 28, 36, 45, 45, 46, 48, 51, 55, 60, 66, 73, 81, 90, 90, 91, 93, 96, 100, 105, 111, 118, 126, 135, 135, 136, 138, 141, 145, 150, 156, 163, 171, 180, 180, 181, 183, 186, 190, 195, 201, 208, 216, 225, 225, 226, 228, 231, 235, 240, 246, 253
Offset: 0

Views

Author

Hieronymus Fischer, May 31 2007

Keywords

Comments

Let A be the Hessenberg n X n matrix defined by A[1,j] = j mod 10, A[i,i]:=1, A[i,i-1]=-1. Then, for n >= 1, a(n)=det(A). - Milan Janjic, Jan 24 2010

Crossrefs

Programs

  • GAP
    a:=[0,1,3,6,10,15,21,28,36,45,45];; for n in [12..61] do a[n]:=a[n-1]+a[n-10]-a[n-11]; od; a; # G. C. Greubel, Aug 31 2019
    
  • Magma
    I:=[0,1,3,6,10,15,21,28,36,45,45]; [n le 11 select I[n] else Self(n-1) + Self(n-10) - Self(n-11): n in [1..61]]; // G. C. Greubel, Aug 31 2019
    
  • Maple
    seq(coeff(series(x*(1-10*x^9+9*x^10)/((1-x^10)*(1-x)^3), x, n+1), x, n), n = 0..60); # G. C. Greubel, Aug 31 2019
  • Mathematica
    LinearRecurrence[{1,0,0,0,0,0,0,0,0,1,-1}, {0,1,3,6,10,15,21,28,36,45, 45}, 60] (* G. C. Greubel, Aug 31 2019 *)
  • PARI
    a(n) = sum(k=0, n, k % 10); \\ Michel Marcus, Apr 28 2018
    
  • Python
    def A130488(n):
        a, b = divmod(n,10)
        return 45*a+(b*(b+1)>>1) # Chai Wah Wu, Jul 27 2022
  • Sage
    def A130488_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P(x*(1-10*x^9+9*x^10)/((1-x^10)*(1-x)^3)).list()
    A130488_list(60) # G. C. Greubel, Aug 31 2019
    

Formula

a(n) = 45*floor(n/10) + A010879(n)*(A010879(n) + 1)/2.
G.f.: (Sum_{k=1..9} k*x^k)/((1-x^10)*(1-x)).
G.f.: x*(1 - 10*x^9 + 9*x^10)/((1-x^10)*(1-x)^3).

A070365 a(n) = 5^n mod 7.

Original entry on oeis.org

1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2, 3, 1, 5, 4, 6, 2
Offset: 0

Views

Author

N. J. A. Sloane, May 12 2002

Keywords

Comments

From Klaus Brockhaus, May 23 2010: (Start)
Period 6: repeat [1, 5, 4, 6, 2, 3].
Continued fraction expansion of (221+11*sqrt(1086))/490.
Decimal expansion of 199/1287.
First bisection is A153727. (End)

Crossrefs

Cf. A178229 (decimal expansion of (221+11*sqrt(1086))/490), A178141 (repeat 4, -1, 2, -4, 1, -2), A117373 (repeat 1, -2, -3, -1, 2, 3), A153727 (trajectory of 3x+1 sequence starting at 1).

Programs

  • Magma
    [Modexp(5, n, 7): n in [0..100]]; // Vincenzo Librandi, Mar 24 2016 - after Bruno Berselli
  • Maple
    A070365:=n->[1, 5, 4, 6, 2, 3][(n mod 6)+1]: seq(A070365(n), n=0..100); # Wesley Ivan Hurt, Jun 23 2016
  • Mathematica
    PowerMod[5, Range[0, 110], 7] (* or *) LinearRecurrence[{1, 0, -1, 1}, {1, 5, 4, 6}, 110] (* Harvey P. Dale, Apr 26 2011 *)
    Table[Mod[5^n, 7], {n, 0, 100}] (* G. C. Greubel, Mar 05 2016 *)
    PadRight[{}, 100, {1, 5, 4, 6, 2, 3}] (* or *) CoefficientList[Series[(1 + 5 x + 4 x^2 + 6 x^3 + 2 x^4 + 3 x^5) / (1 - x^6), {x, 0, 100}], x] (* Vincenzo Librandi, Mar 24 2016 *)
  • PARI
    a(n)=lift(Mod(5,7)^n) \\ Charles R Greathouse IV, Mar 22 2016
    

Formula

From R. J. Mathar, Apr 13 2010: (Start)
a(n) = a(n-1) - a(n-3) + a(n-4) for n>3.
G.f.: (1+4*x-x^2+3*x^3)/ ((1-x)*(1+x)*(x^2-x+1)). (End)
From Klaus Brockhaus, May 23 2010: (Start)
a(n+1)-a(n) = A178141(n).
a(n+2)-a(n) = A117373(n+5). (End)
From G. C. Greubel, Mar 05 2016: (Start)
a(n) = a(n-6) for n>5.
E.g.f.: (1/3)*(7*cosh(x) + 14*sinh(x) + 2*sqrt(3)*exp(x/2)*sin(sqrt(3)*x/2) - 4*exp(x/2)*cos(sqrt(3)*x/2)). (End)
a(n) = (21 - 7*cos(n*Pi) - 8*cos(n*Pi/3) + 4*sqrt(3)*sin(n*Pi/3))/6. - Wesley Ivan Hurt, Jun 23 2016
a(n) = A010876(A000351(n)). - Michel Marcus, Jun 27 2016

A010887 Simple periodic sequence: repeat 1,2,3,4,5,6,7,8.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1
Offset: 0

Views

Author

Keywords

Comments

Partial sums are given by A130486(n)+n+1. - Hieronymus Fischer, Jun 08 2007
1371742/11111111 = 0.123456781234567812345678... - Eric Desbiaux, Nov 03 2008

Crossrefs

Cf. A177034 (decimal expansion of (9280+3*sqrt(13493990))/14165). - Klaus Brockhaus, May 01 2010

Programs

  • Haskell
    a010887 = (+ 1) . flip mod 8
    a010887_list = cycle [1..8]
    -- Reinhard Zumkeller, Nov 09 2014, Mar 04 2014
    
  • Mathematica
    PadRight[{},90,Range[8]] (* Harvey P. Dale, May 10 2022 *)
  • Python
    def A010887(n): return 1 + (n & 7) # Chai Wah Wu, May 25 2022

Formula

a(n) = 1 + (n mod 8) - Paolo P. Lava, Nov 21 2006
From Hieronymus Fischer, Jun 08 2007: (Start)
a(n) = (1/2)*(9 - (-1)^n - 2*(-1)^(b/4) - 4*(-1)^((b - 2 + 2*(-1)^(b/4))/8)) where b = 2n - 1 + (-1)^n.
Also a(n) = A010877(n) + 1.
G.f.: g(x) = (1/(1-x^8))*Sum_{k=0..7} (k+1)*x^k.
Also: g(x) = (8x^9 - 9x^8 + 1)/((1-x^8)*(1-x)^2). (End)

A204453 Period length 14: [0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1] repeated.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5, 6, 0, 6, 5, 4, 3, 2, 1, 0, 1, 2, 3, 4, 5
Offset: 0

Views

Author

Wolfdieter Lang, Jan 17 2012

Keywords

Comments

This sequence can be continued periodically for negative values of n, and then a(-n) = a(n).
This is the seventh sequence of a k-family of sequences P_k, k>=1, which starts with A000007(n+1), n>=0, (the 0-sequence), A000035, A193680, A193682, A203572, A for k=1..6, respectively.
See a comment on A203571 for the general case of the P_k sequences. For a(n)=P_7(n) the nonnegative members of the equivalence classes [0], [1],...,[6], defined by p==q iff P_7(p)=P_7(q), are found in the array A113807 if there the last class [7], starting with 7, is replaced by 0,7,14,..., to become the first class [0] (nonnegative part).

Examples

			a(16) = 16(mod 7) = 2 because 16\7 = floor(16/7)=2 is even; the sign is +1.
a(9) = (7-9)(mod 7) = 5 because 9\7 = floor(9/7)=1 is odd; the sign is -1.
		

Crossrefs

Cf. A203572 (k=6), A113807, A010876.

Formula

a(n) = n(mod 7) if (-1)^floor(n/7)=+1 else (7-n)(mod 7), n>=0. (-1)^floor(n/7) is the sign corresponding to the parity of the quotient floor(n/7). This quotient is sometimes denoted by n\7.
O.g.f.: x*(1+2*x+3*x^2+4*x^3+5*x^4+6*x^5+6*x^7+5*x^8+4*x^9+ 3*x^10+2*x^11+x^12)/(1-x^14).
a(n) = (7*m*(m^4-21*m^3+175*m^2-735*m+1624)*((-1)^floor(n/7)-1)-10908*(-1)^floor(n/7)+12348)*m/1440 where m = n-7*floor(n/7). - Luce ETIENNE, Oct 13 2017

A060154 Table T(n,k) by antidiagonals of n^k mod k [n,k >= 1].

Original entry on oeis.org

0, 1, 0, 1, 0, 0, 1, 2, 1, 0, 1, 0, 0, 0, 0, 1, 2, 1, 1, 1, 0, 1, 4, 3, 0, 2, 0, 0, 1, 2, 3, 4, 1, 0, 1, 0, 1, 0, 3, 4, 0, 0, 1, 0, 0, 1, 8, 1, 4, 1, 1, 1, 2, 1, 0, 1, 4, 0, 0, 5, 0, 2, 0, 0, 0, 0, 1, 2, 9, 1, 1, 6, 1, 3, 1, 1, 1, 0, 1, 4, 3, 6, 8, 0, 0, 4, 4, 0, 2, 0, 0, 1, 2, 9, 4, 5, 0, 1, 1, 3, 0, 1, 0, 1, 0
Offset: 1

Views

Author

Henry Bottomley, Mar 12 2001

Keywords

Examples

			T(5,3) = 5^3 mod 3 = 125 mod 3 = 2.
Rows start:
  0, 1, 1, 1, 1, ...
  0, 0, 2, 0, 2, ...
  0, 1, 0, 1, 3, ...
  0, 0, 1, 0, 4, ...
  0, 1, 2, 1, 0, ...
		

Crossrefs

Rows include A057427, A015910, A056969.
Columns include A000004, A000035 (several times), A010872, A010874, A010876, A021559 and other periodic sequences.
Diagonals include A000004 and A057427.
Cf. A114448.

Formula

T(n, k) = A051129(n, k)-n*A060155(n, k).

A130489 a(n) = Sum_{k=0..n} (k mod 11) (Partial sums of A010880).

Original entry on oeis.org

0, 1, 3, 6, 10, 15, 21, 28, 36, 45, 55, 55, 56, 58, 61, 65, 70, 76, 83, 91, 100, 110, 110, 111, 113, 116, 120, 125, 131, 138, 146, 155, 165, 165, 166, 168, 171, 175, 180, 186, 193, 201, 210, 220, 220, 221, 223, 226, 230, 235, 241, 248, 256, 265, 275, 275, 276
Offset: 0

Views

Author

Hieronymus Fischer, May 31 2007

Keywords

Comments

Let A be the Hessenberg n X n matrix defined by A[1,j] = j mod 11, A[i,i]:=1, A[i,i-1]=-1. Then, for n >= 1, a(n)=det(A). - Milan Janjic, Jan 24 2010

Crossrefs

Programs

  • GAP
    a:=[0,1,3,6,10,15,21,28,36,45, 55,55];; for n in [13..61] do a[n]:=a[n-1]+a[n-11]-a[n-12]; od; a; # G. C. Greubel, Aug 31 2019
  • Magma
    I:=[0,1,3,6,10,15,21,28,36,45,55,55]; [n le 12 select I[n] else Self(n-1) + Self(n-11) - Self(n-12): n in [1..61]]; // G. C. Greubel, Aug 31 2019
    
  • Maple
    seq(coeff(series(x*(1-11*x^10+10*x^11)/((1-x^11)*(1-x)^3), x, n+1), x, n), n = 0 .. 60); # G. C. Greubel, Aug 31 2019
  • Mathematica
    LinearRecurrence[{1,0,0,0,0,0,0,0,0,0,1,-1}, {0,1,3,6,10,15,21,28,36,45, 55,55}, 60] (* G. C. Greubel, Aug 31 2019 *)
    Accumulate[PadRight[{},80,Range[0,10]]] (* Harvey P. Dale, Jul 21 2021 *)
  • PARI
    a(n) = sum(k=0, n, k % 11); \\ Michel Marcus, Apr 28 2018
    
  • Sage
    def A130489_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P(x*(1-11*x^10+10*x^11)/((1-x^11)*(1-x)^3)).list()
    A130489_list(60) # G. C. Greubel, Aug 31 2019
    

Formula

a(n) = 55*floor(n/11) + A010880(n)*(A010880(n) + 1)/2.
G.f.: (Sum_{k=1..10} k*x^k)/((1-x^11)*(1-x)).
G.f.: x*(1 - 11*x^10 + 10*x^11)/((1-x^11)*(1-x)^3).

A010885 Period 6: repeat [1, 2, 3, 4, 5, 6].

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3, 4, 5, 6, 1, 2, 3
Offset: 0

Views

Author

Keywords

Comments

Partial sums are given by A130484(n)+n+1. - Hieronymus Fischer, Jun 08 2007
41152/333333 = 0.123456123456123456... [Eric Desbiaux, Nov 03 2008]

Crossrefs

Cf. A177158 (decimal expansion of (103+2*sqrt(4171))/162). [From Klaus Brockhaus, May 03 2010]

Programs

Formula

a(n) = 1 + (n mod 6). - Paolo P. Lava, Nov 21 2006
a(n) = A010875(n)+1. G.f.: g(x)=(Sum_{0<=k<6} (k+1)*x^k)/(1-x^6). Also g(x)=(6*x^7-7*x^6+1)/((1-x^6)*(1-x)^2). - Hieronymus Fischer, Jun 08 2007
From Wesley Ivan Hurt, Jun 17 2016: (Start)
G.f.: (1+2*x+3*x^2+4*x^3+5*x^4+6*x^5)/(1-x^6).
a(n) = (21-3*cos(n*Pi)-4*sqrt(3)*cos((1-4*n)*Pi/6)-12*sin((1+2*n)*Pi/6))/6.
a(n) = a(n-6) for n>5. (End)
Previous Showing 11-20 of 35 results. Next