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

A099550 Odd part of n modulo 9.

Original entry on oeis.org

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

Views

Author

Ralf Stephan, Oct 23 2004

Keywords

Crossrefs

Programs

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

Formula

a(n) = A010878(A000265(n)).
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = 4. - 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).

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)

A070433 a(n) = n^2 mod 9.

Original entry on oeis.org

0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1, 4, 0, 7, 7, 0, 4, 1, 0, 1
Offset: 0

Views

Author

N. J. A. Sloane, May 12 2002

Keywords

Comments

Also decimal expansion of 4692347/333333333. - Enrique Pérez Herrero, Nov 27 2022

Crossrefs

Programs

Formula

From R. J. Mathar, Apr 20 2010: (Start)
a(n) = a(n-9).
G.f.: ( -x*(1+x)*(x^6+3*x^5-3*x^4+10*x^3-3*x^2+3*x+1) ) / ( (x-1)*(1+x+x^2)*(x^6+x^3+1) ). (End)
a(n) = A010878(A000290(n)) = A010878(n^2). - Enrique Pérez Herrero, Nov 27 2022

A177274 Periodic sequence: Repeat 1, 2, 3, 4, 5, 6, 7, 8, 9.

Original entry on oeis.org

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

Views

Author

Klaus Brockhaus, May 07 2010

Keywords

Comments

Interleaving of A131669 and A131669 without first five terms.
Continued fraction expansion of (684125+sqrt(635918528029))/1033802.
Decimal expansion of 13717421/111111111.
a(n) = A010888(n+1) = A010878(n)+1 = A117230(n+2)-1.
a(n) = A064806(n+1)-n-1.
Essentially first differences of A037123.

Crossrefs

Cf. A131669 (odd digits followed by positive even digits), A010888 (digital root of n), A010878 (n mod 9), A117230 (1 followed by (repeat 2, 3, 4, 5, 6, 7, 8, 9, 10), offset 1), A064806 (n + digital root of n), A037123, A177270 (decimal expansion of (684125+sqrt(635918528029))/1033802).

Programs

  • Magma
    &cat[ [1, 2, 3, 4, 5, 6, 7, 8, 9]: k in [1..12] ];
  • Mathematica
    PadRight[{},120,Range[9]] (* Paolo Xausa, Jan 08 2024 *)

Formula

a(n) = (n mod 9)+1.
a(n) = a(n-9) for n > 8; 1; a(n) = n+1 for n <= 8.
G.f.: (1+2*x+3*x^2+4*x^3+5*x^4+6*x^5+7*x^6+8*x^7+9*x^8)/(1-x^9). [corrected by Georg Fischer, May 11 2019]

A105852 a(n) = sigma(n) mod 9.

Original entry on oeis.org

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

Views

Author

Shyam Sunder Gupta, May 05 2005

Keywords

Comments

If gcd(m,n) = 1 then a(m*n) = (a(m) * a(n)) mod 9. - Robert Israel, Sep 14 2014

Crossrefs

Cf. A000203, A010878, A190998 (digital root of sigma(n)).

Programs

  • Maple
    seq(numtheory:-sigma(n) mod 9, n=1..1000); # Robert Israel, Sep 14 2014
  • Mathematica
    Mod[DivisorSigma[1, Range[100]], 9] (* Wesley Ivan Hurt, Apr 25 2023 *)
  • PARI
    a(n)=sigma(n)%9

Formula

a(n) = A010878(A000203(n)). - Michel Marcus, Sep 14 2014

Extensions

Name corrected and keyword base removed by Michel Marcus, Sep 14 2014

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).

A010889 Simple periodic sequence: repeat 1,2,3,4,5,6,7,8,9,10.

Original entry on oeis.org

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

Views

Author

Keywords

Comments

Partial sums are given by A130488(n)+n+1. - Hieronymus Fischer, Jun 08 2007
Continued fraction expansion of (232405+sqrt(71216963807))/348378. [From Klaus Brockhaus, May 15 2010]

Crossrefs

Cf. A177933 (decimal expansion of (232405+sqrt(71216963807))/348378). [From Klaus Brockhaus, May 15 2010]

