OFFSET
1,5
FORMULA
a(n) = Sum_{l=1..floor(n/5)} Sum_{k=l..floor((n-l)/4)} Sum_{j=k..floor((n-k-l)/3)} Sum_{i=j..floor((n-j-k-l)/2)} (c(i) + c(j) + c(k) + c(l) + c(n-i-j-k-l)), where c(x) = [gcd(n,x) = 1] and [ ] is the Iverson bracket.
EXAMPLE
The partitions of 9 into 5 parts are: 1+1+1+1+5, 1+1+1+2+4, 1+1+1+3+3, 1+1+2+2+3, and 1+2+2+2+2. 9 is relatively prime to 1, 2, 4 and 5. Since there are 22 total parts in these partitions that are coprime to 9, a(9) = 22.
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Wesley Ivan Hurt, May 27 2023
STATUS
approved