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-4 of 4 results.

A007634 Numbers k such that k^2 + k + 41 is composite.

Original entry on oeis.org

40, 41, 44, 49, 56, 65, 76, 81, 82, 84, 87, 89, 91, 96, 102, 104, 109, 117, 121, 122, 123, 126, 127, 130, 136, 138, 140, 143, 147, 155, 159, 161, 162, 163, 164, 170, 172, 173, 178, 184, 185, 186, 187, 190, 201, 204, 205, 207, 208, 209, 213, 215, 216, 217
Offset: 1

Views

Author

Keywords

Comments

A subset of this sequence is shown in A055390. - Matt C. Anderson, Jan 05 2014
If prime p divides m^2+m+41, then m+p*j is in the sequence for all j >= 1. - Robert Israel, Nov 24 2017
Euler noted that the first 40 values of this polynomial, starting with k=0, are all primes. - Harvey P. Dale, Jul 25 2023

References

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

Crossrefs

Programs

Formula

a(n) ~ n. - Charles R Greathouse IV, Apr 25 2014

A194634 Numbers n such that k= n^2 + n + 41 is composite and there is no integer x such that n= x^2 + 40; n= (x^2+x)/2 + 81; or n= 3*x^2 - 2x + 122.

Original entry on oeis.org

127, 138, 155, 163, 164, 170, 173, 178, 185, 190, 204, 205, 207, 208, 213, 215, 216, 232, 237, 239, 242, 244, 245, 246, 248, 249, 251, 256, 259, 261, 266, 268, 270, 278, 279, 283, 284, 286, 287, 289, 295, 299, 300, 301, 302, 309, 314, 321, 325, 326, 327, 328
Offset: 1

Views

Author

Matt C. Anderson, Aug 30 2011

Keywords

Comments

The parabola curve fit: p1(0)=40; p1(1)=41; p1(2)=44 yields p1(x)=x^2+40. A second fit: p2(0)=81; p2(1)=82; p2(2)=84 yields p2(x)=(x^2+x)/2 + 81. A third fit: p3(0)=122; p3(1)=123; p3(2)=130 yields p3(x)=3x^2-2*x+122.
Substituting n=x^2 into k=n^2+n+41 is factorable as: k1=(x^2+x+41)*(x^2-x+41). This shows that all lattice points on p1 produce a composite k.
Similarly, substituting n=(x^2-x)/2 + 81 into k factors as k2=(x^2+163)*(x^2+2*x+164)/4. So all lattice points on p2 produce a composite k.
Similarly, substituting n=3*x^2-2*x+122 into k factors as k3=(x^2-x+41)*(9*x^2-3*x+367). So all lattice points on p3 produce a composite k.
This procedure can be continued with p4(x)=3*x^2+8*x+127, p5(x)=4*x^2-3*x+163, p6(x)=4*x^2+11*x+170, p7(x)=5*x^2-4*x+204, p8(x)=5*x^2+14*x+213, p9(x)=(3*x^2-x)/2+244, p10(x)=(3*x^2+7*x)/2+246, and so on.

References

  • John Stillwell, Elements of Number Theory, Springer, 2003, page 3.
  • R. Crandall and C. Pomerance, Prime Numbers A Computational Perspective 2nd ed., Springer, 2005, page 21.

Crossrefs

Cf. A007634 (n such that n^2+n+41 is composite).
Cf. A055390 (members of A007634 that are not lattice points of x^2+40).
Cf. A194565 (members of A055390 that are not lattice points of (x^2+x)/2 + 81).

Programs

  • Maple
    A007634:={}:
    for n from 1 to 1000 do
    k:=n^2+n+41:
    if isprime(k)=false then
    A007634:=A007634 union {n}:
    end if:
    end do:
    pv1:=Vector(1000,j->(j-1)^2+40):
    p1:=convert(pv1,set):
    A055390:=A007634 minus p1 minus {0}:
    pv2:=Vector(1000,j->((j-1)^2+(j-1))/2+81):
    p2:=convert(pv2,set):
    A194565:=A055390 minus p2:
    pv3:=Vector(1000,j->(3*(j-1)^2-2*(j-1)+122)):
    p3:=convert(pv3,set):
    p3set:=A194565 minus p3;
  • PARI
    is(n)=!isprime(n^2+n+41) && !issquare(n-40) && !issquare(8*n-647) && n > 126 && (x->3*x^2-2*x+122)(round((1+sqrt(3*n-365))/3))!=n \\ Charles R Greathouse IV, Apr 25 2014

Formula

a(n) ~ n. - Charles R Greathouse IV, Apr 25 2014

Extensions

Fixed subscripts in first comment. Added * in 4th comment. Added 5th comment. Changed g to k for consistancy. Improved Maple code. Added second book reference. Changed name to agree with comment of editor.

A194565 Numbers n such that n^2 + n + 41 is composite and n is not a lattice point on the parabolas p1 = x^2 + 40 or p2 = (x^2+x)/2 + 81.

Original entry on oeis.org

122, 123, 127, 130, 138, 143, 155, 162, 163, 164, 170, 173, 178, 185, 187, 190, 204, 205, 207, 208, 213, 215, 216, 218, 232, 237, 239, 242, 244, 245, 246, 248, 249, 251, 255, 256, 259, 261, 266, 268, 270, 278, 279, 283, 284, 286, 287, 289, 295, 298, 299, 300
Offset: 1

