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

A070403 a(n) = 7^n mod 9.

Original entry on oeis.org

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

Views

Author

N. J. A. Sloane, May 12 2002

Keywords

Comments

Also the digital root of 7^n. If we convert this to a repeating decimal 0.174174..., we get the rational number 58/333. - Cino Hilliard, Dec 31 2004
A141722 (1, 25, 121, 505, 2041, 8185) mod 9. Note A141722 = 10*A000975(2n) + A000975(2n+1). - Paul Curtz, Sep 15 2008
Digital root of the powers of any number congruent to 7 mod 9. - Alonso del Arte, Jan 26 2014

References

  • Cecil Balmond, Number 9: The Search for the Sigma Code. Munich, New York: Prestel (1998): 203.

Crossrefs

Cf. Digital roots of powers of c mod 9: c = 2, A153130; c = 4, A100402; c = 5, A070366; c = 8, A010689.

Programs

Formula

From R. J. Mathar, Feb 23 2009: (Start)
G.f.: (1+7*x+4*x^2)/((1-x)*(1+x+x^2)).
a(n+1) - a(n) = 3*A099837(n+3).
a(n) = 4 - 3*A049347(n). (End)
a(n) = a(n-3) for n>3. - G. C. Greubel, Mar 19 2016
a(n) = 4-2*sqrt(3)*sin((2*n+2)*Pi/3). - Wesley Ivan Hurt, Jun 09 2016
a(n) = A010888(7*a(n-1)). - Stefano Spezia, Mar 20 2025

A166304 Third trisection of A022998.

Original entry on oeis.org

4, 5, 16, 11, 28, 17, 40, 23, 52, 29, 64, 35, 76, 41, 88, 47, 100, 53, 112, 59, 124, 65, 136, 71, 148, 77, 160, 83, 172, 89, 184, 95, 196, 101, 208, 107, 220, 113, 232, 119, 244, 125, 256, 131, 268, 137, 280, 143, 292, 149, 304, 155, 316, 161, 328, 167, 340, 173, 352, 179
Offset: 0

Views

Author

Paul Curtz, Oct 11 2009

Keywords

Comments

The sequence read modulo 9 is the periodic sequence 4, 5, 7, 2, 1, 8 (repeat..)
The same set of numbers in a period of length 6 is in A153130,
A165355 read modulo 9, A165367 read modulo 9, and A166138 read modulo 9.

Crossrefs

Cf. A165988 (first trisection), A166138 (2nd trisection).

Programs

  • Mathematica
    LinearRecurrence[{0, 2, 0, -1}, {4, 5, 16, 11}, 100] (* G. C. Greubel, May 09 2016 *)

Formula

a(n) = A022998(3*n+2).
a(n) = 2*a(n-2)-a(n-4).
G.f.: (4+5*x+8*x^2+x^3)/((x-1)^2 *(1+x)^2 ).
a(2*n) = A017569(n). a(2n+1) = A016969(n) .

Extensions

Edited and extended by R. J. Mathar, Oct 14 2009

A154127 Period 6: repeat [1, 2, 5, 8, 7, 4].

Original entry on oeis.org

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

Views

Author

Paul Curtz, Jan 05 2009

Keywords

Crossrefs

Programs

Formula

From R. J. Mathar, Feb 25 2009, Mar 09 2009: (Start)
a(n) = a(n-1) - a(n-3) + a(n-4) for n>3.
G.f.: (1+x+3*x^2+4*x^3)/((1-x)*(1+x)*(x^2-x+1)). (End)
a(n) = (27-cos(n*Pi)-20*cos(n*Pi/3)-4*sqrt(3)*sin(n*Pi/3))/6. - Wesley Ivan Hurt, Jun 17 2016

Extensions

Corrected numerator in g.f R. J. Mathar, Mar 09 2009

A153990 Period 6: repeat [1, 2, 5, 4, 7, 8].

Original entry on oeis.org

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

Views

Author

Paul Curtz, Jan 04 2009

Keywords

Comments

Shares digits with other 6-periodic sequences, see the list in A153130.
Also the decimal expansion of the constant 13942/111111. [R. J. Mathar, Jan 23 2009]

Crossrefs

Programs

Formula

