A367328 The x-coordinate of the point where x + y = n, x and y are integers and x/y is as close as possible to e.
0, 1, 2, 3, 3, 4, 5, 6, 6, 7, 8, 9, 9, 10, 11, 12, 12, 13, 14, 15, 15, 16, 17, 18, 18, 19, 20, 20, 21, 22, 23, 23, 24, 25, 26, 26, 27, 28, 28, 29, 30, 31, 31, 32, 33, 34, 34, 35, 36, 37, 37, 38, 39, 39, 40, 41, 42, 42, 43, 44, 45, 45, 46, 47, 48, 48, 49, 50
Offset: 1
Examples
For n = 3, the possible points are (0,3), (1,2), (2,1) as any negative value would would be further from e than 0/3. The closest value to e out of these is 2/1 so a(3) = 2.
Formula
a(n) is always either ceiling(n*e/(1 + e)) or floor(n*e/(1 + e)) = A076538(n).
Comments