A003984 Table of max(x,y), where (x,y) = (0,0),(0,1),(1,0),(0,2),(1,1),(2,0),...
0, 1, 1, 2, 1, 2, 3, 2, 2, 3, 4, 3, 2, 3, 4, 5, 4, 3, 3, 4, 5, 6, 5, 4, 3, 4, 5, 6, 7, 6, 5, 4, 4, 5, 6, 7, 8, 7, 6, 5, 4, 5, 6, 7, 8, 9, 8, 7, 6, 5, 5, 6, 7, 8, 9, 10, 9, 8, 7, 6, 5, 6, 7, 8, 9, 10, 11, 10, 9, 8, 7, 6, 6, 7, 8, 9, 10, 11, 12, 11, 10, 9, 8, 7, 6, 7, 8, 9, 10, 11, 12, 13, 12, 11, 10, 9, 8, 7, 7, 8
Offset: 0
Examples
Top left corner of array: 0 1 2 3 1 1 2 3 2 2 2 3 3 3 3 3
Formula
From Franklin T. Adams-Watters, Feb 06 2006: (Start)
G.f.: (x+y-3xy+x^2 y^2)/((1-x)^2 (1-y)^2 (1-xy)).
a(n) = (1/2)*(t - 1 + abs(t^2 - 2*n - 1)), where t = floor(sqrt(2*n+1)+1/2). - Ridouane Oudra, May 03 2019