cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A216157 Difference between the sum of the even divisors and the sum of the odd divisors of phi(n).

Original entry on oeis.org

1, 1, 5, 1, 4, 5, 4, 5, 6, 5, 20, 4, 13, 13, 29, 4, 13, 13, 20, 6, 12, 13, 30, 20, 13, 20, 40, 13, 24, 29, 30, 29, 52, 20, 65, 13, 52, 29, 78, 20, 32, 30, 52, 12, 24, 29, 32, 30, 61, 52, 70, 13, 78, 52, 65, 40, 30, 29, 120, 24, 65, 61, 116, 30, 48, 61, 60, 52
Offset: 3

Views

Author

Michel Lagneau, Sep 02 2012

Keywords

Comments

phi(n) : A000010 is the Euler totient function, and even for n > 2.
If n prime, phi(n) = n-1 and a(n) = a((n-1)/2).

Examples

			a(13) = 20 because the divisors of phi(13) = 12 are {1, 2, 3, 4, 6, 12} and (12 + 6 + 4 +2) - (3 + 1) = 20.
		

Crossrefs

Programs

  • Maple
    with(numtheory):for n from 3 to 100 do:x:=divisors(phi(n)):n1:=nops(x):s0:=0:s1:=0:for m from 1 to n1 do: if irem(x[m],2)=0 then s0:=s0+x[m]:else s1:=s1+x[m]:fi:od:if s0>s1  then printf(`%d, `,s0-s1):else fi:od:
  • Mathematica
    Table[Total[Select[Divisors[EulerPhi[n]], EvenQ[#]&]]-Total[Select[Divisors[EulerPhi[n]], OddQ[#]&]], {n,3,80}]