A141184 Duplicate of A033212.
19, 31, 61, 79, 109, 139, 151, 181, 199, 211, 229, 241, 271, 331
Offset: 1
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.
[p: p in PrimesUpTo(1400) | p mod 12 in {1}]; // Vincenzo Librandi, Jul 14 2012 For other programs see the "Binary Quadratic Forms and OEIS" link.
select(isprime, [seq(i,i=1..10000, 12)]); # Robert Israel, Nov 27 2015
Select[Prime/@Range[250], Mod[ #, 12]==1&] Select[Range[13, 10^4, 12], PrimeQ] (* Zak Seidov, Mar 21 2011 *)
for(i=1,250, if(prime(i)%12==1, print(prime(i))))
forstep(p=13,10^4,12,isprime(p)&print(p)); \\ Zak Seidov, Mar 21 2011
Union[QuadPrimes2[7, 4, 52, 10000], QuadPrimes2[7, -4, 52, 10000]] (* see A106856 *)
Select[Prime[Range[200]], JacobiSymbol[#,15]==1&]
is(p)=kronecker(p,15)==1&&isprime(p) \\ M. F. Hasler, Jan 15 2016
a(1)=1 because the primes represented by x^2+xy+y^2 are the same as the primes represented by x^2 + 3*y^2 (see A007645). The known pairs (n,m) are the following (checked for range n<=200 and m<=500): n={1, 4, 4, 6, 6, 7, 8, 8, 10, 10, 10, 14, 14, 14, 16, 18, 22, 22, 26, 38, 38} m={3, 9, 12, 8, 16, 15, 45, 60, 24, 48, 72, 24, 48, 72, 21, 40, 120, 240, 168, 120, 240}.
f = 200; g = 300; h = 30; j = 100; b = {}; Do[a = {}; Do[Do[If[PrimeQ[x^2 + n y^2], AppendTo[a, x^2 + n y^2]], {x, 0, g}], {y, 1, g}]; AppendTo[b, Take[Union[a], h]], {n, 1, f}]; Print[b]; c = {}; Do[a = {}; Do[Do[If[PrimeQ[n^2 + w*n*m + m^2], AppendTo[a, n^2 + w*n*m + m^2]], {n, m, g}], {m, 1, g}]; AppendTo[c, Take[Union[a], h]], {w, 1, j}]; Print[c]; bb = {}; cc = {}; Do[Do[If[b[[p]] == c[[q]], AppendTo[bb, p]; AppendTo[cc, q]], {p, 1, f}], {q, 1, j}]; Union[cc] (*Artur Jasinski*)
[p: p in PrimesUpTo(647) | KroneckerSymbol(p, 30) eq 1]; // Vincenzo Librandi, Sep 11 2012
Select[Prime[Range[200]], JacobiSymbol[#,30]==1&]
is(n)=isprime(n) && kronecker(n,30)==1 \\ Charles R Greathouse IV, Jul 12 2016
Let |I| be the norm of an ideal I, then: |(2, (1+sqrt(-15))/2)| = |(2, (1-sqrt(-15))/2)| = 2; |(3, sqrt(-15))| = 3; |(5, sqrt(-15))| = 5; |(17, 7+4*sqrt(-15))| = |(17, 7-4*sqrt(-15))| = 17; |(2 + sqrt(-15))| = |(2 - sqrt(-15))| = 19; |(23, 17+4*sqrt(-15))| = |(23, 17-4*sqrt(-15))| = 23; |(4 + sqrt(-15))| = |(4 - sqrt(-15))| = 31.
isA341786(n) = my(disc=-15); (isprime(n) && kronecker(disc,n)>=0) || (issquare(n, &n) && isprime(n) && kronecker(disc,n)==-1)
19 is a member because we can write 19=4*2^2+4*2*1-5*1^2 (or 19=4*1^2+12*1*1+3*1^2).
[3] cat [ p: p in PrimesUpTo(3000) | p mod 24 in {19 } ]; // Vincenzo Librandi, Jul 24 2012
QuadPrimes2[3, 0, 16, 10000] (* see A106856 *)
list(lim)=my(v=List(),w,t); for(x=1, sqrtint(lim\3), w=3*x^2; for(y=0, sqrtint((lim-w)\16), if(isprime(t=w+16*y^2), listput(v,t)))); Set(v) \\ Charles R Greathouse IV, Feb 09 2017
QuadPrimes2[2, 1, 2, 100000] (* see A106856 *)
{ fc(a,b,c,M) = my(p,t1,t2,n); t1 = listcreate(); for(n=1,M, p = prime(n); t2 = qfbsolve(Qfb(a,b,c),p); if(t2 == 0,, listput(t1,p))); print(t1); } fc(2,1,2,1000); \\ N. J. A. Sloane, Jun 06 2014
Comments
References
Links
Crossrefs
Programs
Mathematica
PARI
Extensions