The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A068494 a(n) = n mod phi(n). 10

%I #38 Aug 03 2023 16:14:27

%S 0,0,1,0,1,0,1,0,3,2,1,0,1,2,7,0,1,0,1,4,9,2,1,0,5,2,9,4,1,6,1,0,13,2,

%T 11,0,1,2,15,8,1,6,1,4,21,2,1,0,7,10,19,4,1,0,15,8,21,2,1,12,1,2,27,0,

%U 17,6,1,4,25,22,1,0,1,2,35,4,17,6,1,16,27,2,1,12,21,2,31,8,1,18,19,4

%N a(n) = n mod phi(n).

%C By Lehmer's Conjecture, when n > 2 then a(n) = 1 if and only if n is prime. The Notices article states "Lehmer's Conjecture (1932). phi(n) | (n-1) if and only if n is prime." - _Michael Somos_, Oct 14 2011

%H Reinhard Zumkeller, <a href="/A068494/b068494.txt">Table of n, a(n) for n = 1..10000</a>

%H D. H. Bailey and J. M. Borwein, <a href="http://www.ams.org/notices/201110/rtx111001410p.pdf">Exploratory Experimentation and Computation</a>, Notices of A. M. S. 58 (2011) 1410-1419, see p. 1416.

%F b^(n - a(n)) == 1 (mod n) for every b coprime to n. - _Thomas Ordowski_, Jun 30 2017

%t Table[Mod[n, EulerPhi[n]], {n, 100}] (* _Alonso del Arte_, Feb 15 2013 *)

%o (PARI) for(n=1,150,print1(n%eulerphi(n),","))

%o (PARI) {a(n) = n % eulerphi(n)}; /* _Michael Somos_, Oct 14 2011 */

%o (Haskell)

%o a068494 n = mod n $ a000010 n -- _Reinhard Zumkeller_, Oct 14 2011

%o (Magma) [n mod EulerPhi(n): n in [1..100]]; // _Vincenzo Librandi_, Jul 19 2015

%Y Positions of particular numbers: 0: A007694, 1 (conjectured): A065091, 3: A350777\{1, 2, 3}.

%Y Cf. A055516.

%K easy,nonn

%O 1,9

%A _Benoit Cloitre_, Mar 11 2002

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 5 14:50 EDT 2024. Contains 373107 sequences. (Running on oeis4.)