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.

A047257 Numbers that are congruent to {4, 5} mod 6.

Original entry on oeis.org

4, 5, 10, 11, 16, 17, 22, 23, 28, 29, 34, 35, 40, 41, 46, 47, 52, 53, 58, 59, 64, 65, 70, 71, 76, 77, 82, 83, 88, 89, 94, 95, 100, 101, 106, 107, 112, 113, 118, 119, 124, 125, 130, 131, 136, 137, 142, 143, 148, 149
Offset: 1

Views

Author

Keywords

Comments

Equivalently, numbers m such that 2^m - m is divisible by 3. Indeed, for every prime p, there are infinitely many numbers m such that 2^m - m (A000325) is divisible by p, here are numbers m corresponding to p = 3. - Bernard Schott, Dec 10 2021
Numbers k for which A276076(k) and A276086(k) are multiples of nine. For a simple proof, consider the penultimate digit in the factorial and primorial base expansions of n, A007623 and A049345. - Antti Karttunen, Feb 08 2024

References

  • Michael Doob, The Canadian Mathematical Olympiad & L'Olympiade Mathématique du Canada 1969-1993, Canadian Mathematical Society & Société Mathématique du Canada, Problem 4, 1983, page 158, 1993.

Crossrefs

Cf. A000325.
Similar with: A299174 (p = 2), this sequence (p = 3), A349767 (p = 5).

Programs

Formula

a(n) = 4 + 6*floor(n/2) + n mod 2.
a(n) = 6*n-a(n-1)-3, with a(1)=4. - Vincenzo Librandi, Aug 05 2010
G.f.: ( x*(4+x+x^2) ) / ( (1+x)*(x-1)^2 ). - R. J. Mathar, Oct 08 2011
a(n) = 3*n - (-1)^n. - Wesley Ivan Hurt, Mar 20 2015
Sum_{n>=1} (-1)^(n+1)/a(n) = Pi/(6*sqrt(3)) - log(2)/3. - Amiram Eldar, Dec 14 2021
E.g.f.: 1 + 3*x*exp(x) - exp(-x). - David Lovler, Aug 25 2022

A047264 Numbers that are congruent to 0 or 5 mod 6.

Original entry on oeis.org

0, 5, 6, 11, 12, 17, 18, 23, 24, 29, 30, 35, 36, 41, 42, 47, 48, 53, 54, 59, 60, 65, 66, 71, 72, 77, 78, 83, 84, 89, 90, 95, 96, 101, 102, 107, 108, 113, 114, 119, 120, 125, 126, 131, 132, 137, 138, 143, 144, 149, 150, 155, 156, 161, 162, 167, 168, 173, 174
Offset: 1

Views

Author

Keywords

Comments

