login
This site is supported by donations to The OEIS Foundation.
Logo

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A032793 Numbers that are congruent to {1, 2, 4} mod 5. 22
1, 2, 4, 6, 7, 9, 11, 12, 14, 16, 17, 19, 21, 22, 24, 26, 27, 29, 31, 32, 34, 36, 37, 39, 41, 42, 44, 46, 47, 49, 51, 52, 54, 56, 57, 59, 61, 62, 64, 66, 67, 69, 71, 72, 74, 76, 77, 79, 81, 82, 84, 86, 87, 89, 91, 92, 94, 96, 97, 99, 101, 102, 104, 106, 107, 109 (list; graph; refs; listen; history; internal format)
OFFSET

1,2

LINKS

Index to sequences with linear recurrences with constant coefficients, signature (1,0,1,-1).

FORMULA

a(n) = +1*a(n-1) +1*a(n-3) -1*a(n-4).

a(n)=-1+Sum_{k=1..n}{(1/9)*(2*(k mod 3)+8*[(k+1) mod 3]+5*[(k+2) mod 3]}, with n>=1 [From Paolo P. Lava (paoloplava(AT)gmail.com), Sep 03 2010]

a(n)=floor((5*n-2)/3). [From Gary Detlefs (gdetlefs(AT)aol.com), May 14 2011]

G.f. x*(1+x+2*x^2+x^3) / ( (1+x+x^2)*(x-1)^2 ). - R. J. Mathar, Oct 08 2011

MATHEMATICA

Select[Range[0, 200], MemberQ[{1, 2, 4}, Mod[#, 5]] &] (* From Vladimir Joseph Stephan Orlovsky, Feb 11 2012 *)

PROG

(MAGMA)[ n: n in [0..120] | n mod 5 in {1, 2, 4} ]; [From Vincenzo Librandi, Dec 29 2010]

(PARI) a(n)=n\3*5+[-1, 1, 2][n%3+1] \\ Charles R Greathouse IV, Jan 18 2012

CROSSREFS

Cf. A032794, A032795.

Sequence in context: A186151 A184732 A039009 * A195127 A083088 A080755

Adjacent sequences:  A032790 A032791 A032792 * A032794 A032795 A032796

KEYWORD

nonn,easy,changed

AUTHOR

Patrick De Geest (pdg(AT)worldofnumbers.com), May 15, 1998.

EXTENSIONS

Better description from Michael Somos, Jun 08 2000.

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
Recent Additions | More pages | Superseeker | Maintained by The OEIS Foundation Inc.

Content is available under The OEIS End-User License Agreement .

Last modified February 17 08:44 EST 2012. Contains 205998 sequences.