Programs

  • Mathematica
    PadRight[{},120,Range[10]] (* Harvey P. Dale, Feb 22 2015 *)
  • Python
    def a(n): return n % 10 + 1 # Paul Muljadi, Aug 06 2024

Formula

a(n) = 1 + (n mod 10) - Paolo P. Lava, Nov 21 2006
From Hieronymus Fischer, Jun 08 2007: (Start)
a(n) = A010879(n)+1.
G.f.: (Sum_{k=0..9} (k+1)*x^k)/(1-x^10).
G.f.: (10x^11-11x^10+1)/((1-x^10)(1-x)^2). (End)

Extensions

More terms from Klaus Brockhaus, May 15 2010

A014018 Inverse of 9th cyclotomic polynomial.

Original entry on oeis.org

1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, -1, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Keywords

Comments

Periodic with period length 9. - Ray Chandler, Apr 03 2017

Crossrefs

Cf. A010878.

Programs

  • Magma
    &cat[[1,0,0,-1,0,0,0,0,0]: n in [0..15]]; // Vincenzo Librandi, Apr 03 2014
  • Maple
    with(numtheory,cyclotomic); c := n->series(1/cyclotomic(n,x),x,80);
  • Mathematica
    CoefficientList[Series[1/Cyclotomic[9, x], {x, 0, 100}], x] (* Vincenzo Librandi, Apr 03 2014 *)
    LinearRecurrence[{0, 0, -1, 0, 0, -1},{1, 0, 0, -1, 0, 0},81] (* Ray Chandler, Sep 15 2015 *)
  • PARI
    Vec(1/polcyclo(9)+O(x^99)) \\ Charles R Greathouse IV, Mar 24 2014
    

Formula

G.f.: 1/(1 + x^3 + x^6). - Ilya Gutkovskiy, Aug 18 2017
a(n) = (19*m^8 - 628*m^7 + 8526*m^6 - 61152*m^5 + 247611*m^4 - 558012*m^3 + 637604*m^2 - 287408*m + 13440)/13440, where m = n mod 9. - Luce ETIENNE, Oct 18 2018

A086360 The n-th primorial number reduced modulo 9.

Original entry on oeis.org

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

Views

Author

Labos Elemer, Jul 21 2003

Keywords

Comments

a(n) is the fixed point reached by decimal-digit-sum-function (A007953), when starting the iteration from the value of the n-th primorial, A002110(n). - The (edited) original definition of the sequence, which is equal to a simple definition a(n) = A002110(n) mod 9, because taking the decimal digit sum preserves congruence modulo 9. - Antti Karttunen, Nov 14 2024
Only a(0)=1 and a(1)=2; each subsequent term is either a 3 or a 6.

Examples

			For n=7, 7th primorial = 510510, list of iterated digit sums is {510510,12,3}, thus a(7)=3.
		

Crossrefs

Programs

  • Maple
    A086360 := proc(n) option remember: if(n=1)then return 2:fi: return ithprime(n)*procname(n-1) mod 9: end: seq(A086360(n), n=1..100); # Nathaniel Johnston, May 04 2011
  • Mathematica
    sud[x_] := Apply[Plus, DeleteCases[IntegerDigits[x], 0]] q[x_] := Apply[Times, Table[Prime[w], {w, 1, x}]] Table[FixedPoint[sud, q[w]], {w, 1, 128}]
  • PARI
    up_to = 19683;
    A086360list(up_to_n) = { my(m=9, v=vector(1+up_to_n), pr=1); v[1] = 1; for(n=1, up_to_n, pr = (pr*prime(n))%m; v[1+n] = pr); (v); };
    v086360 = A086360list(up_to);
    A086360(n) = v086360[1+n]; \\ Antti Karttunen, Nov 14 2024

Formula

a(n) = A010878(A002110(n)) = A002110(n) mod 9.
a(n) = A010888(A002110(n)).

Extensions

Term a(0)=1 prepended, old definition moved to comments and replaced with one of the formulas, keyword:base removed because not really base-dependent - Antti Karttunen, Nov 14 2024
Previous Showing 11-20 of 33 results. Next