login
A295976
Number of nonnegative solutions to (x,y) = 1 and x^3 + y^3 = n.
3
0, 2, 1, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2
OFFSET
0,2
COMMENTS
Number of ordered pairs of two nonnegative natural numbers that are coprime and whose cubes add to n. - Antti Karttunen, May 31 2021
LINKS
EXAMPLE
For 1729, a(1729) = 4, because the following four ordered pairs, (1,12), (9,10), (10,9) and (12,1) satisfy the condition, as 1^3 + 12^3 = 9^3 + 10^3 = 1729. - Antti Karttunen, May 31 2021
PROG
(PARI) {a(n) = sum(i=0, n, sum(j=0, n, if((gcd(i, j)==1) && (i^3+j^3==n), 1, 0)))}
(PARI) A295976(n) = { my(s=0); for(i=0, oo, i3 = i^3; forstep(j=n-i3, 0, -1, if((i3+j^3==n) && gcd(i, j)==1, s++)); if(i3>n, return(s))); }; \\ Antti Karttunen, May 31 2021
CROSSREFS
Cf. also A202679.
Sequence in context: A331416 A127844 A017877 * A095683 A219481 A361430
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Dec 01 2017
STATUS
approved