Views

Author

Matt C. Anderson, Aug 28 2011

Keywords

Comments

The parabola curve fit: p1(0)=40; p1(1)=41; p1(2)=44 yields p1(x)=x^2+40. A second fit: p2(0)=81; p2(1)=82; p2(2)=84 yields p2(x)=(x^2+x)/2 + 81.
Substituting n=x^2+40 into g=n^2+n+41 is factorable as: g1=(x^2+x+41)*(x^2-x+41). This shows that all lattice points on p1 produce a composite g.
Similarly, substituting n=(x^2-x)/2 + 81 into g factors as g2=(x^2+163)*(x^2+2*x+164)/4. So all lattice points on p2 produce a composite g.

References

  • John Stillwell, Elements of Number Theory, Springer, 2003, page 3.

Crossrefs

Cf. A007634 (n such that n^2+n+41 is composite).
Cf. A055390 (members of A007634 that are not lattice points of x^2+40).

Programs

  • Maple
    AV:=Vector(1000,0):
    counter:=1:
    for n from 1 to 1000 do
    g:=n^2+n+41:
    if isprime(g)=false then
      AV[counter]:=n:
      counter:=counter+1:
    end if
    end do:
    A007634:=convert(AV,set):
    pv1:=Vector(1000,j->(j-1)^2+40):
    p1:=convert(pv1,set):
    A055390:=A007634 minus p1:
    pv2:=Vector(1000,j->((j-1)^2+(j-1))/2+81):
    p2:=convert(pv2,set):
    ThisSet:=A055390 minus p2 minus {0};
  • PARI
    is(n)=!isprime(n^2+n+41) && !issquare(n-40) && !issquare(8*n-647) \\ Charles R Greathouse IV, Apr 25 2014

Formula

a(n) ~ n. - Charles R Greathouse IV, Apr 25 2014

Extensions

Fixed subscript in first comment by Matt C. Anderson

A241529 Positive numbers k such that k^2 + k + 41 is composite and there are no positive integers a,c,d such that k = c*a*z^2 + ((((d+2)*(1/3))*c-2)*a/d+1)*z + ((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2 - (((d-1)*(1/3))*c+1)/d)/c for an integer z.

Original entry on oeis.org

2887, 2969, 3056, 3220, 3365, 3464, 3565, 3611, 3719, 3746, 3814, 3836, 3874, 3879, 3955, 4142, 4147, 4211, 4277, 4371, 4403, 4483, 4564, 4572, 4661, 4730, 4813, 4881, 4888, 4902, 4906, 4965, 4982, 5132, 5175, 5208, 5410, 5431, 5509, 5527, 5564, 5624, 5669
Offset: 1

Views

Author

Matt C. Anderson, Apr 27 2014

Keywords

Comments

This sequence has a restriction involving 4 variables. More composite cases are described with a better restrictive expression. The expression for k(a,c,d,z) will force k^2 + k + 41 to be either a fraction or a composite number.
The condition on k(a,c,d,z) was determined by quadratic curve fitting. It has been automated with the Maple Interactive() command. The ultimate motivation is to try to find a closed-from expression that generates all the composite cases of k^2 + k + 41 for integer k.
What is the smallest value of n where this sequence's a(n) < 2n? (For A194634, this value is 2358.) - J. Lowell, Feb 25 2019

References

  • John Stillwell, Elements of Number Theory, Springer, 2003, page 3.

Crossrefs

Cf. A007634, A055390, A201998, and with division, A235381.

Programs

  • Maple
    # Euler considered the prime values for n^2 + n + 41;
    # This is a 76 second calculation on a 2.93 GHz machine
    h := n^2+n+41;
    y := c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c;
    y2 := subs(n = y, h);
    y3 := factor(y2);
    # note that y is an expression in 4 variables.
    # After a composition of functions, an algebraic factorization
    # can be observed in y3.  As long as y3 is an integer, it will
    # be composite.  This is because y3 factors and both factors
    # are integers bigger than one.
    maxn := 6000;
    A := {}:
    for n to maxn do
    g := n^2+n+41:
    if isprime(g) = false then A := `union`(A, {n}) end if :
    end do:
    # now the A set contains composite values of the form
    # n^2 + n + 41 less than maxn.
    c := 1: a := 1: d := 1: z := -1: p := 41:
    q := c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c:
    A2 := A:
    while q < maxn do
    while `and`(q < maxn, d < 100) do
    while q < maxn do while
    q < maxn do
    A2 := `minus`(A2, {q});
    A2 := `minus`(A2, {c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c});
    z := z+1;
    A2 := `minus`(A2, {c*a*z^2-((((d+2)*(1/3))*c-2)*a/d+1)*(1*z)+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c}); q := c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c
    end do;
    a := a+1; z := -1;
    q := c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c :
    end do;
    d := d+1: a := 1:
    q := c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c :
    end do:
    c := c+1: d := 1:
    q := c*a*z^2+((((d+2)*(1/3))*c-2)*a/d+1)*z+((((367*d^2+d+1)*(1/9))*c^2-((d+2)*(1/3))*c+1)*a/d^2-(((d-1)*(1/3))*c+1)/d)/c :
    end do:
    A2;
    # Matt C. Anderson, May 13 2014
Showing 1-4 of 4 results.