cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A215937 Numbers n such that 2^n + 1 can be written in the form a^2 + 5*b^2.

This page as a plain text file.
%I A215937 #29 Jan 18 2019 13:42:11
%S A215937 2,3,7,10,11,19,23,31,43,47,50,58,71,79,82,107,127,167,178,179,191,
%T A215937 199,250,290,298,311,347,359,410,487,563,599,683,751,802,890,907,1051
%N A215937 Numbers n such that 2^n + 1 can be written in the form a^2 + 5*b^2.
%C A215937 These 2^n + 1 numbers can only have prime factors of the form 1 (mod 20) or 3 (mod 20) or 5 (mod 20) or 7 (mod 20) or 9 (mod 20) raised to an odd power, but their overall product 2^n+1 can only be 1 (mod 20) or 5 (mod 20) or 9 (mod 20). This statement is limited to odd numbers.
%C A215937 In general,
%C A215937 A number n can be written in the form a^2+5*b^2 if and only if n is 0,
%C A215937 or of the form 2^(2i) 5^j Prod_{p==1 or 9 mod 20} p^k Prod_{q==3 or 7 mod 20) q^(2m)
%C A215937 or of the form 2^(2i+1) 5^j Prod_{p==1 or 9 mod 20} p^k Prod_{q==3 or 7 mod 20) q^(2m+1),
%C A215937 for integers i,j,k,m, for primes p,q.
%H A215937 Samuel S. Wagstaff, Jr., The Cunningham Project, <a href="http://homes.cerias.purdue.edu/~ssw/cun/">Factorizations of 2^n-1, for odd n's < 1200</a>
%e A215937 3 is in the sequence because 2^3 + 1 = 9 can be written as 2^2 + 5 * 1^2 = 9.
%o A215937 (PARI) for(i=2, 500, a=factorint(2^i+1)~; has=0; for(j=1, #a, if(((a[1, j]%20>10)||(i%4<2))&&a[2, j]%2==1, has=1; break)); if(has==0, print(i",")))
%o A215937 (PARI) for(i=2, 500, a=factorint(2^i+1)~; flag=0; flip=0; for(j=1, #a, if(((a[1, j]%20>10))&&a[2, j]%2==1, flag=1); if(((a[1, j]%20==2)||(a[1, j]%20==3)||(a[1, j]%20==7))&&a[2, j]%2==1, flip=flip+1)); if(flag==0&&flip%2==0, print(i",")))
%Y A215937 Cf. A000051, A000978, A215800, A215801.
%Y A215937 Cf. A020669, A033205 (numbers and primes of the form x^2 + 5*y^2).
%K A215937 nonn
%O A215937 1,1
%A A215937 _V. Raman_, Aug 27 2012
%E A215937 Terms corrected by _V. Raman_, Sep 20 2012