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.

Previous Showing 11-18 of 18 results.

A055678 Integers not congruent to 0 (mod 6) that are divisible by the number of their divisors.

Original entry on oeis.org

1, 2, 8, 9, 40, 56, 80, 88, 104, 128, 136, 152, 184, 225, 232, 248, 296, 328, 344, 376, 424, 441, 448, 472, 488, 536, 560, 568, 584, 625, 632, 640, 664, 712, 776, 808, 824, 856, 872, 880, 896, 904, 1016, 1040, 1048, 1089, 1096, 1112, 1192, 1208, 1250, 1256
Offset: 1

Views

Author

Robert G. Wilson v, Jun 09 2000

Keywords

Crossrefs

Intersection of A033950 and A047253.

Programs

  • Mathematica
    Do[If[Mod[n,6]!=0,If[IntegerQ[n/DivisorSigma[0,n]],Print[n]]],{n,1500}]

A108612 Beatty-2 (or nested Beatty) sequence for 1/sin(1).

Original entry on oeis.org

1, 4, 9, 16, 25, 42, 56, 72, 90, 110, 143, 168, 195, 224, 255, 304, 340, 378, 418, 460, 504, 572, 621, 672, 725, 780, 864, 924, 986, 1050, 1116, 1216, 1287, 1360, 1435, 1512, 1591, 1710, 1794, 1880, 1968, 2058, 2193, 2288, 2385, 2484, 2585, 2736, 2842, 2950
Offset: 1

Views

Author

Zak Seidov, Jun 13 2005

Keywords

Crossrefs

Formula

a(n) = floor(n*floor(n/sin(1))).

A108613 Excess of Beatty-2 function of 1/sin(1) over n^2.

Original entry on oeis.org

0, 0, 0, 0, 0, 6, 7, 8, 9, 10, 22, 24, 26, 28, 30, 48, 51, 54, 57, 60, 63, 88, 92, 96, 100, 104, 135, 140, 145, 150, 155, 192, 198, 204, 210, 216, 222, 266, 273, 280, 287, 294, 344, 352, 360, 368, 376, 432, 441, 450, 459, 468, 477, 540, 550, 560, 570, 580, 649, 660
Offset: 0

Views

Author

Zak Seidov, Jun 13 2005

Keywords

Comments

Cf. A108612 Beatty-2 (or nested Beatty) function of 1/sin(1).

Crossrefs

Formula

a(n) = A108612[n] - n^2 = floor(n*floor(n/sin(1))) - n^2.

A215898 a(4n) = 1+4n, a(1+4n) = -2-6n, a(2+4n) = 4+6n, a(3+4n) = -3-4n.

Original entry on oeis.org

1, -2, 4, -3, 5, -8, 10, -7, 9, -14, 16, -11, 13, -20, 22, -15, 17, -26, 28, -19, 21, -32, 34, -23, 25, -38, 40, -27, 29, -44, 46, -31, 33, -50, 52, -35, 37, -56, 58, -39, 41, -62, 64, -43, 45, -68, 70, -47, 49, -74, 76, -51, 53, -80, 82, -55, 57, -86, 88, -59
Offset: 0

Views

Author

Paul Curtz, Aug 25 2012

Keywords

Comments

A permutation of A047253, numbers that are not divisible by 6.

Crossrefs

Programs

  • Magma
    m:=60; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((1-x+3*x^2+3*x^4-x^5+x^6)/((1-x)*(1+x+x^2+x^3)^2))); // Bruno Berselli, Sep 06 2012
    
  • Mathematica
    a[n_ /; Mod[n, 4] == 0] := n+1; a[n_ /; Mod[n, 4] == 1] := -(3n+1)/2; a[n_ /; Mod[n, 4] == 2] := (3n+2)/2; a[n_ /; Mod[n, 4] == 3] := -n; Table[a[n], {n, 0, 70}] (* Jean-François Alcover, Sep 03 2012 *)
    LinearRecurrence[{-1,-1,-1,1,1,1,1},{1,-2,4,-3,5,-8,10},60] (* Harvey P. Dale, Mar 24 2023 *)
  • Maxima
    makelist(expand(1+(5-%i^(n*(n+1)))*((2*n+1)*(-1)^n-1)/8), n, 0, 60); /* Bruno Berselli, Sep 07 2012 */

Formula

a(n) = 2*a(n-4) - a(n-8).
a(2*n) + a(1+2*n) = -A109613(n)*(-1)^n.
a(3*n) + a(1+3*n) + a(2+3*n) = 3*a(n).
a(4*n) + a(1+4*n) + a(2+4*n) + a(3+4*n) = 0.
a(5*n) + a(1+5*n) + a(2+5*n) + a(3+5*n) + a(4+5*n) = 5*a(n).
From Bruno Berselli, Sep 07 2012: (Start)
G.f.: (1-x+3*x^2+3*x^4-x^5+x^6)/((1-x)*(1+x+x^2+x^3)^2).
a(n) = 1+(5-i^(n*(n+1)))*((2*n+1)*(-1)^n-1)/8, where i=sqrt(-1).
a(2*n) = 1+(5-(-1)^n)*n/2; a(2*n+1) = 1-(5+(-1)^n)*(n+1)/2.
a(n) = a(-n-1) = -a(n-1)-a(n-2)-a(n-3)+a(n-4)+a(n-5)+a(n-6)+a(n-7). (End)

