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

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A060730 a(n) = a(n-1) + a(n - 1 minus the number of terms of a(k) == (mod 3) so far). 0
1, 2, 3, 5, 7, 12, 17, 22, 34, 41, 53, 87, 109, 131, 184, 218, 252, 361, 414, 501, 632, 763, 894, 1112, 1330, 1548, 1909, 2161, 2575, 3207, 3568, 4331, 5225, 5726, 6489, 7819, 8582, 9694, 11855, 12967, 14515, 18083, 19413, 21574, 26799, 28708, 32276 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

LINKS

Table of n, a(n) for n=1..47.

EXAMPLE

a(5) = a(4) + a(4 - the number of terms congruent to 2 (mod 3) so far) = a(4) + a(4-2) = 5 + 2 = 7.

MATHEMATICA

m[ 1 ] = 1; m[ 2 ] = 2; m[ 3 ] = 3; m[ n_Integer ] := m[ n ] = Block[ {a = b = c = 0}, Do[ Switch[ Mod[ m[ k ], 3 ], 0, a++, 1, b++, 2, c++ ], {k, 1, n - 1} ]; Switch[ Mod[ n, 3 ], 0, m[ n - 1 ] + m[ n - 1 - a ], 1, m[ n - 1 ] + m[ n - 1 - b ], 2, m[ n - 1 ] + m[ n - 1 - c ] ] ]; Table[ m[ n ], {n, 1, 50} ]

CROSSREFS

Sequence in context: A319769 A326083 A027959 * A308928 A308992 A326468

Adjacent sequences:  A060727 A060728 A060729 * A060731 A060732 A060733

KEYWORD

nonn

AUTHOR

Robert G. Wilson v, Apr 22 2001

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 19 18:39 EST 2019. Contains 329323 sequences. (Running on oeis4.)