a(n) - A141425(n) = A131533(n+2).
a(6n+0) + a(6n+5) = a(6n+1) + a(6n+4) = a(6n+2) + a(6n+3) = 9.
G.f.: (1+2*x+5*x^2+4*x^3+7*x^4+8*x^5)/((1-x)*(1+x)*(1+x+x^2)*(x^2-x+1)). [R. J. Mathar, Jan 23 2009]
From Wesley Ivan Hurt, Jun 17 2016: (Start)
a(n) = (27-cos(n*Pi)-8*sqrt(3)*cos((1-4*n)*Pi/6)-16*sin((1+2*n)*Pi/6))/6.
a(n) = a(n-6) for n>5. (End)

Extensions

Edited by R. J. Mathar, Jan 23 2009

A154870 Period 6: repeat [7, 5, 1, -7, -5, -1].

Original entry on oeis.org

7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1, -7, -5, -1, 7, 5, 1
Offset: 0

Views

Author

Paul Curtz, Jan 16 2009

Keywords

Comments

The sequence b(n) = (-A153130(n)) mod 9 = A153130(n+3) = A146501(n-1) = 8, 7, 5, 1, 2, 4,... has period length 6. This here is a(n)=b(n)-A153130(n).
a(n) is (-1)^(n+1) * numerator of F(n) where F(n) = f(F(n-1)) starting from F(0) = -7/4 and step f(z) = z^2 -29/16. - Nicolas Bělohoubek, Nov 20 2024

Crossrefs

Programs

Formula

a(n) = -a(n-3) for n>2; G.f.: (7+5*x+x^2)/((1+x)*(1-x+x^2)). [R. J. Mathar, Jan 23 2009]
a(n) = cos(n*Pi) + 6*cos(n*Pi/3) + 2*sqrt(3)*sin(n*Pi/3). - Wesley Ivan Hurt, Jun 20 2016

Extensions

Edited and extended by R. J. Mathar, Jan 23 2009

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

Original entry on oeis.org

1, 0, 4, 2, 16, 14, 64, 74, 256, 350, 1024, 1562, 4096, 6734, 16384, 28394, 65536, 117950, 262144, 484922, 1048576, 1979054, 4194304, 8034314, 16777216, 32491550, 67108864, 131029082, 268435456, 527304974, 1073741824, 2118785834, 4294967296, 8503841150
Offset: 0

Views

Author

Paul Curtz, Nov 12 2009

Keywords

Comments

Binomial transform of A077917, the signed variant of A127864.

Crossrefs

Cf. A154383.

Programs

  • Maple
    seq(2^n - (1 - (-1)^n)*3^((n-1)/2), n=0..100); # Robert Israel, Apr 11 2019
  • Mathematica
    LinearRecurrence[{2, 3, -6}, {1, 0, 4}, 40] (* Harvey P. Dale, Nov 29 2011 *)

Formula

a(n) = A167936(n+1) - A167936(n).
a(2n) = A000302(n). a(2n+1) = 2*A005061(n).
a(n) = 2*a(n-1) + 3*a(n-2) - 6*a(n-3).
G.f.: (x-1)^2/((2*x-1)*(3*x^2-1)).
a(n+4) mod 9 = A153130(n+4) = A146501(n+2), n>=0.
E.g.f.: exp(2*x) - (2/sqrt(3))*sinh(sqrt(3)*x). - G. C. Greubel, Jun 27 2016

Extensions

Edited and extended by R. J. Mathar, Feb 27 2010
Incorrect b-file corrected by Robert Israel, Apr 11 2019

A381487 Numbers which are a power of their digital root.

Original entry on oeis.org

0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 81, 128, 256, 512, 729, 2401, 6561, 8192, 16384, 32768, 59049, 78125, 524288, 531441, 823543, 1048576, 2097152, 4782969, 33554432, 43046721, 67108864, 134217728, 282475249, 387420489, 1220703125, 2147483648, 3486784401, 4294967296
Offset: 1

Views

Author

Stefano Spezia, Feb 25 2025

Keywords

Examples

			a(12) = 128 is a term since 128 = 2^7 = A010888(128)^7.
		

Crossrefs

Digital root of k^n: A000012 (1), A153130 (2), A100401 (3), A100402 (4), A070366 (5), A100403 (6), A070403 (7), A010689 (8), A010734 (9).

Programs

  • Mathematica
    A010888[n_]:=n - 9*Floor[(n-1)/9]; kmax=5*10^6; a={0,1}; For[k=2, k<=kmax, k++, If[A010888[k]!=1, If[IntegerQ[Log[A010888[k],k]], AppendTo[a,k]]]]; a
  • PARI
    isok(k) = if ((k==0) || (k==1), return(1)); my(d=(k-1)%9+1); if (d>1, d^logint(k, d) == k); \\ Michel Marcus, Feb 26 2025
    
  • PARI
    lista(nn) = my(list = List()); listput(list, 0); listput(list, 1); for (n=2, 9, for (k=1, logint(nn, n), if ((n^k-1)%9+1 == n, listput(list, n^k)););); vecsort(Vec(list)); \\ Michel Marcus, Feb 27 2025

