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.

User: Bob Selcoe

Bob Selcoe's wiki page.

Bob Selcoe has authored 85 sequences. Here are the ten most recent ones:

A330885 Square array T(n,k) read by antidiagonals upwards: T(n,0)=1; T(n,1) = n+1; T(n,2) = 2n+1, T(n,k>2) = T(n,k-1) - T(n,k-2) - T(n,k-3).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 3, 3, -1, 1, 4, 5, 0, -3, 1, 5, 7, 1, -5, -3, 1, 6, 9, 2, -7, -8, 1, 1, 7, 11, 3, -9, -13, -3, 7, 1, 8, 13, 4, -11, -18, -7, 10, 9, 1, 9, 15, 5, -13, -23, -11, 13, 21, 1, 1, 10, 17, 6, -15, -28, -15, 16, 33, 14, -15
Offset: 0

Author

Bob Selcoe, May 05 2020

Keywords

Examples

			Array starts:
1  1   1  -1   -3   -3    1   7   9   1  -15   -25
1  2   3   0   -5   -8   -3  10  21  14  -17   -52
1  3   5   1   -7  -13   -7  13  33  27  -19   -79
1  4   7   2   -9  -18  -11  16  45  40  -21  -106
1  5   9   3  -11  -23  -15  19  57  53  -23  -133
1  6  11   4  -13  -28  -19  22  69  66  -25  -160
1  7  13   5  -15  -33  -23  25  81  79  -27  -187
		

Crossrefs

Columns k: A000012 (k=0), A000027 (k=1), A005408 (k=2), A023443 (k=3), A165747 (k=4), -A016885 (k=5), -A004767 (k=6), A016777 (k=7), A017629 (k=8), A190991 (k=9).

Programs

  • Mathematica
    T[n_, k_]:= T[n, k]= If[k<3, k*n+1, T[n, k-1] - T[n, k-2] - T[n, k-3]];
    Table[T[n-k, k], {n,0,12}, {k,0,n}]//Flatten (* G. C. Greubel, May 26 2020 *)

Formula

T(0,k) = A180735(k-1).
T(n,k) - T(n-1,k) = -A078016(k+1).

A328037 Irregular triangle T(n,k) read by rows: "quotient trajectories" in reduced Collatz sequences; i.e., T(n,k) = q-value(A256598(n,k)) where q-value(z) = (z - A259663(m,j))/2^(m+j) and (m,j) is the unique pair such that z == A259663(m,j) (mod 2^(m+j)). (See Comments for definitions.)

Original entry on oeis.org

0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 1, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 1, 0, 2, 0, 0, 0, 1, 5, 0, 0, 2, 6, 20, 15, 5, 17, 3, 9, 29, 2, 8, 24, 74, 27, 5, 15, 47, 17, 53
Offset: 0

Author

Bob Selcoe, Oct 03 2019

Keywords

Comments

Coefficients T(m,j) in the array A259663 are least residues in congruence classes T(m,j) mod 2^(m+j). T"(m,j) denotes all members of that class.
Reduced Collatz sequences (i.e., reduced sequences) are standard Collatz sequences excluding even terms. Row n in triangle A256598 shows the reduced sequence starting with 2n+1.
Let every positive odd number z = T"(m,j)_q, where q is the quotient of z in T"(m,j). For example, T(2,3) = 7 in A259663, so T"(2,3) contains all numbers == 7 (mod 32). So z = T"(2,3)_0 = 7, z = T"(2,3)_1 = 39, z = T"(2,3)_2 = 71, etc.
T(n,k) is the q-value of A256598(n,k) (see Example below). Thus, each row n is defined here as a "quotient trajectory" for the reduced sequence with starting term 2n+1.

Examples

			Triangle starts:
  0;
  0, 0, 0;
  0, 0;
  0, 0, 2, 0, 0, 0;
  1, 0, 0, 2, 0, 0, 0;
  0, 2, 0, 0, 0;
  0, 0, 0;
  0, 0, 0, 0, 0, 0;
  2, 0, 0, 0;
  0, 1, 0, 2, 0, 0, 0;
  0, 0;
  0, 0, 0, 0, 0;
  3, 0, 1, 0, 2, 0, 0, 0;
  ...
