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.

Showing 1-4 of 4 results.

A010877 a(n) = n mod 8.

Original entry on oeis.org

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

Views

Author

Keywords

Comments

The rightmost digit in the base-8 representation of n. Also, the equivalent value of the three rightmost digits in the base-2 representation of n. - Hieronymus Fischer, Jun 12 2007

Crossrefs

Partial sums: A130486. Other related sequences A130481, A130482, A130483, A130484, A130485.

Programs

Formula

Complex representation: a(n) = (1/8)*(1-r^n)*Sum_{k=1..7} k*Product_{m=1..7, m<>k} (1 - r^(n-m)) where r = exp(Pi/4*i) = (1+i)*sqrt(2)/2 and i=sqrt(-1).
Trigonometric representation: a(n) = 256*(sin(n*Pi/8))^2*Sum_{k=1..7} k*Product_{m=1..7, m<>k} (sin((n-m)*Pi/8))^2.
G.f.: g(x) = (Sum_{k=1..7}, k*x^k)/(1-x^8).
Also: g(x) = x(7x^8-8x^7+1)/((1-x^8)(1-x)^2). - Hieronymus Fischer, May 31 2007
a(n) = n mod 2 + 2*(floor(n/2) mod 4) = A000035(n) + 2*A010873(A004526(n)).
a(n) = n mod 4 + 4*(floor(n/4) mod 2) = A010873(n) + 4*A000035(A002265(n)).
a(n) = n mod 2 + 2*(floor(n/2) mod 2) + 4*(floor(n/4) mod 2) = A000035(n) + 2*A000035(A004526(n)) + 4*A000035(A002265(n)). - Hieronymus Fischer, Jun 12 2007
a(n) = (1/2)*(7 - (-1)^n - 2*(-1)^(b/4) - 4*(-1)^((b - 2 + 2*(-1)^(b/4))/8)) where b = 2n - 1 + (-1)^n. - Hieronymus Fischer, Jun 12 2007
General formula for period 2^k: a(n) = (1/2)*(2^k - 1 - Sum_{j=0..k-1} 2^j*(-1)^p(j,n)) where p(j,n) is defined recursively by p(0,n)=n, p(j,n) = (1/4)*(2*p(j-1,n) - 1 + (-1)^p(j-1,n)). - Hieronymus Fischer, Jun 14 2007
a(n) = floor(1234567/99999999*10^(n+1)) mod 10. - Hieronymus Fischer, Jan 03 2013
a(n) = floor(48913/2396745*8^(n+1)) mod 8. - Hieronymus Fischer, Jan 04 2013

Extensions

Formula section re-edited for better readability by Hieronymus Fischer

A168183 Numbers that are not multiples of 9.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 16, 17, 19, 20, 21, 22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 35, 37, 38, 39, 40, 41, 42, 43, 44, 46, 47, 48, 49, 50, 51, 52, 53, 55, 56, 57, 58, 59, 60, 61, 62, 64, 65, 66, 67, 68, 69, 70, 71, 73, 74, 75, 76, 77, 78, 79, 80
Offset: 1

Views

Author

Reinhard Zumkeller, Nov 30 2009

Keywords

Comments

It seems that, for any n >= 1, there exists no positive integer z such that digit_sum(z) = digit_sum(a(n)+z). - Max Lacoma, Sep 19 2019. Giovanni Resta: this follows immediately from the well-known fact that sod(x) == x (mod 9).

Crossrefs

Complement of A008591.

Programs

Formula

A168182(a(n)) = 1.
A010888(a(n)) = A010887(n-1).
A109012(a(n)) < 9.
From Wesley Ivan Hurt, Sep 12 2015: (Start)
a(n) = a(n-1) + a(n-8) - a(n-9), n>9.
a(n) = n + floor((n-1)/8). (End)
From Philippe Deléham, Dec 05 2016: (Start)
a(n) = 1 + A248375(n-1).
G.f.: x*(1-x^9)/((1-x)^2*(1-x^8)). (End)
E.g.f.: 1 + (1/8)*(-cos(x) + (-5+9*x)*cosh(x) - 2*cos(x/sqrt(2))*cosh(x/sqrt(2)) + sin(x) + (-4+9*x)*sinh(x) + 2*sin(x/sqrt(2))*(sqrt(2)*cosh(x/sqrt(2)) + sinh(x/sqrt(2)))). - Stefano Spezia, Sep 20 2019
Sum_{n>=1} (-1)^(n+1)/a(n) = (sqrt(3) + 3*cosec(2*Pi/9) - 3*tan(Pi/18)) * Pi/27. - Amiram Eldar, May 11 2025

A177034 Decimal expansion of (9280+3*sqrt(13493990))/14165.

Original entry on oeis.org

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

Views

Author

Klaus Brockhaus, May 01 2010

Keywords

Comments

Continued fraction expansion of (9280+3*sqrt(13493990))/14165 is A010887.

Examples

			(9280+3*sqrt(13493990))/14165 = 1.43312742655589912842...
		

Crossrefs

Cf. A177035 (decimal expansion of sqrt(13493990)), A010887 (repeat 1, 2, 3, 4, 5, 6, 7, 8).

Programs

  • Mathematica
    First@RealDigits@N[(9280 + 3 Sqrt[13493990])/14165, 200] (* Vincenzo Librandi, Dec 29 2016 *)

A181753 Universal sequence of period 56 which contains every 3-subset of {1,2,...,8} exactly once.

Original entry on oeis.org

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

Views

Author

Susanna Cuyler, Nov 14 2010

Keywords

Comments

Each successive block of length 7 is obtained by adding 5 mod 8 to the previous block.

Examples

			The period is 1356725 6823472 3578147 8245614 5712361 2467836 7134583 4681258.
		

Crossrefs

Cf. A010887.

Programs

  • Haskell
    a181753 n = a181753_list !! (n-1)
    a181753_list = concat $ iterate
                   (map ((+ 1) . flip mod 8 . (+ 4))) [1,3,5,6,7,2,5]
    -- Reinhard Zumkeller, Nov 09 2014

Formula

From Chai Wah Wu, Jun 13 2020: (Start)
a(n) = a(n-1) - a(n-7) + a(n-8) - a(n-14) + a(n-15) - a(n-21) + a(n-22) - a(n-28) + a(n-29) - a(n-35) + a(n-36) - a(n-42) + a(n-43) - a(n-49) + a(n-50) for n > 50.
G.f.: x*(-8*x^49 + 3*x^48 + 3*x^47 + x^46 - 7*x^45 + 2*x^44 + 2*x^43 - 7*x^42 - 2*x^41 + 6*x^40 + 2*x^39 - 6*x^38 + 4*x^37 - 4*x^36 - 6*x^35 + x^34 + x^33 + 3*x^32 - 5*x^31 + 6*x^30 - 2*x^29 - 5*x^28 - 4*x^27 + 4*x^26 + 4*x^25 - 4*x^24 - 4*x^21 - x^20 - x^19 + 5*x^18 - 3*x^17 + 2*x^16 - 6*x^15 - 3*x^14 + 2*x^13 + 2*x^12 - 2*x^11 - 2*x^10 + 4*x^9 - 4*x^8 - 2*x^7 - 3*x^6 + 5*x^5 - x^4 - x^3 - 2*x^2 - 2*x - 1)/(x^50 - x^49 + x^43 - x^42 + x^36 - x^35 + x^29 - x^28 + x^22 - x^21 + x^15 - x^14 + x^8 - x^7 + x - 1). (End)
Showing 1-4 of 4 results.