login
Largest power of 2 <= n^2.
0

%I #16 May 11 2014 18:01:48

%S 1,4,8,16,16,32,32,64,64,64,64,128,128,128,128,256,256,256,256,256,

%T 256,256,512,512,512,512,512,512,512,512,512,1024,1024,1024,1024,1024,

%U 1024,1024,1024,1024,1024,1024,1024,1024,1024,2048,2048,2048,2048,2048,2048

%N Largest power of 2 <= n^2.

%C The first values of n that produce powers of 4 are precisely the powers of 2.

%e a(3) = 8 because 3^2 = 9 and the largest power of 2 <= 9 is 8.

%o (PARI) a(n)=2^(#binary(n^2)-1) \\ _Charles R Greathouse IV_, May 11 2014

%K nonn,easy

%O 1,2

%A _J. Lowell_, May 11 2014