A274677 Numbers k such that 7*10^k + 19 is prime.

Original entry on oeis.org

1, 2, 3, 4, 27, 32, 63, 69, 107, 145, 154, 173, 190, 271, 412, 1219, 1509, 2392, 4444, 5567, 7424, 32174, 51573
Offset: 1

Views

Author

Vincenzo Librandi, Jul 04 2016

Keywords

Comments

No term is divisible by 6 (A047253) because 7*1000000^k + 19 = 7*(76923*13 + 1)^k + 19 is divisible by 13 and is therefore not prime. - Bruno Berselli, Jul 05 2016

Examples

			3 is in this sequence because 7*10^3 + 19 = 7019 is prime.
5 is not in the sequence because 7*10^5 + 19 = 79*8861.
Initial terms and associated primes:
a(1) = 1: 89;
a(2) = 2: 719;
a(3) = 3: 7019;
a(4) = 4: 70019, etc.
		

Crossrefs

Subsequence of A047253.
Cf. similar sequences listed in A274676.

Programs

  • Magma
    [n: n in [1..800] | IsPrime(7*10^n+19)];
    
  • Mathematica
    Select[Range[0, 3000], PrimeQ[7 10^# + 19] &]
  • PARI
    lista(nn) = for(n=1, nn, if(ispseudoprime(7*10^n+19), print1(n, ", "))); \\ Altug Alkan, Jul 05 2016
    
  • Python
    from sympy import isprime
    def afind(limit, startk=0):
        sevenpow10 = 7*10**startk
        for k in range(startk, limit+1):
            if isprime(sevenpow10 + 19):
                print(k, end=", ")
            k += 1
            sevenpow10 *= 10
    afind(500) # Michael S. Branicky, Dec 31 2021

Extensions

a(20)-a(21) from Michael S. Branicky, Dec 31 2021
a(22)-a(23) from Kamada data by Tyler Busby, Apr 14 2024

A323139 Integers that are not multiples of 6 and are the sum of two consecutive primes.

Original entry on oeis.org

5, 8, 52, 68, 100, 112, 128, 152, 172, 268, 308, 320, 340, 352, 410, 434, 472, 508, 520, 532, 548, 668, 712, 740, 752, 772, 872, 892, 946, 1012, 1030, 1064, 1088, 1120, 1132, 1148, 1180, 1192, 1208, 1220, 1250, 1300, 1312, 1334, 1360, 1460, 1472, 1508, 1606, 1888, 1900, 1948, 1960, 1988, 2006, 2032, 2072, 2132, 2156
Offset: 1

Views

Author

Pedro Caceres, Jan 05 2019

Keywords

Comments

All primes, except 2 and 3, are of the form 6k+1 or 6k-1 for k a positive integer. The converse statement is not true for all k, so the sum of two consecutive primes is not always a multiple of 6. This sequence lists the sums of two consecutive primes that are not multiple of 6.

Examples

			52 = 23 + 29 is not a multiple of 6.
		

Crossrefs

Programs

  • Maple
    p:= 2:
    count:= 0: Res:= NULL:
    while count < 100 do
      q:= nextprime(p);
      if p+q mod 6 <> 0 then
         count:= count+1; Res:= Res, p+q;
      fi;
      p:= q;
    od:
    Res; # Robert Israel, Jan 09 2019
  • Mathematica
    Select[Total /@ Partition[Prime@ Range@ 180, 2, 1], Mod[#, 6] != 0 &] (* Michael De Vlieger, Jan 07 2019 *)
  • PARI
    my(p=2); forprime(q=3, 1e3, if ((p+q) % 6, print1(p+q", ")); p=q); \\ Michel Marcus, Jan 05 2019

A364902 Let x, y be the greatest exponents of 2, 3 respectively such that 2^x, 3^y do not exceed n and let k_2, k_3 be n - 2^x, and n - 3^y respectively. Then for n such that k_2 = 0 or k_3 = 0, a(n) = n, else a(n) is the least novel number Min{p*a(k_2), q*a(k_3)}, where p, q are primes not equal to either 2 or 3.

Original entry on oeis.org

1, 2, 3, 4, 5, 10, 15, 8, 9, 7, 14, 20, 25, 35, 50, 16, 11, 22, 21, 28, 55, 70, 75, 40, 45, 49, 27, 13, 26, 33, 44, 32, 17, 34, 39, 52, 65, 98, 100, 56, 63, 77, 80, 121, 110, 105, 140, 112, 143, 154, 147, 196, 245, 135, 91, 130, 165, 220, 160, 85, 170, 195, 260, 64, 19, 38, 51, 68
Offset: 1

Views

Author

Keywords

Comments

Motivated by the recursion D(2) known to reproduce A005940, this sequence uses a compound version based on a squarefree semiprime (6) rather than a prime, in which the terms are generated by a greedy algorithm related to the distances between n and the greatest powers of 2, and 3 not exceeding n. After a(9) = 9 each power of 2 or 3 is followed by the smallest prime not yet in the sequence. (e.g. 11 follows 16, 13 follows 27, etc).
There are no multiples of 6 in this sequence.
For k > 2, if a(i) = prime(k) = p and a(j) = p^2 then j-i is a term in A006899 (e.g. a(17) = 11, a(44) = 121 and 44 - 17 = 27 = 3^3).
Conjectures: (i). This is a permutation of A047253 with primes in order; (ii). All terms between consecutive prime terms, prime(k), prime(k+1) are prime(k)-smooth.

Examples

			a(n) = n for n <= 4 because all such n are powers of 2 or 3.
a(5) = least novel Min{a(1)*p,a(2)*q} = Min{p,2*q} for o,q prime != 2 or 3, so a(5) = 5.
17=16+1=9+8, so a(17) = least novel Min{a(1)*p,a(8)*q} = Min{p,8*q} = 11.
Data can be shown in tabular form in two distinct ways: First row starts with 1 and then rows start with a prime; alternatively each row starts with 2^i or 3^j:
 1;                       1;
 2;                       2;
 3,4;                     3;
 5,10,15,8,9;             4,5,10,15;
 7,14,20,25,35,50,16;     8;
 11,22,21,28,55...        9,7,14,20,25,35,50
		

Crossrefs

Programs

  • Mathematica
    nn = 120; c[_] = False; s = {1, 2}; w = Length[s]; t = Prime[s]; flag = 0;
    Array[Set[{q[#1], p[#1],
          r[#1]}, {#1, #2,
            Prepend[#2^Range[Floor@Log[#2, nn]], 1]} & @@ {#2,
           Prime[#2]}] & @@ {#, s[[#]]} &, w];
    Do[If[n == 1,
       Set[{a[n], c[1]}, {1, True}],
       Array[Set[m[#], 1] &, w];
       Array[Set[j[#], n - p[#]^(-1 + LengthWhile[r[#], # < n + 1 &])] &, w];
       Array[
        If[j[#] == 0,
          k[#] = n; flag = #,
          While[Set[k[#], Prime[m[#]] a[j[#]]];
           Or[MemberQ[s, m[#]], c[k[#]]], m[#]++]] &, w];
       If[flag > 0,
        Set[{a[n], c[k[flag]]}, {k[flag], True}]; flag = 0,
        Set[{a[n], c[#]}, {#, True}] &[Min@ Array[k, w]] ]], {n, nn}];
    Array[a, nn] (* Michael De Vlieger, Sep 24 2023 *)

Formula

For n > 6, a(A006899(n) + 1) = prime(n-2).

A292163 a(n) is the least prime p such that the orderly concatenation of the n successive powers of p yields a prime number; a(n)=0 if n is a multiple of 6.

Original entry on oeis.org

3, 3, 337, 23, 0, 373, 37, 839, 421, 7, 0, 1447, 2113, 29, 43, 17, 0, 1789, 523, 84737, 7669, 397, 0, 3851, 3583, 99149, 146023, 157, 0, 14173, 38329, 1229, 8017, 1021, 0, 18979, 5437, 17207, 6571, 47, 0, 347, 43669, 25847, 257353, 2887, 0, 33889, 71287
Offset: 2

Views

Author

Michel Marcus, Sep 10 2017

Keywords

Comments

See in the Prime Puzzle link the discussion for when n is a multiple of 6.

Examples

			For n=2, the concatenation of 3^0 and 3^1 is 13 which is prime (while 12 was not prime); so a(2) = 3.
For n=3, the concatenation of 3^0, 3^1 and 3^2 is 139 which is prime (while 124 was not prime); so a(3) = 3.
		

Crossrefs

Cf. A047253.

Programs

  • Maple
    g:= proc(p,n) local i,t;
      t:= p^(n-1):
      for i from n-2 to 0 by -1 do
        t:= t + 10^(1+ilog10(t))*p^i
      od;
      t
    end proc:
    f:= proc(n)
      local p;
      if n mod 6 = 0 then return 0 fi;
      p:= 3;
      while not isprime(g(p,n)) do
        p:= nextprime(p);
        if n mod 3 = 0 then while p mod 3 = 1 do p:= nextprime(p) od fi:
      od;
      p
    end proc:
    map(f, [$2..30]); # Robert Israel, Sep 10 2017
  • PARI
    pconc(p, n) = {my(s = "1"); for (k=1, n, s = concat(s, Str(p^k));); eval(s);}
    a(n) = {if (!(n % 6), return (0)); n --; my(p = 2); while (! isprime(pconc(p, n)), p = nextprime(p+1)); p;}

Extensions

a(27)-a(50) from Robert Israel, Sep 10 2017
Previous Showing 11-18 of 18 results.