|
|
A085623
|
|
Let p = n-th prime; a(n) = number of pairs (i,j) with 0 < i < p, 0 < j < p such that ij == 1 mod p and i and j have opposite parity.
|
|
2
|
|
|
0, 2, 0, 4, 6, 10, 4, 12, 18, 4, 14, 18, 20, 16, 30, 32, 30, 20, 28, 34, 32, 40, 46, 54, 46, 48, 64, 62, 66, 40, 68, 66, 72, 90, 68, 70, 84, 92, 90, 100, 90, 80, 98, 102, 88, 88, 108, 108, 106, 126, 116, 126, 112, 134, 136, 150, 116, 142, 146, 144, 146, 136, 156, 158, 178
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
2,2
|
|
COMMENTS
|
If we let p=2n+1 run through all odd numbers >=3 and consider only i coprime to p, the sequence becomes 0, 2, 0, 4, 4, 6, 0, 10, 4, 4, 12, 14, 8, 18, 4, 12, 12, 14, 8, 18... [R. J. Mathar, Aug 07 2010]
|
|
REFERENCES
|
R. K. Guy, Unsolved Problems in Number Theory, F12.
|
|
LINKS
|
|
|
EXAMPLE
|
For p = 13, the pairs are (2,7), (5,8), (6,11) and their reversals. So a(6) = 6.
|
|
MATHEMATICA
|
f[n_] := Length[ Select[ Mod[ Flatten[ Table[i*j, {j, 2, n - 1}, {i, j - 1, 1, -2}], 1], n], # == 1 & ]]; 2Table[ f[ Prime[n]], {n, 2, 70}]
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,easy
|
|
AUTHOR
|
|
|
EXTENSIONS
|
Removed the "odd" attribute from the primes in the definition (see the offset) - R. J. Mathar, Aug 07 2010
|
|
STATUS
|
approved
|
|
|
|