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

A120847 Klarner-Rado primes. Primes in A005658.

Original entry on oeis.org

2, 5, 17, 29, 47, 53, 83, 89, 101, 173, 191, 251, 263, 269, 281, 317, 431, 467, 479, 521, 587, 659, 809, 857, 911, 929, 947, 953, 983, 1019, 1091, 1163, 1307, 1439, 1451, 1493, 1559, 1601, 1613, 1667, 1811, 1847, 1871, 1901, 1979, 2027, 2063, 2099, 2207, 2243
Offset: 1

Views

Author

Jonathan Vos Post, Aug 18 2006

Keywords

Crossrefs

Subsequence of A003627.

Programs

  • MATLAB
    N = 10^4;
    A = zeros(1,N);
    todo = [1];
    A(1) = 1;
    while numel(todo) > 0
      x = todo(1);
      todo = todo(2:end);
      Y = [2*x,3*x+2,6*x+3];
      Y = Y(Y <= N);
      Y = Y(A(Y) == 0);
      A(Y) = 1;
      todo = [todo, Y];
    end;
    S = find(A==1);
    S(isprime(S)) % Robert Israel, Jun 17 2015
    
  • Maple
    N:= 3000: # to get all terms <= N
    A:= Vector(N):
    A[1]:= 1:
    todo:= {1}:
    while todo <> {} do
    x:= todo[1];
    todo:= todo[2..-1];
    Y:= select(t -> (t <= N and A[t] = 0),[2*x,3*x+2, 6*x+3]);
      A[Y]:= 1;
      todo:= todo union convert(Y,set);
    od:
    select(t -> A[t]=1 and isprime(t), [$1..N]); # Robert Israel, Jun 17 2015
  • PARI
    has(n)=if(n<3, return(n>0)); my(k=n%6); if(k==3, return(has(n\6))); if(k==1, return(0)); if(k==5, return(has(n\3))); if(k!=2, return(has(n/2))); has(n\3) || has(n/2)
    print1(2); forprime(p=5,1e5, if(p%3==2 && has(p\3), print1(", "p))) \\ Charles R Greathouse IV, Sep 15 2015

Formula

A000040 INTERSECTION {sequence starting with 1 and such that if n appears so do 2n, 3n+2, 6n+3}.

Extensions

More terms from R. J. Mathar, Aug 20 2006

A005659 If k appears so do 2k-2 and 3k-3. (duplicates omitted.)

Original entry on oeis.org

4, 6, 9, 10, 15, 16, 18, 24, 27, 28, 30, 34, 42, 45, 46, 51, 52, 54, 58, 66, 69, 78, 81, 82, 87, 88, 90, 99, 100, 102, 106, 114, 123, 130, 132, 135, 136, 150, 153, 154, 159, 160, 162, 171, 172, 174, 178, 195, 196, 198, 202, 204, 210, 226, 231, 240, 243, 244, 258
Offset: 1

Views

Author

Keywords

Examples

			From _Seiichi Manyama_, Feb 29 2024: (Start)
87, 130 and 258 are terms and 258 = 2*130 - 2 = 3*87 - 3.
135, 202 and 402 are terms and 402 = 2*202 - 2 = 3*135 - 3.
231, 346 and 690 are terms and 690 = 2*346 - 2 = 3*231 - 3. (End)
		

References

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

Crossrefs

Cf. A005661.

