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!)
A087964 a(n) is the least prime p such that exponent of highest power of 2 dividing 3p+1 equals n. 1

%I #23 Aug 28 2020 02:37:14

%S 3,17,13,5,53,149,1237,1109,853,2389,3413,17749,128341,70997,251221,

%T 415061,218453,2708821,27088213,29709653,3495253,85284181,13981013,

%U 39146837,794121557,1498764629,492131669,626349397,13779686741

%N a(n) is the least prime p such that exponent of highest power of 2 dividing 3p+1 equals n.

%H Giovanni Resta, <a href="/A087964/b087964.txt">Table of n, a(n) for n = 1..1000</a>

%F a(n) = A000040(Min{x; A007814(1 + 3*A000040(x)) = n}).

%e p = 218453 is the first prime so that 3*p+1 = 655360 = (2^18)*5 has 18 as exponent of 2 in 3p+1, thus a(18) = 218453.

%p f:= proc(n)

%p local m,t,p;

%p t:= 2^n;

%p for m from 1 + 4*(n mod 2) by 6 do

%p p:= (t*m-1)/3;

%p if isprime(p) then return p fi

%p od

%p end proc:

%p map(f, [$1..100]); # _Robert Israel_, Nov 18 2017

%t a[n_] := Module[{m, t = 2^n, p}, For[m = 1 + 4 Mod[n, 2], True, m += 6, p = (t m - 1)/3; If[PrimeQ[p], Return[p]]]];

%t Array[a, 100] (* _Jean-François Alcover_, Aug 28 2020, after _Robert Israel_ *)

%Y Cf. A087272, A087273, A087274, A007814, A087230, A087963.

%K nonn

%O 1,1

%A _Labos Elemer_, Sep 18 2003

%E More terms from _Ray Chandler_, Sep 21 2003

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 19 11:14 EDT 2024. Contains 371791 sequences. (Running on oeis4.)