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

A078784 Primes on axis of Ulam square spiral (with rows ... / 7 8 9 / 6 1 2 / 5 4 3 / ... ) with origin at (1).

Original entry on oeis.org

2, 11, 19, 23, 53, 61, 127, 139, 151, 163, 233, 281, 431, 541, 613, 743, 827, 977, 1009, 1279, 1621, 1871, 2003, 2281, 2377, 2731, 3109, 3221, 3511, 3571, 3631, 3691, 4001, 4129, 4523, 4591, 5077, 6361, 6521, 7789, 7877, 8419, 9851, 10151, 10973, 11503, 11719, 11827, 12377, 12601, 12713, 13399
Offset: 1

Views

Author

Donald S. McDonald, Jan 10 2003

Keywords

Comments

Quadrants are numbered clockwise: 4=north, 1=east, 2=south, 3=west. The spiral numbers falling on axes (whether prime or not) are 4=north (2n+1)^2-n, 1=east (2n+1)^2+n+1, 2=south (2n)^2-(n-1), 3=west (2n)^2+n+1.
Primes to the left, right, above or below the 1 in the example in A054552.
This is the union of the primes in A168022, A168023, A168025 and A168027. - R. J. Mathar, Jul 11 2014

Examples

			For n=0, quadrant = 1, a(1) =  2, distance = 1;
for n=1, quadrant = 1, a(2) = 11, distance = 2;
for n=2, quadrant = 3, a(3) = 19, distance = 2.
		

Crossrefs

Programs

  • Mathematica
    Select[ Sort@ Flatten@ Table[ 4n^2 + (2j - 3)n + 1, {j, 0, 3}, {n, 58}], PrimeQ] (* Robert G. Wilson v, Jul 10 2014 *)

Formula

Primes in A039823(n) = ceiling((n^2 + n + 2)/4). - Georg Fischer, Dec 04 2024

Extensions

a(12) onward from Robert G. Wilson v, Jul 10 2014

A270269 Prime numbers with locations of right angle turns in the Ulam square spiral that are vertices of isosceles right triangles.

Original entry on oeis.org

3, 5, 7, 31, 37, 43, 8011, 8101, 8191, 920641, 921601, 922561, 3894703, 3896677, 3898651, 5902471, 5904901, 5907331, 7450171, 7452901, 7455631, 7482961, 7485697, 7488433, 36066031, 36072037, 36078043, 37155121, 37161217, 37167313, 39759331, 39765637, 39771943
Offset: 1

Views

Author

Michel Lagneau, Mar 14 2016

Keywords

Comments

See the illustration for more information.
Subsequence of A172979. This sequence is probably infinite.
An interesting property: the sequence of the differences between prime numbers that are vertices for each triangle is the sequence {2, 6, 90, 960, 1974, 2430, 2730, 2736, 6006, 6096, 6306, ...} = A087277: numbers n such that the three second-degree cyclotomic polynomials x^2 + 1, x^2 - x + 1 and x^2 + x + 1 are simultaneously prime.
For example:
2 = 5 - 3 = 7 - 5;
6 = 37 - 31 = 43 - 37;
90 = 8101 - 8011 = 8191 - 8101.
Consequence: a(3n) + A087277(n) is a square. The corresponding sequence of the squares is {3^2, 7^2, 91^2, 961^2, 1975^2, 2431^2, 2731^2, 2737^2, 6007^2, ...}.
Examples:
a(3) + A087277(1) = 7 + 2 = 3^2;
a(6) + A087277(2) = 43 + 6 = 7^2;
a(9) + A087277(3) = 8191 + 90 = 91^2.

Crossrefs

Programs

  • Maple
    nn:=20000:T:=array(1..nn):a0:=1:kk:=0:
    for p from 1 to nn do :
       a1:=a0+floor(p/2):a0:=a1:
        if  isprime(a1)
         then
         kk:=kk+1:T[kk]:=a1:
         else
        fi:
      od:
       for n from 1 to kk-2 do:
        d1:=T[n+2]-T[n+1]:d2:=T[n+1]-T[n]:
         if d1=d2
         then
          printf("%d %d %d \n", T[n], T[n+1], T[n+2]):
          else
         fi:
       od:

A331997 Semiprimes m = p*q where m, p and q are in A033638 (locations of right angle turns in Ulam square spiral).

Original entry on oeis.org

10, 21, 26, 65, 91, 111, 785, 842, 1333, 4097, 21171, 28562, 50851, 100807, 194923, 970226, 1000001, 37021141, 65618101, 81144065, 151782401, 151819363, 174134417, 577921601, 688773781, 796622401, 796678851, 1276025563, 2090501285, 2176782337, 3662246773, 6059299123, 6879790081
Offset: 1

Views

Author

Michel Lagneau, Feb 04 2020

Keywords

Comments

The sequence is probably infinite.
A geometric property of the sequence: consider the first diagonal with numbers of the form f(k) = k^2 + k + 1 in the Ulam spiral. The semiprimes and their prime factors belonging to the diagonal are given by the subsequence: 21, 91, 1333, 50851, 194923, 37021141, 65618101, 151819363, 688773781, 796622401, 1276025563, 3662246773, 6059299123, 6879790081, ... (see the illustration). This subsequence is the result of the following property: f(k)*f(k+1) = f((k+1)^2).
Examples:
21 = 3*7 = f(1)*f(2) = f(4);
91 = 7*13 = f(2)*f(3) = f(9);
1333 = 31*43 = f(5)*f(6) = f(36);
................................
This subsequence is probably infinite.

Examples

			111 is in the sequence because 111 = 3*37, and the numbers 3, 37 and 111 are in A033638.
		

Crossrefs

Programs

  • Maple
    with(numtheory):nn:=10^5:T1:=1:
    lst:={1}:lst1:={}:
      for n from 2 to nn do:
       T2:= T1 + floor(n/2):lst:=lst union {T2}:T1:=T2:
      od:
          for j from 2 to nn do:
            x:=lst[j]:d:=factorset(x):n0:=nops(d):
              if n0=2 and bigomega(x)=2
               and {d[1],d[2]} intersect lst = {d[1],d[2]}
               then
               lst1:=lst1 union {lst[j]}
               else
               fi:
              od:
              sort(lst1);
  • PARI
    lista(nn) = {my(vn = vector(nn, k, k^2\4 + 1)); for (i=1, #vn, if (bigomega(vn[i]) == 2, my(f=factor(vn[i])); my(p=f[1,1], q = f[2,1]); if (vecsearch(vn, p) && vecsearch(vn, q), print1(vn[i], ", "));););} \\ Michel Marcus, Feb 04 2020

Extensions

More terms from Michel Marcus, Jan 13 2025
Showing 1-3 of 3 results.