n=13 starts with 27 = T"(2,2)_1 and takes 41 steps: 1, 5, 0, 0, 2, 6, 20, 15, 5, ..., 0, 0, 0.
Row n=12 maps to the reduced sequence n=12 in A256598: 25 -> 19 -> 29 -> 11 -> 17 -> 13 -> 5 -> 1, which is T"(2,1)_3 -> T"(3,2)_0 -> T"(3,1)_1 -> T"(2,2)_0 -> T"(2,1)_2 -> T"(3,1)_0 -> T"(4,1)_0 -> T"(2,1)_0.
		

Crossrefs

Programs

  • PARI
    Tdt(n, k) = if (n==2, if (k%2, 2^k-1, 3*2^k-1), if (n==3, if (k%2, 7*2^k-1, 5*2^k-1), mj = 2^(n-3) % 2^(n-2); mk = k % 2^(n-2); (2^k*3^(mj-mk) - 1) % 2^(n+k))); \\ A259663
    qvalue(m) = {my(line = 2, i, md); while (1, i = line; for (j=1, line-1, md = Tdt(i, j); if (m % (2^(i+j)) == md % (2^(i+j)), return((m-md)/2^(i+j))); i--;); line ++;);}
    row(n) = {my(oddn = 2*n+1, vl = List(oddn), x); while (oddn != 1, x = 3*oddn+1; oddn = x >> valuation(x, 2); listput(vl, oddn)); my(v = Vec(vl)); for (i=1, #v, v[i] = qvalue(v[i]);); v;} \\ A256598
    tabf(nn) = {for (n=0, nn, my(rown = row(n)); for (k=1, #rown, print1(rown[k], ", ")); print;);} \\ Michel Marcus, Oct 04 2019

A327283 Irregular triangle T(n,k) read by rows: "residual summands" in reduced Collatz sequences (see Comments for definition and explanation).

Original entry on oeis.org

1, 1, 5, 1, 5, 19, 73, 347, 1, 7, 29, 103, 373, 1631, 1, 5, 23, 133, 1, 11, 1, 5, 19, 65, 451, 1, 7, 53, 1, 5, 31, 125, 503, 2533, 1, 1, 5, 19, 185, 1, 7, 29, 151, 581, 2255, 10861, 1, 5, 23, 85, 287, 925
Offset: 1

Author

Bob Selcoe, Sep 15 2019

Keywords

Comments

Let R_s be the reduced Collatz sequence (cf. A259663) starting with s and let R_s(k), k >= 0 be the k-th term in R_s. Then R_(2n-1)(k) = (3^k*(2n-1) + T(n,k))/2^j, where j is the total number of halving steps from R_(2n-1)(0) to R_(2n-1)(k). T(n,k) is defined here as the "residual summand".
The sequence without duplicates is a permutation of A116641.

Examples

			Triangle starts:
  1;
  1, 5;
  1;
  1, 5, 19, 73,  347;
  1, 7, 29, 103, 373, 1631;
  1, 5, 23, 133;
  1, 11;
  1, 5, 19, 65,  451;
  1, 7, 53;
  1, 5, 31, 125, 503, 2533;
  1;
  1, 5, 19, 185;
  1, 7, 29, 151, 581, 2255, 10861;
  ...
T(5,4)=103 because R_9(4) = 13; the number of halving steps from R_9(0) to R_9(4) is 6, and 13 = (81*9 + 103)/64.
		

Crossrefs

Formula

T(n,k) = 2^j*R_(2n-1)(k) - 3^k*(2n-1), as defined in Comments.
T(n,1) = 1; for k>1: T(n,k) = 3*T(n,k-1) + 2^i, where i is the total number of halving steps from R_(2n-1)(0) to R_(2n-1)(k-1).

A308999 Irregular triangle T(n,k) read by rows: Lexicographically smallest marks on "perfect rulers" (as defined in A103294) of length n.

Original entry on oeis.org

0, 0, 1, 0, 1, 2, 0, 1, 3, 0, 1, 2, 4, 0, 1, 2, 5, 0, 1, 4, 6, 0, 1, 2, 3, 7, 0, 1, 2, 5, 8, 0, 1, 2, 6, 9, 0, 1, 2, 3, 6, 10, 0, 1, 2, 3, 7, 11, 0, 1, 2, 3, 8, 12, 0, 1, 2, 6, 10, 13, 0, 1, 2, 3, 4, 9, 14, 0, 1, 2, 3, 4, 10, 15, 0, 1, 2, 3, 8, 12, 16
Offset: 0

Author

Bob Selcoe, Jul 04 2019

Keywords

Comments

Refer to A103294 for additional definitions, references and links.
All rulers (rows) start with mark 0 and end with mark n.
Row lengths are A103298(n) + 1.

Examples

			Triangle starts:
  0;
  0,  1;
  0,  1,  2;
  0,  1,  3;
  0,  1,  2,  4;
  0,  1,  2,  5;
  0,  1,  4,  6;
  0,  1,  2,  3,  7;
  0,  1,  2,  5,  8;
  0,  1,  2,  6,  9;
  0,  1,  2,  3,  6, 10;
  0,  1,  2,  3,  7, 11;
  0,  1,  2,  3,  8, 12;
  0,  1,  2,  6, 10, 13;
  0,  1,  2,  3,  4,  9, 14;
  0,  1,  2,  3,  4, 10, 15;
  0,  1,  2,  3,  8, 12, 16;
		

Crossrefs

Programs

  • Sage
    def Partsum(T) :
        return [add([T[j] for j in range(i)]) for i in (0..len(T))]
    def Ruler(L, S) :
        return map(Partsum, Compositions(L, length=S))
    def isComplete(R) :
        S = Set([])
        L = len(R)-1
        for i in range(L,0,-1) :
            for j in (1..i) :
                S = S.union(Set([R[i]-R[i-j]]))
        return len(S) == R[L]
    def CompleteRuler(L, S) :
        return list(filter(isComplete, Ruler(L, S)))
    def PerfectRulers(L) :
        for i in (0..L) :
            R = CompleteRuler(L, i)
            if R: return R
        return []
    def A308999list(L):
        for n in (0..L):
            print(PerfectRulers(n)[-1])
    A308999list(16) # Peter Luschny, Aug 21 2019

A316625 Terms in A259663, in ascending order.

Original entry on oeis.org

1, 3, 5, 7, 11, 13, 15, 19, 21, 23, 31, 35, 47, 53, 55, 63, 79, 85, 87, 95, 99, 127, 143, 151, 191, 213, 223, 227, 255, 271, 319, 341, 351, 383, 407, 483, 511, 575, 663, 739, 767, 783, 853, 863, 895, 1023, 1175, 1251, 1279, 1365, 1407, 1535, 1599, 1807, 1887, 2047
Offset: 1

Author

Bob Selcoe, Jul 08 2018

Keywords

Comments

See A259663 for discussion of these terms in relation to Collatz sequences.
There are k terms in the interval [2^k, 2^(k+1)], k >= 1; terms in each interval are of the form 2^k + a(n) for some n.
The sequence is a permutation (without repeating terms) of the following numbers:
2^i-1 and 7*2^i-1 when i is odd, i >= 1;
3^2^i-1 and 5^2^i-1 when i is even, i >= 2;
For fixed k >= 4: least residues of 3^j*(2^(2^(k-3) + i*2^(k-2) - j)) - 1 mod 2^(2^(k-3) + i*2^(k-2) + k-j), i >= 0, 0 <= j < 2^(k-3) + i*2^(k-2) . (See example).

Examples

			k=5, i=1 -- terms are least residues of 3^j*2^(12-j)-1 mod 2^(17-j), 0 <= j < 12:
j=0: 4096-1 mod 131072 = 4095;
j=1: 3*2048-1 mod 65536 = 6143;
j=2: 9*1024-1 mod 32768 = 9215;
j=3: 27*512-1 mod 16384 = 13823;
j=4: 81*256-1 mod 8192 = 20735 mod 8192 == 4351;
j=5: 243*128-1 mod 4096 = 31103 mod 4096 == 2431;
j=6: 729*64-1 mod 2048 = 46655 mod 2048 == 1599;
j=7: 2187*32-1 mod 1024 = 69983 mod 1024 == 351;
j=8: 6561*16-1 mod 512 = 104975 mod 512 == 15;
j=9: 19683*8-1 mod 256 = 157463 mod 256 == 23;
j=10: 59049*4-1 mod 128 = 236195 mod 128 == 35;
j=11: 177147*2-1 mod 64 = 354293 mod 64 == 53.
Note: k=5, i=0 is equivalent to starting with j=0: 15 mod 512.
		

Crossrefs

Cf. A259663.

Extensions

More terms from Michel Marcus, Jul 10 2018

A299109 Probable primes in A030221.

Original entry on oeis.org

29, 139, 3191, 15289, 350981, 1681651, 20344613659, 2237722536169, 5650248517599839, 1464318118372209903213451940281613111, 471219735266432821374794400248484805597413615642086220363989152195627985749609
Offset: 1

Author

Keywords

Comments

From a problem in A269254. For detailed theory, see [Hone].
Subsequent terms have too many digits to display.

Crossrefs

Formula

a(n) = A030221(A299101(n)).

A299107 Probable primes in sequence {s_k(4)}, where s_k(4) = 4*s_{k-1}(4) - s_{k-2}(4), k >= 2, s_0(4) = 1, s_1(4) = 5.

Original entry on oeis.org

5, 19, 71, 3691, 191861, 138907099, 26947261171, 436315574686414344004975231616076636245689199862837798457639364993981991744926792179
Offset: 1

Author

Keywords

Comments

From a problem in A269254. For detailed theory, see [Hone].
Subsequent terms have too many digits to display.

Formula

a(n) = s_{A299100(n)}(4) = A001834(A299100(n)).

A299101 Indices of (probable) primes in A030221.

Original entry on oeis.org

2, 3, 5, 6, 8, 9, 15, 18, 23, 53, 114, 194, 564, 575, 585, 2594, 3143, 4578, 4970, 9261, 11508, 13298, 30018, 54993, 198476
Offset: 1

Author

Keywords

Comments

From a problem in A269254. For detailed theory, see [Hone].
a(25) > 2*10^5. - Robert Price, Jul 03 2020

Programs

Formula

A299109(n) = A030221(a(n)). - R. J. Mathar, Jul 22 2022

Extensions

a(24) from Robert Price, Jul 03 2020

A299100 Indices k such that s_k(4) is a (probable) prime, where s_k(4) = 4*s_{k-1}(4) - s_{k-2}(4), k >= 2, s_0(4) = 1, s_1(4) = 5.

Original entry on oeis.org

1, 2, 3, 6, 9, 14, 18, 146, 216, 293, 704, 1143, 1530, 1593, 2924, 7163, 9176, 9489, 11531, 39543, 50423, 60720, 62868, 69993, 69995, 88103, 88163, 104606, 164441, 178551
Offset: 1

Author

Keywords

Comments

From a problem in A269254. For detailed theory, see [Hone].
a(31) > 2*10^5. - Robert Price, May 29 2020

Crossrefs

Programs

  • Mathematica
    s[k_, m_] := s[k, m] = Which[k == 0, 1, k == 1, 1 + m, True, m s[k - 1, m] - s[k - 2, m]]; Select[Range@ 2000, PrimeQ@ Abs@ s[#, 4] &] (* Michael De Vlieger, Feb 03 2018 *)

Extensions

a(24)-a(30) from Robert Price, May 29 2020

A299071 Union_{odd primes p, n >= 3} {T_p(n)}, where T_m(x) = x*T_{m-1}(x) - T_{m-2}(x), m >= 2, T_0(x) = 2, T_1(x) = x (dilated Chebyshev polynomials of the first kind).

Original entry on oeis.org

18, 52, 110, 123, 198, 488, 702, 724, 843, 970, 1298, 1692, 2158, 2525, 3330, 4048, 4862, 5778, 6726, 6802, 7940, 9198, 10084, 10582, 13752, 15550, 17498, 19602, 21868, 24302, 26910, 29698, 30248, 32672, 35838, 39603, 42770, 46548, 50542
Offset: 1

Author

Keywords

Comments

From a problem in A269254. For detailed theory, see [Hone].
Sequence avoids numbers of the form T_p(T_2(j)).

Crossrefs

Programs

  • Mathematica
    maxT = 55000; maxn = 12;
    T[0][] = 2; T[1][x] = x;
    T[m_][x_] := T[m][x] = x T[m-1][x] - T[m-2][x];
    TT = Table[T[p][n], {p, Prime[Range[2, maxn]]}, {n, 3, Prime[maxn]}] // Flatten // Union // Select[#, # <= maxT&]&;
    avoid = Table[T[p][T[2][n]], {p, Prime[Range[2, maxn]]}, {n, 3, Prime[maxn] }] // Flatten // Union // Select[#, # <= maxT&]&;
    Complement[TT, avoid] (* Jean-François Alcover, Nov 03 2018 *)