Programs

  • Mathematica
    Take[Union[Nest[Flatten[{#,2#-2,3#-3}]&,4,10]],100] (* Harvey P. Dale, Mar 21 2025 *)

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Oct 01 2001

A005660 If k appears so do 2k+2 and 3k+3. (duplicates omitted.)

Original entry on oeis.org

3, 8, 12, 18, 26, 27, 38, 39, 54, 56, 57, 78, 80, 81, 84, 110, 114, 116, 117, 120, 158, 162, 164, 165, 170, 171, 174, 222, 230, 234, 236, 237, 242, 243, 246, 255, 318, 326, 330, 332, 333, 342, 344, 345, 350, 351, 354, 363, 446, 462, 470, 474, 476, 477, 486
Offset: 1

Views

Author

Keywords

Examples

			From _Seiichi Manyama_, Feb 29 2024: (Start)
59049, 88574 and 177150 are terms and 177150 = 2*88574 + 2 = 3*59049 + 3.
80553, 120830 and 241662 are terms and 241662 = 2*120830 + 2 = 3*80553 + 3.
167913, 251870 and 503742 are terms and 503742 = 2*251870 + 2 = 3*167913 + 3. (End)
		

References

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

Crossrefs

Cf. A005662.

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Oct 01 2001

A005662 Start with 4; if k appears then so do 2k+2 and 3k+3. (duplicates omitted.)

Original entry on oeis.org

4, 10, 15, 22, 32, 33, 46, 48, 66, 68, 69, 94, 98, 99, 102, 134, 138, 140, 141, 147, 190, 198, 200, 201, 206, 207, 210, 270, 278, 282, 284, 285, 296, 297, 300, 309, 382, 398, 402, 404, 405, 414, 416, 417, 422, 423, 426, 444, 542, 558, 566, 570, 572, 573, 594
Offset: 1

Views

Author

Keywords

Examples

			208857, 313286 and 626574 are terms and 626574 = 2*313286 + 2 = 3*208857 + 3. - _Seiichi Manyama_, Feb 29 2024
		

References

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

Crossrefs

Cf. A005660.

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Oct 01 2001

A335155 Start with 1; if n is in the sequence, so are n+5 and 3*n.

Original entry on oeis.org

1, 3, 6, 8, 9, 11, 13, 14, 16, 18, 19, 21, 23, 24, 26, 27, 28, 29, 31, 32, 33, 34, 36, 37, 38, 39, 41, 42, 43, 44, 46, 47, 48, 49, 51, 52, 53, 54, 56, 57, 58, 59, 61, 62, 63, 64, 66, 67, 68, 69, 71, 72, 73, 74, 76, 77, 78, 79, 81, 82, 83, 84, 86, 87, 88, 89, 91, 92, 93, 94, 96, 97, 98, 99, 101, 102, 103, 104, 106
Offset: 1

Views

Author

N. J. A. Sloane, Jun 05 2020

Keywords

Comments

This is the lexicographically earliest sequence of positive numbers with the property that if n is in the sequence, so are n+5 and 3*n.
Suggested by A335365 (which is the complement).

Crossrefs

Cf. A335365.
See also A005658, A005660, A005662, etc.

Programs

  • PARI
    Vec(x*(1 + 2*x + 3*x^2 + 2*x^3 - x^6 - x^7 + x^8 - x^10 + x^11 - x^13 + x^14 - x^15 - x^16) / ((1 - x)^2*(1 + x)*(1 + x^2)) + O(x^60)) \\ Colin Barker, Jun 07 2020

Formula

From Colin Barker, Jun 07 2020: (Start)
G.f.: x*(1 + 2*x + 3*x^2 + 2*x^3 - x^6 - x^7 + x^8 - x^10 + x^11 - x^13 + x^14 - x^15 - x^16) / ((1 - x)^2*(1 + x)*(1 + x^2)).
a(n) = a(n-1) + a(n-4) - a(n-5) for n>17.
(End)

A005661 k in S implies 2k-2, 3k-3 in S.

Original entry on oeis.org

5, 8, 12, 14, 21, 22, 26, 33, 39, 40, 42, 50, 60, 63, 64, 75, 76, 78, 82, 96, 98, 114, 117, 118, 123, 124, 126, 147, 148, 150, 154, 162, 177, 186, 189, 190, 194, 222, 225, 226, 231, 232, 234, 243, 244, 246, 250, 285, 291, 292, 294, 298, 306, 322, 339, 348, 351
Offset: 1

Views

Author

Keywords

Examples

			From _Seiichi Manyama_, Feb 29 2024: (Start)
663, 994 and 1986 are terms and 1986 = 2*994 - 2 = 3*663 - 3.
3159, 4738 and 9474 are terms and 9474 = 2*4738 - 2 = 3*3159 - 3.
18711, 28066 and 56130 are terms and 56130 = 2*28066 - 2 = 3*18711 - 3. (End)
		

References

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

Crossrefs

Cf. A005659.

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Oct 01 2001
Showing 1-6 of 6 results.