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!)
A001836 Numbers k such that phi(2k-1) < phi(2k), where phi is Euler's totient function A000010.
(Formerly M5429 N2359)
2

%I M5429 N2359 #49 Sep 23 2023 23:34:02

%S 53,83,158,263,293,368,578,683,743,788,878,893,908,998,1073,1103,1208,

%T 1238,1268,1403,1418,1502,1523,1658,1733,1838,1943,1964,2048,2063,

%U 2153,2228,2243,2258,2363,2393,2423,2468,2558,2573,2633,2657,2678

%N Numbers k such that phi(2k-1) < phi(2k), where phi is Euler's totient function A000010.

%D Jeffrey Shallit, personal communication.

%D N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).

%D N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

%H T. D. Noe, <a href="/A001836/b001836.txt">Table of n, a(n) for n = 1..1000</a>

%H V. L. Klee, Jr., <a href="http://www.jstor.org/stable/2305207">Some remarks on Euler's totient function</a>, Amer. Math. Monthly, 54 (1947), 332.

%H Don Reble, <a href="/A001836/a001836.py.txt">Python program</a>.

%H J. Shallit, <a href="/A001274/a001274.pdf">Letter to N. J. A. Sloane, Jul 17 1975</a>.

%p with(numtheory): A001836:=n->`if`(phi(2*n-1) < phi(2*n), n, NULL): seq(A001836(n), n=1..5*10^3); # _Wesley Ivan Hurt_, Oct 10 2014

%t Select[Range[3000], EulerPhi[2# - 1] < EulerPhi[2#] &] (* _Harvey P. Dale_, Apr 01 2012 *)

%t Position[Partition[EulerPhi[Range[6000]],2],_?(#[[1]]<#[[2]]&),1,Heads-> False]//Flatten (* _Harvey P. Dale_, Jul 02 2021 *)

%o (PARI) is(n)=eulerphi(2*n-1)<eulerphi(2*n) \\ _Charles R Greathouse IV_, Feb 21 2013

%o (Haskell)

%o a001836 n = a001836_list !! (n-1)

%o a001836_list = f a000010_list 1 where

%o f (u:v:ws) x = if u < v then x : f ws (x + 1) else f ws (x + 1)

%o -- _Reinhard Zumkeller_, Jul 11 2014

%o (Python)

%o from sympy import totient

%o def ok(n): return totient(2*n - 1) < totient(2*n) # _Indranil Ghosh_, Apr 29 2017

%Y Cf. A000010, A001837.

%K nonn,nice

%O 1,1

%A _N. J. A. Sloane_

%E Corrected and extended by _Don Reble_, Jan 04 2007

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 April 24 20:08 EDT 2024. Contains 371963 sequences. (Running on oeis4.)