Values of n for which Sum_{k=1..n} k*Fibonacci(k) is even (n > 0). Example: 5 is in the sequence because Sum_{k=1..5} k*Fibonacci(k) = 1*1 + 2*1 + 3*2 + 4*3 + 5*5 = 46. - Emeric Deutsch, Mar 28 2005
For a(n) is the n-th Tower of Hanoi move, the smallest disc (#1) is on peg A. If n == (1,2) mod 6, the disc is on peg C; and if n == (3,4) mod 6, the disc is on peg B. Disc #1 rotates C,B,A,C,B,A,C,B,A,... All discs start at "0" on peg A. Disc #1 is on peg A again for moves (5,6), (11,12), (17,18), ... - Gary W. Adamson, Jun 23 2012

Examples

			From _Vincenzo Librandi_, Aug 05 2010: (Start)
a(2) = 6*2 - 0 - 7 = 5;
a(3) = 6*3 - 5 - 7 = 6;
a(4) = 6*4 - 6 - 7 = 11. (End)
		

Crossrefs

Complement of A047227.

Programs

  • Maple
    c:=proc(n) if n mod 6 = 0 or n mod 6 = 5 then n else fi end: seq(c(n),n=0..149); # Emeric Deutsch, Mar 28 2005
  • Mathematica
    Select[Range[0, 149], MemberQ[{0, 5}, Mod[#, 6]] &] (* or *)
    Fold[Append[#1, 6 #2 - Last@ #1 - 7] &, {0}, Range[2, 50]] (* or *)
    Rest@ CoefficientList[Series[x^2*(5 + x)/((1 + x) (x - 1)^2), {x, 0, 50}], x] (* Michael De Vlieger, Jan 12 2018 *)
  • PARI
    forstep(n=0,200,[5,1],print1(n", ")) \\ Charles R Greathouse IV, Oct 17 2011
    
  • PARI
    a(n) = 3*n - 2 + (-1)^n \\ David Lovler, Aug 04 2022

Formula

a(n) = 3*n + (-1)^n - 2.
a(n) = 6*n - a(n-1) - 7 (with a(1)=0). - Vincenzo Librandi, Aug 05 2010
G.f.: x^2*(5+x) / ( (1+x)*(x-1)^2 ). - R. J. Mathar, Oct 08 2011
Let b(1)=0, b(2)=1 and b(k+2) = b(k+1) - b(k) + k^2; then a(n) is the sequence of integers such that b(a(n)) is a square = (a(n) + 1)^2. - Benoit Cloitre, Sep 04 2002
a(n+1) = Sum_{k>=0} A030308(n,k)*b(k) with b(0)=5 and b(k)=A007283(k) for k > 0. - Philippe Deléham, Oct 17 2011
Sum_{n>=2} (-1)^n/a(n) = log(2)/3 + log(3)/4 - sqrt(3)*Pi/12. - Amiram Eldar, Dec 13 2021
E.g.f.: 1 + (3*x - 2)*exp(x) + exp(-x). - David Lovler, Aug 08 2022

A047247 Numbers that are congruent to {2, 3, 4, 5} (mod 6).

Original entry on oeis.org

2, 3, 4, 5, 8, 9, 10, 11, 14, 15, 16, 17, 20, 21, 22, 23, 26, 27, 28, 29, 32, 33, 34, 35, 38, 39, 40, 41, 44, 45, 46, 47, 50, 51, 52, 53, 56, 57, 58, 59, 62, 63, 64, 65, 68, 69, 70, 71, 74, 75, 76, 77, 80, 81, 82, 83, 86, 87, 88, 89, 92, 93, 94, 95, 98, 99
Offset: 1

Views

Author

Keywords

Comments

The sequence is the interleaving of A047235 with A047270. - Guenther Schrack, Feb 10 2019
Numbers k for which A276076(k) and A276086(k) are multiples of three. For a simple proof, consider the penultimate digit in the factorial and primorial base expansions of n, A007623 and A049345. - Antti Karttunen, Feb 08 2024

Crossrefs

Programs

  • Magma
    [n : n in [0..100] | n mod 6 in [2, 3, 4, 5]]; // Wesley Ivan Hurt, May 21 2016
    
  • Maple
    A047247:=n->(6*n-1-I^(2*n)-(1-I)*I^(-n)-(1+I)*I^n)/4: seq(A047247(n), n=1..100); # Wesley Ivan Hurt, May 21 2016
  • Mathematica
    Table[(6n-1-I^(2n)-(1-I)*I^(-n)-(1+I)*I^n)/4, {n, 80}] (* Wesley Ivan Hurt, May 21 2016 *)
    LinearRecurrence[{1,0,0,1,-1},{2,3,4,5,8},70] (* Harvey P. Dale, May 25 2024 *)
  • PARI
    my(x='x+O('x^70)); Vec(x*(2+x+x^2+x^3+x^4)/((1-x)*(1-x^4))) \\ G. C. Greubel, Feb 16 2019
    
  • Sage
    a=(x*(2+x+x^2+x^3+x^4)/((1-x)*(1-x^4))).series(x, 72).coefficients(x, sparse=False); a[1:] # G. C. Greubel, Feb 16 2019

Formula

G.f.: x*(2+x+x^2+x^3+x^4) / ( (1+x)*(1+x^2)*(1-x)^2 ). - R. J. Mathar, Oct 08 2011
From Wesley Ivan Hurt, May 21 2016: (Start)
a(n) = a(n-1) + a(n-4) - a(n-5) for n>5.
a(n) = (6*n - 1 - i^(2*n) - (1-i)*i^(-n) - (1+i)*i^n)/4 where i = sqrt(-1).
a(2*n) = A047270(n), a(2*n-1) = A047235(n).
a(n) = A047227(n) + 1, a(1-n) = - A047227(n). (End)
From Guenther Schrack, Feb 10 2019: (Start)
a(n) = (6*n - 1 - (-1)^n -2*(-1)^(n*(n+1)/2))/4.
a(n) = a(n-4) + 6, a(1)=2, a(2)=3, a(3)=4, a(4)=5, for n > 4.
a(n) = A047227(n) + 1. a(n) = A047246(n) + 2. (End)
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(3)*Pi/12 - 2*log(2)/3 + log(3)/4. - Amiram Eldar, Dec 17 2021

Extensions

More terms from Wesley Ivan Hurt, May 21 2016

A203016 Numbers congruent to {1, 2, 3, 4} mod 6, multiplied by 3.

Original entry on oeis.org

3, 6, 9, 12, 21, 24, 27, 30, 39, 42, 45, 48, 57, 60, 63, 66, 75, 78, 81, 84, 93, 96, 99, 102, 111, 114, 117, 120, 129, 132, 135, 138, 147, 150, 153, 156, 165, 168, 171, 174, 183, 186, 189, 192, 201, 204, 207, 210, 219, 222, 225, 228, 237, 240, 243, 246, 255, 258, 261, 264, 273, 276, 279, 282, 291, 294, 297
Offset: 1

Views

Author

N. J. A. Sloane, Dec 27 2011

Keywords

Comments

Appears to coincide with the list of numbers n such that A006600(n) is not a multiple of n. Equals A047227 multiplied by 3.

Crossrefs

Programs

  • Magma
    [3*n : n in [0..100] | n mod 6 in [1..4]]; // Wesley Ivan Hurt, Jun 07 2016
  • Maple
    A203016:=n->3*(6*n-5-I^(2*n)+(1+I)*I^(1-n)+(1-I)*I^(n-1))/4: seq(A203016(n), n=1..100); # Wesley Ivan Hurt, Jun 07 2016
  • Mathematica
    3 Select[Range[100], MemberQ[{1, 2, 3, 4}, Mod[#, 6]] &] (* Wesley Ivan Hurt, Jun 07 2016 *)

Formula

From Wesley Ivan Hurt, Jun 07 2016: (Start)
G.f.: 3*x*(1+x+x^2+x^3+2*x^4)/((x-1)^2*(1+x+x^2+x^3)).
a(n) = 3*(6*n-5-i^(2*n)+(1+i)*i^(1-n)+(1-i)*i^(n-1))/4 where i=sqrt(-1).
a(n) = a(n-1) + a(n-4) - a(n-5) for n>5.
a(2k) = 3*A047235(k), a(2k-1) = 3*A047241(k). (End)
E.g.f.: 3*(4 + sin(x) - cos(x) + (3*x - 2)*sinh(x) + 3*(x - 1)*cosh(x))/2. - Ilya Gutkovskiy, Jun 07 2016
Showing 1-4 of 4 results.