A079643 a(n) = floor(n/floor(sqrt(n))).
1, 2, 3, 2, 2, 3, 3, 4, 3, 3, 3, 4, 4, 4, 5, 4, 4, 4, 4, 5, 5, 5, 5, 6, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 7, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 8, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 9, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11
Offset: 1
References
- A. Gardiner, The Mathematical Olympiad Handbook: An Introduction to Problem Solving, Oxford University Press, 1997, reprinted 2011, Pb 4 pp. 54 and 92-93 (1996).
Links
- Giovanni Resta, Table of n, a(n) for n = 1..10000
- British Mathematical Olympiad, 1996 - Problem 4
- Index to sequences related to Olympiads.
Programs
-
Mathematica
Table[Floor[n/Floor[Sqrt[n]]],{n,100}] (* Harvey P. Dale, Sep 22 2011 *)
-
PARI
a(n)=floor(n/sqrtint(n))
-
Python
from math import isqrt def a(n): return n//isqrt(n) print([a(n) for n in range(1, 100)]) # Michael S. Branicky, May 25 2025
Formula
For m = positive integer, terms a(m^2) through a(m^2+m-1) each equal m; terms a(m^2+m) through a(m^2+2m-1) each equal m+1; term a(m^2+2m) equals m+2. - Leroy Quet, Apr 02 2007
a(n) = floor(2*sqrt(n+1)) - floor(sqrt(n)). - Wesley Ivan Hurt, Dec 25 2020
From Natalia L. Skirrow, May 13 2025: (Start)
G.f.: (t_3(x)-1)/(2*x) + psi(x^2)/(1-x) - 2, where t_3(x) (A000122) is Jacobi's third theta function and psi(x) is Ramanujan's psi function.
a(n) = A010052(n+1) + A000194(n+1) = [m is square] + floor((sqrt(4*m)+1)/2) where m=n+1 and [] is the Iverson bracket.
(End)
Comments