login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A082023
Number of partitions of n into 2 parts which are not relatively prime.
6
0, 0, 0, 0, 1, 0, 2, 0, 2, 1, 3, 0, 4, 0, 4, 3, 4, 0, 6, 0, 6, 4, 6, 0, 8, 2, 7, 4, 8, 0, 11, 0, 8, 6, 9, 5, 12, 0, 10, 7, 12, 0, 15, 0, 12, 10, 12, 0, 16, 3, 15, 9, 14, 0, 18, 7, 16, 10, 15, 0, 22, 0, 16, 13, 16, 8, 23, 0, 18, 12, 23, 0, 24, 0, 19, 17, 20, 8, 27, 0, 24, 13, 21, 0, 30, 10, 22
OFFSET
0,7
COMMENTS
a(p) = 0 if p is prime.
LINKS
FORMULA
a(0) = 0; and for n >= 1, a(n) = floor((n-phi(n))/2), where phi(n)=A000010(n) is Euler's totient function. - Dean Hickerson, Apr 22 2003. Clarified by Antti Karttunen, Oct 30 2017
EXAMPLE
a(14) = 4 and the partitions are (12,2), (10,4), (8,6) and (7,7).
a(13) = 0 as for all r + s = 13, r > 0, s > 0, gcd(r,s) = 1.
MATHEMATICA
Array[Floor[(# - EulerPhi[#])/2] &, 87, 0] (* or *)
Table[-1 + Boole[n == 1] + Count[IntegerPartitions[n, 2], _?(! CoprimeQ @@ # &)], {n, 0, 86}] (* Michael De Vlieger, Oct 30 2017 *)
PROG
(PARI) A082023(n) = if(0==n, n, ((n-eulerphi(n))\2)); \\ Antti Karttunen, Oct 30 2017
CROSSREFS
Sequence in context: A055136 A074397 A345039 * A349438 A078152 A339242
KEYWORD
nonn
AUTHOR
Amarnath Murthy, Apr 07 2003
EXTENSIONS
More terms from Antonio G. Astudillo (afg_astudillo(AT)lycos.com), Apr 20 2003
STATUS
approved

  NODES
orte 1
see 1
Story 1