|
|
A022846
|
|
Nearest integer to n*sqrt(2).
|
|
18
|
|
|
0, 1, 3, 4, 6, 7, 8, 10, 11, 13, 14, 16, 17, 18, 20, 21, 23, 24, 25, 27, 28, 30, 31, 33, 34, 35, 37, 38, 40, 41, 42, 44, 45, 47, 48, 49, 51, 52, 54, 55, 57, 58, 59, 61, 62, 64, 65, 66, 68, 69, 71, 72, 74, 75, 76, 78, 79, 81, 82, 83, 85, 86, 88, 89, 91, 92, 93, 95, 96
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
COMMENTS
|
Let R(i,j) be the rectangle with antidiagonals 1; 2,3; 4,5,6; ...; n^2 is in antidiagonal number a(n). Proof: n^2 is in antidiagonal m iff A000217(m-1)< n^2 <=A000217(m), where A000217(m)=m*(m+1)/2. So m = A002024(n^2) = round(n*sqrt(2)) = a(n). - Antonio G. Astudillo (afg_astudillo(AT)hotmail.com), Mar 07 2003
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
n = 4, n^2 = 16; 0, 1, 3, 6, 10, 15 are triangular numbers in interval [0, 16); a(4) = 6. - Philippe Deléham, Mar 08 2013
|
|
MATHEMATICA
|
|
|
PROG
|
(PARI) a(n)=round(n*sqrt(2))
(Haskell)
a022846 = round . (* sqrt 2) . fromIntegral
(Python)
from math import isqrt
|
|
CROSSREFS
|
Cf. A063957 (complement of this set).
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|