|
|
A001494
|
|
Numbers k such that phi(k) = phi(k+2).
(Formerly M3293 N1328)
|
|
17
|
|
|
4, 7, 8, 10, 26, 32, 70, 74, 122, 146, 308, 314, 386, 512, 554, 572, 626, 635, 728, 794, 842, 910, 914, 1015, 1082, 1226, 1322, 1330, 1346, 1466, 1514, 1608, 1754, 1994, 2132, 2170, 2186, 2306, 2402, 2426, 2474, 2590, 2642, 2695, 2762, 2906, 3242, 3314
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
If p and 2p-1 are odd primes then 2*(2p-1) is a solution of the equation. Other terms (7,8,32,70,...) are not of this form.
There are 506764111 terms under 10^12. - Jud McCranie, Feb 13 2012
If 2^(2^m) + 1 is a Fermat prime in A019434, so, m = 0, 1, 2, 3, 4, then k = 2^(2^m + 1) is a term; this subsequence consists of {4, 8, 32, 512, 131072} and, in this case, phi(k) = phi(k+2) = 2^(2^m). - Bernard Schott, Apr 22 2022
|
|
REFERENCES
|
D. M. Burton, Elementary Number Theory, section 7-2.
R. K. Guy, Unsolved Problems Number Theory, Sect. B36.
N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
|
|
LINKS
|
|
|
FORMULA
|
|
|
MAPLE
|
with(numtheory): P:=proc(n) if phi(n)=phi(n+2) then n;
|
|
MATHEMATICA
|
Select[Range[3500], EulerPhi[#]==EulerPhi[#+2]&] (* Harvey P. Dale, Apr 24 2011 *)
Flatten[Position[Partition[EulerPhi[Range[3500]], 3, 1], _?(#[[1]]==#[[3]]&), {1}, Heads->False]] (* This program is more efficient than the first program above because it only has to calculate phi of each number once. *) (* Harvey P. Dale, Aug 20 2014 *)
SequencePosition[EulerPhi[Range[4300]], {x_, _, x_}][[All, 1]] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Sep 04 2020 *)
|
|
PROG
|
(PARI) op=[0, c=0]; for( n=1, 1e7, if( op[bittest(n, 0)+1]+0==op[bittest(n, 0)+1]=eulerphi(n), write("b001494.txt", c++, " "n-2))) \\ M. F. Hasler, Jan 05 2011
(Haskell)
import Data.List (elemIndices)
a001494 n = a001494_list !! (n-1)
a001494_list = map (+ 1) $ elemIndices 0 $
zipWith (-) (drop 2 a000010_list) a000010_list
(Magma) [n: n in [1..4000] | EulerPhi(n) eq EulerPhi(n+2)]; // Vincenzo Librandi, Sep 07 2016
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,nice
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|