OFFSET
1,8
COMMENTS
Any number n can be written as n=1*n, therefore max{ n-x-y; x>0, y>0, x*y=n } >= -1, with equality for prime numbers. - M. F. Hasler, Dec 29 2012
FORMULA
a(n) = n - A063655(n).
a(n) = max { n-x-y ; x>0, y>0, x*y = n }. - M. F. Hasler, Dec 29 2012
EXAMPLE
a(4) = 0 because 4 = 2*2 and 0 = 4 - 2 - 2.
MAPLE
A220114 := proc(n)
local k, x;
k := {-1} ;
for x in numtheory[divisors](n) do
k := k union {n-x-n/x} ;
end do:
return max(op(k)) ;
end proc: # R. J. Mathar, Jan 08 2013
CROSSREFS
KEYWORD
sign
AUTHOR
Gerasimov Sergey, Dec 06 2012
EXTENSIONS
Corrected by R. J. Mathar, Jan 08 2013
STATUS
approved