Formula

a(n) = A381491(n)^A381492(n).

A154815 Period 6: repeat [8, 7, 4, 5, 2, 1].

Original entry on oeis.org

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

Views

Author

Paul Curtz, Jan 15 2009

Keywords

Comments

Obtained through reversion of the period in A153990, or by taking a half period of A154811.
Shares digits with other 6-periodic sequences, see the list in A153130.
Also the decimal expansion of the constant 97169/111111. [R. J. Mathar, Jan 23 2009]

Crossrefs

Programs

Formula

a(n) = (8*A153990(n)) mod 9.
G.f.: (8+7*x+4*x^2+5*x^3+2*x^4+x^5)/((1-x)*(1+x)*(1+x+x^2)(x^2-x+1)). [R. J. Mathar, Jan 23 2009]
From Wesley Ivan Hurt, Jun 23 2016: (Start)
a(n) = a(n-6) for n>5.
a(n) = (27 + cos(n*Pi) + 8*cos(n*Pi/3) + 12*cos(2*n*Pi/3) + 8*sqrt(3)*sin(n*Pi/3) + 4*sqrt(3)*sin(2*n*Pi/3))/6. (End)

Extensions

Edited by R. J. Mathar, Jan 23 2009

A156067 a(0)=1. a(n)= -2^(n-1)-3*(-1)^n, n>1.

Original entry on oeis.org

1, 2, -5, -1, -11, -13, -35, -61, -131, -253, -515, -1021, -2051, -4093, -8195, -16381, -32771, -65533, -131075, -262141, -524291, -1048573, -2097155, -4194301, -8388611, -16777213, -33554435, -67108861, -134217731, -268435453, -536870915, -1073741821, -2147483651
Offset: 0

Views

Author

Paul Curtz, Feb 03 2009

Keywords

Comments

The main diagonal of the array of A153130 and its successive differences.
A154589 is the second upper diagonal of the array.

Programs

  • Mathematica
    Join[{1},LinearRecurrence[{1,2},{2,-5},40]] (* Harvey P. Dale, Dec 11 2011 *)

Formula

a(n)= +a(n-1) +2*a(n-2), n>2.
G.f.: x*(-2+7*x) / ( (1+x)*(2*x-1) ).
a(n) == A153130(n) (mod 9).
a(n+1)-2*a(n) = (-1)^n*9, n>0.
a(n) = A154589(n)-3*(-1)^n.
a(n)+a(n+3) = -A005010(n-1) = -9*A131577(n).
a(2*n)+a(2*n+1) = -3*2^(2n-1) = -A002023(n-2).

A166577 Inverse binomial transform of A166517.

Original entry on oeis.org

1, 4, -5, 10, -20, 40, -80, 160, -320, 640, -1280, 2560, -5120, 10240, -20480, 40960, -81920, 163840, -327680, 655360, -1310720, 2621440, -5242880, 10485760, -20971520, 41943040, -83886080, 167772160, -335544320, 671088640, -1342177280, 2684354560, -5368709120
Offset: 0

Views

Author

Paul Curtz, Oct 17 2009

Keywords

Comments

The definition assumes that the offset of A166517 is changed to 0.
A166517 mod 9 yields a periodic sequence with period 1, 5, 4, 8, 7, 2.
This set of numbers in the period appears also in A153130, A146501, and A166304.

Crossrefs

Programs

  • Mathematica
    Join[{1,4},NestList[-2#&,-5,40]] (* Harvey P. Dale, Aug 02 2012 *)
    Join[{1, 4}, LinearRecurrence[{-2}, {-5}, 48]] (* G. C. Greubel, May 17 2016 *)

Formula

a(n) = -2*a(n-1), n>2.
a(n) = (-1)^(n+1)*A020714(n-2), n>1.
From Colin Barker, Jan 07 2013: (Start)
a(n) = -5*(-1)^n*2^(n-2) for n>1.
G.f.: (3*x^2+6*x+1)/(2*x+1). (End)
E.g.f.: (9/4) + (3/2)*x - (5/4)*exp(-2*x). - Alejandro J. Becerra Jr., Feb 15 2021

Extensions

Edited, comments not concerning this sequence removed, and extended by R. J. Mathar, Oct 21 2009
Previous Showing 11-20 of 28 results. Next