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.

A047234 Numbers that are congruent to {0, 1, 4} mod 6.

This page as a plain text file.
%I A047234 #37 Jul 27 2024 12:37:50
%S A047234 0,1,4,6,7,10,12,13,16,18,19,22,24,25,28,30,31,34,36,37,40,42,43,46,
%T A047234 48,49,52,54,55,58,60,61,64,66,67,70,72,73,76,78,79,82,84,85,88,90,91,
%U A047234 94,96,97,100,102,103,106,108,109,112,114,115,118,120,121,124
%N A047234 Numbers that are congruent to {0, 1, 4} mod 6.
%H A047234 Vincenzo Librandi, <a href="/A047234/b047234.txt">Table of n, a(n) for n = 1..1000</a>
%H A047234 <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (1,0,1,-1).
%F A047234 Equals partial sums of (0, 1, 3, 2, 1, 3, 2, 1, 3, 2, ...). - _Gary W. Adamson_, Jun 19 2008
%F A047234 G.f.: x^2*(1+x)*(2*x+1)/((1+x+x^2)*(x-1)^2). - _R. J. Mathar_, Oct 08 2011
%F A047234 From _Wesley Ivan Hurt_, Jun 14 2016: (Start)
%F A047234 a(n) = a(n-1) + a(n-3) - a(n-4) for n>4.
%F A047234 a(n) = (6*n-7+cos(2*n*Pi/3)+sqrt(3)*sin(2*n*Pi/3))/3.
%F A047234 a(3k) = 6k-2, a(3k-1) = 6k-5, a(3k-2) = 6k-6. (End)
%F A047234 Sum_{n>=2} (-1)^n/a(n) = (3-sqrt(3))*Pi/18 + log(2)/3 + log(2+sqrt(3))/(2*sqrt(3)). - _Amiram Eldar_, Dec 14 2021
%F A047234 E.g.f.: (6 + exp(x)*(6*x - 7) + exp(-x/2)*(cos(sqrt(3)*x/2) + sqrt(3)*sin(sqrt(3)*x/2)))/3. - _Stefano Spezia_, Jul 26 2024
%p A047234 A047234:=n->(6*n-7+cos(2*n*Pi/3)+sqrt(3)*sin(2*n*Pi/3))/3: seq(A047234(n), n=1..100); # _Wesley Ivan Hurt_, Jun 14 2016
%t A047234 Select[Range[0, 200], Mod[#, 6] == 0 || Mod[#, 6] == 1 || Mod[#, 6] == 4 &] (* _Vladimir Joseph Stephan Orlovsky_, Jul 07 2011 *)
%t A047234 LinearRecurrence[{1, 0, 1, -1}, {0, 1, 4, 6}, 100] (* _Vincenzo Librandi_, Jun 15 2016 *)
%t A047234 #+{0,1,4}&/@(6*Range[0,20])//Flatten (* _Harvey P. Dale_, Jul 25 2019 *)
%o A047234 (PARI) a(n)=(n-1)\3*6+[4,0,1][n%3+1] \\ _Charles R Greathouse IV_, Jun 11 2015
%o A047234 (Magma) [n : n in [0..150] | n mod 6 in [0, 1, 4]]; // _Wesley Ivan Hurt_, Jun 14 2016
%Y A047234 Cf. A047240, A047242.
%K A047234 nonn,easy
%O A047234 1,3
%A A047234 _N. J. A. Sloane_