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.

Showing 1-10 of 19 results. Next

A155565 Intersection of A001481 and A020669: N = a^2 + b^2 = c^2 + 5d^2 for some integers a,b,c,d.

Original entry on oeis.org

0, 1, 4, 5, 9, 16, 20, 25, 29, 36, 41, 45, 49, 61, 64, 80, 81, 89, 100, 101, 109, 116, 121, 125, 144, 145, 149, 164, 169, 180, 181, 196, 205, 225, 229, 241, 244, 245, 256, 261, 269, 281, 289, 305, 320, 324, 349, 356, 361, 369, 389, 400, 401, 404, 405, 409, 421
Offset: 1

Views

Author

M. F. Hasler, Jan 25 2009

Keywords

Comments

Contains A155575 as a subsequence (obtained by restricting a,b,c,d to be nonzero). Also contains A000290 (squares) as subsequence.

Crossrefs

Programs

  • PARI
    isA155565(n,/* use optional 2nd arg to get other analogous sequences */c=[5,1]) = { for(i=1,#c, for(b=0,sqrtint(n\c[i]), issquare(n-c[i]*b^2) & next(2)); return);1}
    for( n=1,500, isA155565(n) & print1(n","))

A155567 Intersection of A002479 and A020669 : N = a^2 + 2b^2 = c^2 + 5d^2 for some integers a,b,c,d.

Original entry on oeis.org

0, 1, 4, 6, 9, 16, 24, 25, 36, 41, 49, 54, 64, 81, 86, 89, 96, 100, 121, 129, 134, 144, 150, 164, 166, 169, 196, 201, 214, 216, 225, 241, 246, 249, 256, 281, 289, 294, 321, 324, 326, 344, 356, 361, 369, 384, 400, 401, 409, 441, 449, 454, 484, 486, 489, 516, 521
Offset: 1

Views

Author

M. F. Hasler, Jan 25 2009

Keywords

Comments

Contains A155577 as a subsequence (obtained by restricting a,b,c,d to be nonzero). Also contains A000290 (squares) as subsequence.

Crossrefs

Programs

  • PARI
    isA155567(n,/* use optional 2nd arg to get other analogous sequences */c=[5,2]) = { for(i=1,#c, for(b=0,sqrtint(n\c[i]), issquare(n-c[i]*b^2) & next(2)); return);1}
    for( n=1,600, isA155567(n) & print1(n","))

A155570 Intersection of A003136 and A020669: N = a^2 + 3b^2 = c^2 + 5d^2 for some integers a,b,c,d.

Original entry on oeis.org

0, 1, 4, 9, 16, 21, 25, 36, 49, 61, 64, 81, 84, 100, 109, 121, 129, 144, 169, 181, 189, 196, 201, 225, 229, 241, 244, 256, 289, 301, 309, 324, 336, 349, 361, 381, 400, 409, 421, 436, 441, 469, 484, 489, 516, 525, 529, 541, 549, 576, 601, 625, 661, 669, 676, 709
Offset: 1

Views

Author

M. F. Hasler, Jan 25 2009

Keywords

Comments

Contains A155710 as a subsequence (obtained by restricting a,b,c,d to be nonzero). Also contains A000290 (squares) as subsequence.

Crossrefs

Programs

  • PARI
    isA155570(n,/* use optional 2nd arg to get other analogous sequences */c=[5,3]) = { for(i=1,#c, for(b=0,sqrtint(n\c[i]), issquare(n-c[i]*b^2) & next(2)); return);1}
    for( n=0,800, isA155570(n) & print1(n","))

A302982 Number of ways to write n as x^2 + 5*y^2 + 2^z + 3*2^w with x,y,z,w nonnegative integers.

Original entry on oeis.org

0, 0, 0, 1, 2, 1, 2, 4, 3, 3, 5, 4, 6, 7, 4, 7, 5, 4, 7, 8, 5, 5, 8, 5, 9, 7, 6, 13, 10, 7, 9, 10, 7, 12, 11, 8, 11, 7, 7, 11, 11, 6, 11, 13, 6, 10, 7, 7, 17, 13, 6, 13, 14, 9, 11, 18, 10, 13, 14, 11
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 16 2018

Keywords

Comments

Conjecture: a(n) > 0 for all n > 3.
Clearly, a(4*n) > 0 if a(n) > 0. We have verified a(n) > 0 for all n = 4..2*10^8.
See also A302983 and A302984 for similar conjectures.

Examples

			a(4) = 1 with 4 = 0^2 + 5*0^2 + 2^0 + 3*2^0.
a(5) = 2 with 5 =  1^2 + 5*0^2 + 2^0 + 3*2^0 = 0^2 + 5*0^2 + 2^1 + 3*2^0.
a(6) = 1 with 6 = 1^2 + 3*0^2 + 2^1 + 3*2^0.
		

Crossrefs

Programs

  • Mathematica
    SQ[n_]:=SQ[n]=IntegerQ[Sqrt[n]];
    tab={};Do[r=0;Do[If[SQ[n-3*2^k-2^j-5x^2],r=r+1],{k,0,Log[2,n/3]},{j,0,If[n==3*2^k,-1,Log[2,n-3*2^k]]},{x,0,Sqrt[(n-3*2^k-2^j)/5]}];tab=Append[tab,r],{n,1,60}];Print[tab]

A055664 Norms of Eisenstein-Jacobi primes.

Original entry on oeis.org

3, 4, 7, 13, 19, 25, 31, 37, 43, 61, 67, 73, 79, 97, 103, 109, 121, 127, 139, 151, 157, 163, 181, 193, 199, 211, 223, 229, 241, 271, 277, 283, 289, 307, 313, 331, 337, 349, 367, 373, 379, 397, 409, 421, 433, 439, 457, 463, 487, 499, 523, 529, 541, 547, 571
Offset: 1

Views

Author

N. J. A. Sloane, Jun 09 2000

Keywords

Comments

These are the norms of the primes in the ring of integers a+b*omega, a and b rational integers, omega = (1+sqrt(-3))/2.
Let us say that an integer n divides a lattice if there exists a sublattice of index n. Example: 3 divides the hexagonal lattice. Then A003136 (Loeschian numbers) is the sequence of divisors of the hexagonal lattice. Say that n is a "prime divisor" if the index-n sublattice is not contained in any other sublattice except the original lattice itself. The present sequence gives the prime divisors of the hexagonal lattice. Similarly, A055025 (Norms of Gaussian primes) is the sequence of "prime divisors" of the square lattice. - Jean-Christophe Hervé, Dec 04 2006

Examples

			There are 6 Eisenstein-Jacobi primes of norm 3, omega-omega^2 times one of the 6 units [ +-1, +-omega, +-omega^2 ] but only one up to equivalence.
		

References

  • R. K. Guy, Unsolved Problems in Number Theory, A16.
  • L. W. Reid, The Elements of the Theory of Algebraic Numbers, MacMillan, NY, 1910, see Chap. VI.

Crossrefs

Cf. A055665-A055668, A055025-A055029, A135461, A135462. See A004016 and A035019 for theta series of Eisenstein (or hexagonal) lattice.
The Z[sqrt(-5)] analogs are in A020669, A091727, A091728, A091729, A091730 and A091731.

Programs

  • Mathematica
    Join[{3}, Select[Range[600], (PrimeQ[#] && Mod[#, 6] == 1) || (PrimeQ[Sqrt[#]] && Mod[Sqrt[#], 3] == 2) & ]] (* Jean-François Alcover, Oct 09 2012, from formula *)
  • PARI
    is(n)=(isprime(n) && n%3<2) || (issquare(n,&n) && isprime(n) && n%3==2) \\ Charles R Greathouse IV, Apr 30 2013

Formula

Consists of 3; rational primes == 1 (mod 3) [A002476]; and squares of rational primes == -1 (mod 3) [A003627^2].

Extensions

More terms from David Wasserman, Mar 21 2002

A033205 Primes of form x^2 + 5*y^2.

Original entry on oeis.org

5, 29, 41, 61, 89, 101, 109, 149, 181, 229, 241, 269, 281, 349, 389, 401, 409, 421, 449, 461, 509, 521, 541, 569, 601, 641, 661, 701, 709, 761, 769, 809, 821, 829, 881, 929, 941, 1009, 1021, 1049, 1061, 1069, 1109, 1129, 1181, 1201, 1229, 1249, 1289, 1301, 1321, 1361, 1381, 1409, 1429, 1481, 1489
Offset: 1

Views

Author

Keywords

Comments

It is a classical result that p is of the form x^2 + 5y^2 if and only if p = 5 or p == 1 or 9 mod 20 (see Cox, page 33). - N. J. A. Sloane, Sep 20 2012
Except for 5, also primes of the form x^2 + 25y^2. See A140633. - T. D. Noe, May 19 2008
Or, 5 and all primes p that divide Fibonacci((p - 1)/2) = A121568(n). - Alexander Adamchuk, Aug 07 2006

References

  • David A. Cox, "Primes of the Form x^2 + n y^2", Wiley, 1989; see p. 33.

Crossrefs

Subsequence of A091729.
Primes in A020669 (numbers of form x^2+5y^2). Cf. A121568, A139643, A216815.
Cf. A029718, A106865 (in the same genus).

Programs

  • Magma
    [p: p in PrimesUpTo(2000) | NormEquation(5,p) eq true]; // Bruno Berselli, Jul 03 2016
    
  • Mathematica
    QuadPrimes2[1, 0, 5, 10000] (* see A106856 *)
  • PARI
    is(n)=my(k=n%20); n==5 || ((k==9 || k==9) && isprime(n)) \\ Charles R Greathouse IV, Feb 09 2017

Formula

A020669 INTERSECT A000040.
a(n) ~ 4n log n. - Charles R Greathouse IV, Nov 09 2012

A154778 Numbers of the form a^2 + 5b^2 with positive integers a,b.

Original entry on oeis.org

6, 9, 14, 21, 24, 29, 30, 36, 41, 45, 46, 49, 54, 56, 61, 69, 70, 81, 84, 86, 89, 94, 96, 101, 105, 109, 116, 120, 126, 129, 134, 141, 144, 145, 149, 150, 161, 164, 166, 174, 180, 181, 184, 189, 196, 201, 205, 206, 214, 216, 224, 225, 229, 230, 241, 244, 245, 246
Offset: 1

Views

Author

M. F. Hasler, Jan 24 2009

Keywords

Comments

Subsequence of A020669 (which allows for a=0 and/or b=0). See there for further references. See A155560 ff for intersection of sequences of type (a^2 + k b^2).
Also, subsequence of A000408 (with 5b^2 = b^2 + (2b)^2).

Examples

			a(1) = 6 = 1^2 + 5*1^2 is the least number that can be written as A+5B where A,B are positive squares.
a(2) = 9 = 2^2 + 5*1^2 is the second smallest number that can be written in this way.
		

Crossrefs

Cf. A033205 (subsequence of primes). [From R. J. Mathar, Jan 26 2009]

Programs

  • Mathematica
    formQ[n_] := Reduce[a > 0 && b > 0 && n == a^2 + 5 b^2, {a, b}, Integers] =!= False; Select[ Range[300], formQ] (* Jean-François Alcover, Sep 20 2011 *)
    Timing[mx = 300; limx = Sqrt[mx]; limy = Sqrt[mx/5]; Select[Union[Flatten[Table[x^2 + 5 y^2, {x, limx}, {y, limy}]]], # <= mx &]] (* T. D. Noe, Sep 20 2011 *)
  • PARI
    isA154778(n,/* use optional 2nd arg to get other analogous sequences */c=5) = { for( b=1,sqrtint((n-1)\c), issquare(n-c*b^2) & return(1))}
    for( n=1,300, isA154778(n) & print1(n","))

A002481 Numbers of form x^2 + 6y^2.

Original entry on oeis.org

0, 1, 4, 6, 7, 9, 10, 15, 16, 22, 24, 25, 28, 31, 33, 36, 40, 42, 49, 54, 55, 58, 60, 63, 64, 70, 73, 79, 81, 87, 88, 90, 96, 97, 100, 103, 105, 106, 112, 118, 121, 124, 127, 132, 135, 144, 145, 150, 151, 154, 159, 160, 166, 168, 169, 175, 177, 186, 193, 196, 198, 199, 202, 214
Offset: 1

Views

Author

Keywords

Comments

Norms of numbers in Z[sqrt(-6)]. - Alonso del Arte, Sep 23 2014
It seems that a positive integer n is in this sequence if and only if the p-adic order ord_p(n) of n is even for any prime p with floor(p/12) odd, and the number of prime divisors p == 5 or 11 (mod 24) with ord_p(n) odd has the same parity with ord_2(n) + ord_3(n). - Zhi-Wei Sun, Mar 24 2018

References

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

Crossrefs

Programs

  • Maple
    N:= 10^4: # to get all terms <= N
    {seq(seq(a^2 + 6*b^2, a = 0 .. floor(sqrt(N-6*b^2))), b = 0 .. floor(sqrt(N/6)))};
    # for Maple 11, or earlier, uncomment the next line
    # sort(convert(%,list));  # Robert Israel, Sep 24 2014
  • Mathematica
    lim = 10^4; k = 6; Union@Flatten@Table[x^2 + k * y^2, {y, 0, Sqrt[lim/k]}, {x, 0, Sqrt[lim - k * y^2]}] (* Zak Seidov, Mar 30 2011 *)

A106865 Primes of the form 2x^2 + 2xy + 3y^2.

Original entry on oeis.org

2, 3, 7, 23, 43, 47, 67, 83, 103, 107, 127, 163, 167, 223, 227, 263, 283, 307, 347, 367, 383, 443, 463, 467, 487, 503, 523, 547, 563, 587, 607, 643, 647, 683, 727, 743, 787, 823, 827, 863, 883, 887, 907, 947, 967, 983, 1063, 1087, 1103, 1123, 1163, 1187
Offset: 1

Views

Author

T. D. Noe, May 09 2005

Keywords

Comments

Discriminant = -20.
Also: Primes of the form 2x^2 - 2xy + 3y^2 with x and y nonnegative. Cf. A106864.
Primes congruent to 2, 3, 7 modulo 20. - Michael Somos, Aug 13 2006
In Z[sqrt(-5)], these numbers are irreducible but not prime. In terms of ideals, they generate principal ideals that are not prime (or maximal). The equation x^2 + 5y^2 = a(n) has no solutions, but x^2 = -5 (mod a(n)) does. For example, 2 * 3 = (1 - sqrt(-5))(1 + sqrt(-5)) and 7 * 23 = (9 - 4*sqrt(-5))(9 + 4*sqrt(-5)). - Alonso del Arte, Dec 19 2015

Examples

			x = 1, y = 1 gives 2x^2 + 2xy + 3y^2 = 2 + 2 + 3 = 7.
x = 1, y = -3 gives 2x^2 + 2xy + 3y^2 = 2 - 6 + 27 = 23.
		

References

  • David A. Cox, "Primes of the Form x^2 + n y^2", Wiley, 1989; see p. 33.

Crossrefs

For n > 1, a(n) = A122870(n-1). Cf. A122870, A106864.

Programs

  • Maple
    select(isprime, [2, seq(seq(5+s+20*i,s=[-2,2]),i=0..10^3)]); # Robert Israel, Dec 23 2015
  • Mathematica
    QuadPrimes2[2, -2, 3, 10000] (* see A106856 *)
  • PARI
    is(n)=isprime(n) && #qfbsolve(Qfb(2,2,3),n)>0 \\ Charles R Greathouse IV, Feb 09 2017

Formula

Complement(A000040, A020669).

A033718 Product theta3(q^d); d | 5.

Original entry on oeis.org

1, 2, 0, 0, 2, 2, 4, 0, 0, 6, 0, 0, 0, 0, 4, 0, 2, 0, 0, 0, 2, 8, 0, 0, 4, 2, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 4, 0, 0, 0, 6, 4, 0, 0, 6, 0, 0, 0, 0, 8, 0, 4, 0, 0, 0, 0, 4, 0, 0, 2, 0, 0, 0, 0, 8, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 10, 0, 0, 8, 0, 4, 0, 0, 4, 0, 0, 0, 0, 4, 0, 4, 0, 0, 0, 2, 4, 0, 0, 0, 8, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 4, 2, 0, 0, 0, 2, 12
Offset: 0

Views

Author

Keywords

Comments

Ramanujan theta functions: f(q) := Product_{k>=1} (1-(-q)^k) (see A121373), phi(q) := theta_3(q) := Sum_{k=-oo..oo} q^(k^2) (A000122), psi(q) := Sum_{k>=0} q^(k*(k+1)/2) (A010054), chi(q) := Product_{k>=0} (1+q^(2k+1)) (A000700).
Number of representations of n as a sum of five times a square and a square. - Ralf Stephan, May 14 2007

References

  • J. H. Conway and N. J. A. Sloane, "Sphere Packings, Lattices and Groups", Springer-Verlag, p 102 eq 9.

Crossrefs

Programs

  • Maple
    S:= series(JacobiTheta3(0,q)*JacobiTheta3(0,q^5), q, 1001):
    seq(coeff(S,q,j),j=0..1000); # Robert Israel, Dec 22 2015
  • Mathematica
    terms = 127; s = EllipticTheta[3, 0, q] EllipticTheta[3, 0, q^5] + O[q]^terms; CoefficientList[s, q] (* Jean-François Alcover, Jul 04 2017 *)
  • PARI
    {a(n)=if(n<1, n==0, qfrep([1,0;0,5],n)[n]*2)} /* Michael Somos, Aug 13 2006 */
    
  • PARI
    N=666;  x='x+O('x^N);
    T3(x)=1+2*sum(n=1,ceil(sqrt(N)),x^(n*n));
    Vec(T3(x)*T3(x^5))
    /* Joerg Arndt, Sep 21 2012 */

Formula

Theta series of lattice with Gram matrix [1 0 / 0 5].
Expansion of phi(q)phi(q^5) in powers of q where phi(q) is a Ramanujan theta function.
Euler transform of period 20 sequence [ 2, -3, 2, -1, 4, -3, 2, -1, 2, -6, 2, -1, 2, -3, 4, -1, 2, -3, 2, -2, ...]. - Michael Somos, Aug 13 2006
If p is prime then a(p) is nonzero iff p is in A033205.
0=a(n)a(2n) and 2*A035170(n) = a(n) + a(2n) if n>0. - Michael Somos, Oct 21 2006
a(n) is nonzero iff n is in A020669. - Robert Israel, Dec 22 2015
a(0) = 1, a(n) = (1+(-1)^t)b(n) for n > 0, where t is the number of prime factors of n, counting multiplicity, which are == 2,3,7 (mod 20), and b() is multiplicative with b(p^e) = (e+1) for primes p == 1,3,7,9 (mod 20) and b(p^e) = (1+(-1)^e)/2 for primes p == 11,13,17,19 (mod 20). (This formula is Corollary 3.3 in the Berkovich-Yesilyurt paper) - Jeremy Lovejoy, Nov 12 2024
Showing 1-10 of 19 results. Next