login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A130253
Number of Jacobsthal numbers (A001045) <=n.
14
1, 3, 3, 4, 4, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9
OFFSET
0,2
COMMENTS
Partial sums of the Jacobsthal indicator sequence (A105348).
For n<>1, we have a(A001045(n))=n+1.
LINKS
Dorin Andrica, Ovidiu Bagdasar, and George Cătălin Tųrcąs, On some new results for the generalised Lucas sequences, An. Şt. Univ. Ovidius Constanţa (Romania, 2021) Vol. 29, No. 1, 17-36.
FORMULA
a(n) = floor(log_2(3n+1)) + 1 = ceiling(log_2(3n+2)).
a(n) = A130249(n) + 1 = A130250(n+1).
G.f.: 1/(1-x)*(Sum_{k>=0} x^A001045(k)).
EXAMPLE
a(9)=5 because there are 5 Jacobsthal numbers <=9 (0,1,1,3 and 5).
MATHEMATICA
Table[1+Floor[Log[2, 3n+1]], {n, 0, 100}] (* Harvey P. Dale, Jul 03 2013 *)
PROG
(PARI) a(n)=logint(3*n+1, 2)+1 \\ Charles R Greathouse IV, Oct 03 2016
(Magma) [Ceiling(Log(3*n+2)/Log(2)): n in [0..30]]; // G. C. Greubel, Jan 08 2018
CROSSREFS
For partial sums see A130252. Other related sequences A001045, A130249, A130250, A130253, A105348. Also A130233, A130235, A130241, A108852, A130245.
Sequence in context: A240622 A364883 A130250 * A145288 A075324 A134993
KEYWORD
nonn,easy
AUTHOR
Hieronymus Fischer, May 20 2007
STATUS
approved