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.

A171569 Triangular numbers T such that T-2 is a prime.

Original entry on oeis.org

15, 21, 45, 55, 91, 105, 153, 231, 253, 351, 435, 465, 595, 703, 741, 861, 1035, 1225, 1431, 1485, 1711, 1891, 1953, 2145, 2701, 3003, 3081, 3321, 3741, 4005, 4095, 4465, 4753, 5565, 5671, 6555, 7021, 7875, 8515, 9045, 10011, 10153, 10731, 11175, 11781
Offset: 1

Views

Author

Keywords

Examples

			15-2 = 13, 21-2 = 19, 45-2 = 43, ...
		

Crossrefs

Programs

  • Mathematica
    Select[s=0;Table[n*(n+1)/2,{n,6!}],PrimeQ[ #-2]&]
    Select[Accumulate[Range[200]],PrimeQ[#-2]&] (* Harvey P. Dale, Apr 09 2018 *)

A171570 Triangular numbers T such that T+2 is a prime.

Original entry on oeis.org

1, 3, 15, 21, 45, 105, 171, 231, 351, 465, 561, 741, 861, 1275, 1431, 1485, 2211, 2415, 2775, 3081, 3321, 4005, 4371, 5151, 7875, 8385, 10731, 11175, 11781, 13041, 13695, 14535, 15051, 15225, 17205, 17391, 17955, 18915, 21321, 22155, 23871, 24531
Offset: 1

Views

Author

Keywords

Examples

			1+2=3, 3+2=5, 15+2=17, ..
		

Crossrefs

Programs

  • Mathematica
    Select[s=0;Table[n*(n+1)/2,{n,6!}],PrimeQ[ #+2]&]
    Select[Accumulate[Range[300]],PrimeQ[#+2]&] (* Harvey P. Dale, Jun 27 2017 *)

A226109 Triangular numbers t such that t - 4, t - 2, t + 2, t + 4 are four primes.

Original entry on oeis.org

15, 105, 1485, 18915, 666435, 2143485, 4174605, 10059855, 10440165, 28196295, 95295915, 124591005, 155064855, 171023265, 206258205, 298400235, 311737965, 347701635, 389470095, 459332895, 460424685, 498948255, 526517475, 537575655, 615496155, 645500415, 885763005, 963144105
Offset: 1

Views

Author

Alex Ratushnyak, May 26 2013

Keywords

Comments

Subsequence of A129752.
Proper subsequence of A226196. - Alex Ratushnyak, May 30 2013

Crossrefs

Programs

  • Java
    import java.math.BigInteger;
    public class A226109 {
        public static void main (String[] args) {
          for (long n = 1; n < (1L << 31); n++) {
              long p2 = n * (n + 1)/2 + 2, m2 = p2 - 4;
              BigInteger b = BigInteger.valueOf(p2);
              if (!b.isProbablePrime(80)) continue;
              b = BigInteger.valueOf(m2);
              if (!b.isProbablePrime(80)) continue;
              b = BigInteger.valueOf(p2 + 2);
              if (!b.isProbablePrime(80)) continue;
              b = BigInteger.valueOf(m2 - 2);
              if (!b.isProbablePrime(80)) continue;
              System.out.printf("%d, ", p2 - 2);
          }
        }
    }
    
  • Magma
    A000217:=func; [A000217(t): t in [0..10^5] | forall{A000217(t)+i: i in [-4,-2,2,4] | IsPrime(A000217(t)+i)}]; // Bruno Berselli, May 27 2013
  • Mathematica
    Select[Accumulate[Range[0, 70]], Union[PrimeQ[{# - 4, # - 2, # + 2, # + 4}]] == {True} &] (* Alonso del Arte, May 27 2013 *)
Showing 1-3 of 3 results.