login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

A130216
a(0) = 3; a(n) = a(n-1) + (number of multiples of 3 so far in the sequence).
1
3, 4, 5, 6, 8, 10, 12, 15, 19, 23, 27, 32, 37, 42, 48, 55, 62, 69, 77, 85, 93, 102, 112, 122, 132, 143, 154, 165, 177, 190, 203, 216, 230, 244, 258, 273, 289, 305, 321, 338, 355, 372, 390, 409, 428, 447, 467, 487, 507, 528, 550, 572, 594, 617, 640, 663, 687, 712
OFFSET
0,1
COMMENTS
See A007980 for the same construction with multiples of 2.
LINKS
FORMULA
G.f.: -(3*x^8-2*x^7+x^4-2*x+3) / (x^9-2*x^8+x^7-x^2+2*x-1). - Alois P. Heinz, Aug 12 2009
EXAMPLE
3,4,5,6,8,10,12,15: next term is 19 which is 15 + 4 previous terms divisible by 3 (they are 3,6,12,15).
MAPLE
a:= proc(n) local m, r; m:= iquo(n, 7, 'r'); (3+21*m+6*r) *m/2 +[3, 4, 5, 6, 8, 10, 12][r+1] end: seq(a(n), n=0..80); # Alois P. Heinz, Aug 12 2009
MATHEMATICA
l={3}; Do[AppendTo[l, Last[l]+Count[l, _?(Divisible[#, 3]&)]], {n, 60}]; l (* Harvey P. Dale, Jul 24 2011 *)
CROSSREFS
Sequence in context: A198382 A173946 A051916 * A120162 A002859 A180646
KEYWORD
easy,nonn
AUTHOR
Eric Angelini, Aug 05 2007
EXTENSIONS
More terms from Alois P. Heinz, Aug 12 2009
STATUS
approved