# [seqfan] Re: A088144 and A076409

Richard Guy rkg at cpsc.ucalgary.ca
Wed Feb 23 18:58:05 CET 2011

```Dear JM Bergot,
the seqfan network, as there are one or
two things they may like to add to OEIS.

The sum of the primitive roots
of  p  (A088144) is a multiple of  p  whenever
p  is of shape  4k+1.  This is because the
primitive roots come in pairs,  r  and  p-r,
and their number is  phi(phi(p)) = phi(p-1),
and the total is  p * phi(p-1) / 2,  though I
didn't see that this was mentioned in  A088144.
The sum is also a multiple of  p  for  p = 19;
are there other examples?  Searching for the
sequence  5, 13, 17, 19, 29, ... didn't give
any hits.  Perhaps it would be of interest to
list the subsequence

2 = 1*3 - 1,  8 = 1*7 + 1,  23 = 2*11 + 1,
57 = 3*19,  139 = 6*23 + 1,  123 = 4*31 - 1,
257 = 6*43 - 1,  612 = 13*47 + 1, 886 = 15*59 + 1,
669 = 10*67 - 1, 1064 = 15*71 - 1, 1105 = 14*79 - 1,
1744 = 21*83 + 1, ...

and of the coefficients

1, 1, 2, 3, 6, 4, 6, 13, 15, 10, 15, 10, 14, 21, ...

and even the ``errors''

-1, 1, 1, 0, 1, -1, -1, 1, 1, -1, -1, -1, 1, ...
(are there any more zeroes? or any terms other
than 1 & -1 ?)

sum of the primitive roots is equal to the sum
of the quadratic residues (A076409) for  p = 5
and  p = 17  and perhaps (only?) for the Fermat
primes.  Here it IS mentioned that the sum is
k(4k+1)  when  p= 4k+1  and  A076410  confirms
that the sum is always a multiple of  p, though
it would be good to mention this at A076409.

Best,   R.

On Mon, 21 Feb 2011, JM Bergot wrote:

> Do you think it is possible for:
> (1)The sum of the primitive roots of some
>      prime p is divisible by p.
>
> (2)The sum of the quadratic residues for
>      some prime p is the same as the sum
>      of its primitive roots, say for some p
>     of the form 2*q+1=p for prime q.
```