OFFSET
1,2
COMMENTS
FORMULA
a(n) = max({k : sigma(k) = n*tau(k)} U {0}).
EXAMPLE
a(2) = 3 because 3 is the largest k that satisfies sigma(k)/tau(k) = 2.
a(3) = 6 because 6 is the largest k that satisfies sigma(k)/tau(k) = 3.
a(5) = 0 because no k satisfies sigma(k)/tau(k) = 5.
PROG
(Python)
from sympy import divisor_count, divisor_sigma
def a(n):
max_k = 0
for k in range(1, 4*n*n + 1):
if divisor_sigma(k) == n * divisor_count(k): max_k = k
return max_k
(PARI) a(n) = forstep(k=4*n^2+1, 1, -1, my(f=factor(k)); if (sigma(f)/numdiv(f) == n, return(k))); \\ Michel Marcus, Dec 08 2025
CROSSREFS
KEYWORD
nonn
AUTHOR
Joe Anderson, Dec 07 2025
STATUS
approved
