The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A261387 Number of ways to write n = k + m  with 0 < k < m < n such that prime(k) is a primitive root modulo prime(m) and also prime(m) is a primitive root modulo prime(k). 1
 0, 0, 1, 1, 1, 1, 2, 0, 2, 1, 3, 3, 1, 1, 2, 1, 2, 7, 4, 2, 1, 1, 1, 4, 3, 4, 2, 4, 3, 3, 4, 7, 3, 3, 5, 5, 5, 5, 4, 3, 6, 7, 5, 5, 5, 3, 7, 7, 5, 2, 7, 6, 4, 5, 5, 7, 10, 9, 8, 8, 4, 7, 5, 11, 14, 7, 12, 11, 9, 6 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,7 COMMENTS Conjecture: (i) a(n) > 0 except for n = 1, 2, 8. (ii) Any positive rational number r not equal to 1 can be written as m/n, where m and n are positive integers such that prime(m) is a primitive root modulo prime(n) and also prime(n) is a primitive root modulo prime(m). LINKS Zhi-Wei Sun, Table of n, a(n) for n = 1..3000 Zhi-Wei Sun, New observations on primitive roots modulo primes, arXiv:1405.0290 [math.NT], 2014. EXAMPLE a(7) = 2 since 7 = 1+6 = 3+4, prime(1) = 2 is a primitive root modulo prime(6) = 13 and 13 is a primitive root modulo 2, also prime(3) = 5 is a primitive root modulo prime(4) = 7 and 7 is a primitive root modulo 5. a(22) = 1 since 22 = 4+18, prime(4)= 7 is a primitive root modulo prime(18) = 61 and 61 is a primitive root modulo 7. MATHEMATICA f[n_]:=Prime[n] Dv[n_]:=Divisors[n] LL[n_]:=Length[Dv[n]] Do[r=0; Do[Do[If[Mod[f[k]^(Part[Dv[f[n-k]-1], i])-1, f[n-k]]==0, Goto[bb]], {i, 1, LL[f[n-k]-1]-1}]; Do[If[Mod[f[n-k]^(Part[Dv[f[k]-1], i])-1, f[k]]==0, Goto[bb]], {i, 1, LL[f[k]-1]-1}]; r=r+1; Label[bb]; Continue, {k, 1, (n-1)/2}]; Print[n, " ", r]; Continue, {n, 1, 70}] CROSSREFS Cf. A000040, A242748, A259492. Sequence in context: A035373 A240138 A341975 * A197317 A035573 A295689 Adjacent sequences:  A261384 A261385 A261386 * A261388 A261389 A261390 KEYWORD nonn AUTHOR Zhi-Wei Sun, Aug 27 2015 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

Last modified July 28 15:51 EDT 2021. Contains 346335 sequences. (Running on oeis4.)