OFFSET
0,4
COMMENTS
There are no self-conjugate partitions of 2, so we set a(2)=0.
FORMULA
a(n) = r - (s mod 2), where n = r(r+1)/2 + s with 0 <= s <= r; i.e. r = floor((sqrt(8n+1)-1)/2).
MATHEMATICA
r[n_] := Floor[(Sqrt[8n+1]-1)/2]; s[n_] := n-r[n](r[n]+1)/2; a[n_] := r[n]-Mod[s[n], 2]
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Naohiro Nomoto, Feb 05 2002
EXTENSIONS
Edited by Dean Hickerson, Feb 15 2002
STATUS
approved