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 51-60 of 218 results. Next

A290221 Number of elements added at n-th stage to the structure of the narrow cross described in A290220.

Original entry on oeis.org

0, 2, 4, 4, 8, 8, 8, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12, 8, 16, 12
Offset: 0

Views

Author

Omar E. Pol, Jul 24 2017

Keywords

Comments

For n = 0..6 the sequence is similar to some toothpick sequences.
The surprising fact is that for n >= 7 the sequence has periodic tail. More precisely, it has period 3: repeat [8, 16, 12]. This tail is in accordance with the expansion of the four arms of the cross.
This is essentially the first differences of A290221. The behavior is similar to A289841 and A294021 in the sense that these three sequences from cellular automata have the property that after the initial terms the continuation is a periodic sequence. - Omar E. Pol, Oct 29 2017

Examples

			For n = 0..6 the sequence is: 0, 2, 4, 4, 8, 8, 8;
Terms 7 and beyond can be arranged in a rectangular array with three columns as shown below:
8, 16, 12;
8, 16, 12;
8, 16, 12;
8, 16, 12;
...
		

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{0,0,1},{0,2,4,4,8,8,8,8,16,12},90] (* Harvey P. Dale, Dec 31 2018 *)
  • PARI
    concat(0, Vec(2*x*(1 + 2*x + 2*x^2 + 3*x^3 + 2*x^4 + 2*x^5 + 4*x^7 + 2*x^8) / ((1 - x)*(1 + x + x^2)) + O(x^100))) \\ Colin Barker, Nov 12 2017

Formula

G.f.: 2*x*(1 + 2*x + 2*x^2 + 3*x^3 + 2*x^4 + 2*x^5 + 4*x^7 + 2*x^8) / ((1 - x)*(1 + x + x^2)). - Colin Barker, Nov 12 2017

A095100 Integers m of the form 4k+3 for which all sums Sum_{i=1..u} J(i/m) (with u ranging from 1 to (m-1)) are nonnegative, where J(i/m) is Jacobi symbol of i and m.

Original entry on oeis.org

3, 7, 11, 15, 23, 27, 31, 35, 39, 47, 55, 59, 63, 71, 75, 79, 83, 87, 95, 103, 111, 119, 131, 135, 143, 151, 159, 167, 171, 175, 183, 191, 199, 215, 231, 239, 243, 251, 255, 263, 271, 279, 287, 295, 299, 303, 311, 319, 327, 335, 343, 351, 359, 363
Offset: 1

Views

Author

Antti Karttunen, Jun 01 2004

Keywords

Comments

Integers whose Jacobi-vector forms a valid Motzkin-path.

Crossrefs

Subset of A095102. Complement of A095101 in A004767.
Cf. A095090.

Programs

  • Mathematica
    isMotzkin[n_, k_] := Module[{s = 0, r = True}, Do[s += JacobiSymbol[i, n]; If[s < 0, r = False; Break[]], {i, 1, k}]; r]; A095100[n_] := Select[4*Range[0, n+1]+3, isMotzkin[#, Quotient[#, 2]] &]; A095100[90] (* Jean-François Alcover, Oct 08 2013, translated from Sage *)
  • PARI
    isok(m) = {if(m%4<3, return(0)); my(s=0); for(i=1, m-1, if((s+=kronecker(i, m))<0, return(0))); 1; } \\ Jinyuan Wang, Jul 20 2020
  • Sage
    def is_Motzkin(n, k):
        s = 0
        for i in range(1, k + 1) :
            s += jacobi_symbol(i, n)
            if s < 0: return False
        return True
    def A095100_list(n):
        return [m for m in range(3, n + 1, 4) if is_Motzkin(m, m // 2)]
    A095100_list(363) # Peter Luschny, Aug 08 2012
    

Formula

a(n) = 4*A095274(n) + 3.

A176255 Numbers of the form 4k-1 with least prime divisor of the form 4m+1.

Original entry on oeis.org

35, 55, 95, 115, 155, 175, 215, 235, 247, 275, 295, 299, 323, 335, 355, 391, 395, 403, 415, 455, 475, 515, 527, 535, 559, 575, 595, 611, 635, 655, 695, 715, 731, 755, 767, 775, 799, 815, 835, 871, 875, 895, 899, 923, 935, 955, 995, 1003, 1015, 1027, 1055
Offset: 1

Views

Author

Vladimir Shevelev, Apr 13 2010

Keywords

Comments

By definition, all terms are composite numbers.

Crossrefs

Programs

  • Magma
    [n: n in [1..1500] |  (n mod 4 eq 3) and (Min(PrimeFactors(n)) mod 4) eq 1]; // Vincenzo Librandi, Feb 07 2016
  • Maple
    A020639 := proc(n) if n = 1 then 1; else min(op(numtheory[factorset](n))) ; end if; end proc:
    isA176255 := proc(n) (n mod 4 = 3) and ( A020639(n) mod 4 = 1) ; end proc:
    for n from 3 to 1200 by 4 do if isA176255(n) then printf("%d,",n); end if; end do:
    # R. J. Mathar, Oct 30 2010
  • Mathematica
    Select[4 Range@ 265 - 1, Mod[#, 4] == 1 &[FactorInteger[#][[1, 1]]] &] (* Michael De Vlieger, Feb 07 2016 *)
  • PARI
    isok(n) = ((n % 4) == 3) && ((vecmin(factor(n)[,1]) % 4) == 1); \\ Michel Marcus, Feb 07 2016
    

Extensions

Terms > 559 from R. J. Mathar, Oct 30 2010

A239126 Rectangular array showing the starting values M(n, k), k >= 1, for the Collatz operation (ud)^n, n >= 1, ending in an odd number, read by antidiagonals.

Original entry on oeis.org

3, 7, 7, 11, 15, 15, 15, 23, 31, 31, 19, 31, 47, 63, 63, 23, 39, 63, 95, 127, 127, 27, 47, 79, 127, 191, 255, 255, 31, 55, 95, 159, 255, 383, 511, 511, 35, 63, 111, 191, 319, 511, 767, 1023, 1023, 39, 71, 127, 223, 383, 639, 1023, 1535, 2047, 2047
Offset: 1

Views

Author

Wolfdieter Lang, Mar 13 2014

Keywords

Comments

The companion array and triangle for the odd end numbers N(n, k) is given in A239127.
The two operations on natural numbers m used in the Collatz 3x+1 conjecture are here (following the M. Trümper paper given in the link) denoted by u for 'up' and d for 'down': u m = 3*m+1, if m is odd, and d m = m/2 if m is even. The present array gives all start numbers M(n, k) for the Collatz word (ud)^n = s^n (s = ud is useful because, except for the one letter word u, at least one d follows a letter u), with n >= 1, and k >= 1. Such Collatz sequences have the maximal number of u's (grow fastest).
This rectangular array is M of Example 2.2. with x=y = n, n >= 1, of the M. Trümper reference, pp. 7-8, written as a triangle by taking NE-SW diagonals. The Collatz sequence starting with M(n, k) has length 2*n+1 for each k and it ends in the odd number N(n, k) given in A239127.
The first row sequences of the array M (columns of triangle TM) are A004767, A004771, A125169, A239128, ...

Examples

			The rectangular array M(n, k) begins:
n\k     1    2    3    4     5     6     7     8     9    10 ...
1:      3    7   11   15    19    23    27    31    35    39
2:      7   15   23   31    39    47    55    63    71    79
3:     15   31   47   63    79    95   111   127   143   159
4:     31   63   95  127   159   191   223   255   287   319
5:     63  127  191  255   319   383   447   511   575   639
6:    127  255  383  511   639   767   895  1023  1151  1279
7:    255  511  767 1023  1279  1535  1791  2047  2303  2559
8:    511 1023 1535 2047  2559  3071  3583  4095  4607  5119
9:   1023 2047 3071 4095  5119  6143  7167  8191  9215 10239
10:  2047 4095 6143 8191 10239 12287 14335 16383 18431 20479
...
The triangle TM(m, n) begins (zeros are not shown):
m\n   1    2     3     4     5     6      7      8      9    10 ...
1:    3
2:    7    7
3:   11   15    15
4:   15   23    31    31
5:   19   31    47    63    63
6:   23   39    63    95   127   127
7:   27   47    79   127   191   255    255
8:   31   55    95   159   255   383    511    511
9:   35   63   111   191   319   511    767   1023   1023
10:  39   71   127   223   383   639   1023   1535   2047  2047
...
---------------------------------------------------------------------
n=1, ud, k=1: M(1, 1) = 3 = TM(1, 1), N(1,1) = 5 with the Collatz sequence  [3, 10, 5] of length 3.
n=1, ud, k=2: M(1, 2) = 7 = TM(2, 1), N(1,2) = 11 with the Collatz sequence  [7, 22, 11] of length 3.
n=4, (ud)^4, k=2: M(4, 2) = 63 = TM(5, 4), N(4,2) = 323 with the Collatz sequence  [63, 190, 95, 286, 143, 430, 215, 646, 323] of length 9.
n=5, (ud)^5, k=1: M(5, 1) = 63 =  TM(5, 5), N(5,1) = 485 with the Collatz sequence  [63, 190, 95, 286, 143, 430, 215, 646, 323, 970, 485] of length 11.
		

Crossrefs

Formula

The array: M(n, k) = 2^(n+1)*k - 1 for n >= 1 and k >= 1.
The triangle: TM(m, n) = M(n, m-n+1) = 2^(n+1)*(m-n+1) - 1 for m >= n >= 1 and 0 for m < n.
a(n) = 4*A087808(A130328(n-1)) - 1 (conjectured). - Christian Krause, Jun 15 2021

A289841 Number of elements added at n-th stage to the structure of the complex square cross described in A289840.

Original entry on oeis.org

0, 1, 2, 8, 8, 8, 8, 32, 16, 16, 16, 48, 16, 16, 16, 64, 48, 32, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48, 48, 32, 80, 16, 16, 16, 64, 48
Offset: 0

Views

Author

Omar E. Pol, Jul 14 2017

Keywords

Comments

For n = 0..17 the sequence is similar to the known toothpick sequences.
The surprising fact is that for n >= 18 the sequence has a periodic tail. More precisely, it has period 8: repeat [32, 80, 16, 16, 16, 64, 48, 48]. This tail is in accordance with the expansion of the four arms of the cross. The tail also can be written starting from the 20th stage, with period 8: repeat [16, 16, 16, 64, 48, 48, 32, 80], (see example).
This sequence is essentially the first differences of A289840. The behavior is similar to A290221 and A294021 in the sense that these three sequences from cellular automata have the property that after the initial terms the continuation is a periodic sequence. - Omar E. Pol, Oct 29 2017

Examples

			For n = 0..17 the sequence is 0, 1, 2, 8, 8, 8, 8, 32, 16, 16, 16, 48, 16, 16, 16, 64, 48, 32;
Terms 18 and beyond can be arranged in a rectangular array with eight columns as shown below:
32, 80, 16, 16, 16, 64, 48, 48;
32, 80, 16, 16, 16, 64, 48, 48;
32, 80, 16, 16, 16, 64, 48, 48;
32, 80, 16, 16, 16, 64, 48, 48;
32, 80, 16, 16, 16, 64, 48, 48;
...
On the other hand, in accordance with the periodic structure of the arms of the square cross, the terms 20 and beyond can be arranged in a rectangular array with eight columns as shown below:
16, 16, 16, 64, 48, 48, 32, 80;
16, 16, 16, 64, 48, 48, 32, 80;
16, 16, 16, 64, 48, 48, 32, 80;
16, 16, 16, 64, 48, 48, 32, 80;
16, 16, 16, 64, 48, 48, 32, 80;
...
		

Crossrefs

Programs

  • PARI
    concat(0, Vec(x*(1 + 2*x + 8*x^2 + 8*x^3 + 8*x^4 + 8*x^5 + 32*x^6 + 16*x^7 + 15*x^8 + 14*x^9 + 40*x^10 + 8*x^11 + 8*x^12 + 8*x^13 + 32*x^14 + 32*x^15 + 16*x^16 + 16*x^17 + 32*x^18 + 16*x^24) / ((1 - x)*(1 + x)*(1 + x^2)*(1 + x^4)) + O(x^100))) \\ Colin Barker, Nov 12 2017

Formula

G.f.: x*(1 + 2*x + 8*x^2 + 8*x^3 + 8*x^4 + 8*x^5 + 32*x^6 + 16*x^7 + 15*x^8 + 14*x^9 + 40*x^10 + 8*x^11 + 8*x^12 + 8*x^13 + 32*x^14 + 32*x^15 + 16*x^16 + 16*x^17 + 32*x^18 + 16*x^24) / ((1 - x)*(1 + x)*(1 + x^2)*(1 + x^4)). - Colin Barker, Nov 12 2017

A369056 Numbers k of the form 4m+3 for which there is no representation as a sum (p*q + p*r + q*r) with three odd primes p <= q <= r.

Original entry on oeis.org

3, 7, 11, 15, 19, 23, 31, 35, 43, 47, 59, 63, 67, 79, 83, 99, 107, 115, 127, 139, 143, 159, 163, 171, 175, 179, 207, 219, 223, 227, 235, 243, 259, 279, 283, 295, 303, 307, 319, 323, 339, 347, 367, 379, 387, 399, 403, 415, 427, 443, 463, 499, 515, 523, 531, 547, 559, 571, 579, 595, 603, 619, 639, 643, 655, 659, 675
Offset: 1

Views

Author

Antti Karttunen, Jan 20 2024

Keywords

Comments

Numbers k in A004767 for which A369054(k) = 0.
Numbers k of the form 4m-1 such that they are not arithmetic derivative (A003415) of any term of A046316.
Question: Is it possible that this sequence might be finite (although very long)? See comments in A369055.

Crossrefs

Setwise difference A004767 \ A369251.
Subsequences: A369248 (terms that are multiples of 3), A369249 (primes in this sequence).
Cf. also A369250 (4m+3 primes missing from this sequence).

Programs

  • Maple
    N:= 1000: # for terms <= N
    S:= {seq(i,i=3..N,4)}:
    P:= select(isprime, [seq(i,i=3..N/3,2)]):
    for i from 1 to nops(P) do
      p:= P[i];
      for j from i to nops(P) do
        q:= P[j];
        if 2*p*q + q^2 > N then break fi;
        for k from j to nops(P) do
          r:= P[k];
          v:= p*q + p*r + q*r;
          if v > N then break fi;
          S:= S minus {v};
    od od od:
    sort(convert(S,list)); # Robert Israel, Apr 17 2024
  • PARI
    isA369056(n) = ((3==(n%4)) && !A369054(n)); \\ Needs also program from A369054.

A370655 Triangle read by rows where row n is a block of length 4*n-1 which is a permutation of the numbers of its constituents.

Original entry on oeis.org

2, 1, 3, 4, 5, 7, 6, 8, 9, 10, 13, 14, 11, 12, 16, 15, 17, 20, 19, 18, 21, 26, 27, 24, 25, 22, 23, 29, 28, 30, 35, 32, 33, 34, 31, 36, 43, 44, 41, 42, 39, 40, 37, 38, 46, 45, 47, 54, 49, 52, 51, 50, 53, 48, 55
Offset: 1

Views

Author

Boris Putievskiy, Feb 24 2024

Keywords

Comments

Generalization of the Cantor numbering method for two adjacent diagonals. A pair of neighboring diagonals are combined into one block.
The sequence is a self-inverse permutation of natural numbers.
The sequence is an intra-block permutation of integer positive numbers.
The sequence A373498 generates the cyclic group C6 under composition. The elements of C6 are the successive compositions of A373498 with itself: A374494 = A373498(A373498) = A373498^2, A370655 = A373498^3, A374531 = A373498^4, A374447 = A373498^5. The identity element is A000027 = A373498^6. - Boris Putievskiy, Aug 03 2024

Examples

			Triangle begins:
     k = 1   2   3   4   5   6   7   8   9  10  11
  n=1:   2,  1,  3;
  n=2:   4,  5,  7,  6,  8,  9, 10;
  n=3:  13, 14, 11, 12, 16, 15, 17, 20, 19, 18, 21;
Subtracting (n-1)*(2*n-1) from each term is row n is a self-inverse permutation of 1 .. 4*n-1,
  2,1,3,
  1,2,4,3,5,6,7,
  3,4,1,2,6,5,7,10,9,8,11,
  ...
The triangle rows can be arranged as two successive upward antidiagonals in an array:
   2,  3,  7, 10, 16, 21, ...
   1,  5,  9, 12, 18, 23, ...
   4,  8, 11, 19, 22, 34, ...
   6, 14, 20, 25, 33, 40, ...
  13, 17, 24, 32, 39, 51, ...
  15, 27, 35, 42, 52, 61, ...
		

Crossrefs

Programs

  • Mathematica
    Nmax = 21;
    a[n_] := Module[{L, R, P, Result}, L = Ceiling[(Sqrt[8*n + 1] - 1)/4];
      R = n - (L - 1)*(2*L - 1);
      P = If[R < 2*L - 1, If[Mod[R, 2] == 1, -R + 2*L - 2, -R + 2*L],
        If[R == 2*L - 1, 2*L,
         If[R == 2*L, R - 1, If[Mod[R, 2] == 1, R, 6*L - R]]]];
      Result = P + (L - 1)*(2*L - 1);
      Result]
    Table[a[n], {n, 1, Nmax}]

Formula

Linear sequence:
a(n) = P(n) + (L(n)-1)*(2*L(n)-1), where L(n) = ceiling((sqrt(8*n+1)-1)/4),
L(n) = A204164(n),
R(n) = n - (L(n)-1)*(2*L(n)-1),
P(n) = -R(n) + 2*L(n)-2, if R(n) < 2*L(n) - 1 and R(n) mod 2 = 1, P(n) = -R(n) + 2*L(n), if R(n) < 2*L(n) - 1 and R(n) mod 2 = 0, P(n) = 2*L(n), if R(n) = 2*L(n) - 1, P(n) = R(n)-1, if R(n) = 2*L(n), P(n) = R(n), if R(n) > 2*L(n) and R(n) mod 2 = 1, P(n) = 6*L(n) - R(n), if R(n) > 2*L(n) and R(n) mod 2 = 0.
Triangular array T(n,k) for 1 <= k <= 4*n-1 (see Example):
T(n,k) = (n-1)*(2*n-1) + P(n,k), where
P(n,k) = 2*n-k-2 if k < 2*n-1 and k mod 2 = 1,
2*n-k if k < 2*n-1 and k mod 2 = 0,
2*k if k = 2*n-1,
k-1 if k = 2*n,
k if k > 2*n and k mod 2 = 1,
6*n-k if k > 2*n and k mod 2 = 0.

A013777 a(n) = 2^(4*n + 3).

Original entry on oeis.org

8, 128, 2048, 32768, 524288, 8388608, 134217728, 2147483648, 34359738368, 549755813888, 8796093022208, 140737488355328, 2251799813685248, 36028797018963968, 576460752303423488, 9223372036854775808, 147573952589676412928, 2361183241434822606848, 37778931862957161709568
Offset: 0

Views

Author

Keywords

Crossrefs

Subsequence of A000079.
Cf. A004767.

Programs

Formula

From Philippe Deléham, Nov 23 2008: (Start)
a(n) = 16*a(n-1); a(0)=8.
G.f.: 8/(1-16*x). (End)
From Elmo R. Oliveira, Feb 18 2025: (Start)
E.g.f.: 8*exp(16*x).
a(n) = A000079(A004767(n)). (End)

A033566 a(n) = (2*n+1) * (4*n-1).

Original entry on oeis.org

-1, 9, 35, 77, 135, 209, 299, 405, 527, 665, 819, 989, 1175, 1377, 1595, 1829, 2079, 2345, 2627, 2925, 3239, 3569, 3915, 4277, 4655, 5049, 5459, 5885, 6327, 6785, 7259, 7749, 8255, 8777, 9315, 9869, 10439, 11025, 11627, 12245, 12879, 13529, 14195, 14877, 15575, 16289, 17019, 17765
Offset: 0

Views

Author

Keywords

Crossrefs

Programs

  • GAP
    List([0..50], n-> (2*n+1)*(4*n-1)); # G. C. Greubel, Oct 12 2019
  • Magma
    [(2*n+1)*(4*n-1): n in [0..50]]; // G. C. Greubel, Oct 12 2019
    
  • Maple
    seq((2*n+1)*(4*n-1), n=0..50); # G. C. Greubel, Oct 12 2019
  • Mathematica
    Table[(2*n+1)*(4*n-1), {n, 0, 50}] (* G. C. Greubel, Oct 12 2019 *)
  • PARI
    a(n) = (2*n+1) * (4*n-1); \\ Michel Marcus, Oct 03 2016
    
  • Sage
    [(2*n+1)*(4*n-1) for n in range(50)] # G. C. Greubel, Oct 12 2019
    

Formula

a(n) = A005408(n) * A004767(n-1). - Michel Marcus, Oct 03 2016
From G. C. Greubel, Oct 12 2019: (Start)
G.f.: (-1 + 12*x + 5*x^2)/(1-x)^3.
E.g.f.: (-1 + 10*x + 8*x^2)*exp(x). (End)
Sum_{n>=0} 1/a(n) = -2/3 +log(2)/6-Pi/12 = -0.81294152437.. - R. J. Mathar, May 07 2024

Extensions

Terms a(37) onward added by G. C. Greubel, Oct 12 2019

A166092 Integers (all of the form 4k+3) organized into an array based on the number of times Sum_{i=1..u} J(i,4k+3) obtains value zero when u ranges from 1 to (4k+3), where J(i,k) is the Jacobi symbol.

Original entry on oeis.org

3, 7, 11, 15, 319, 19, 23, 607, 35, 415, 31, 703, 59, 1639, 91, 39, 895, 63, 2359, 175, 43, 47, 1063, 103, 3995, 575, 127, 51, 55, 1103, 131, 5191, 631, 295, 83, 67, 71, 1135, 251, 5459, 731, 635, 223, 115, 27, 79, 1447, 279, 7567, 1175, 659, 735, 139
Offset: 0

Views

Author

Antti Karttunen, Oct 08 2009

Keywords

Comments

Note: these are all of the form 4k+3, but still this is not permutation of A004767 (for the reason explained in A166091). Sequence A165603 gives the 4k+3 integers missing from this table.This square array A(row>=0, col>=0) is listed antidiagonally as A(0,0), A(0,1), A(1,0), A(0,2), A(1,1), A(2,0), ...

Examples

			The top left corner of the array:
3, 7, 15, 23, 31, 39, ...
11, 319, 607, 703, 895, 1063, ...
19, 35, 59, 63, 103, 131, ...
415, 1639, 2359, 3995, 5191, 5459, ...
91, 175, 575, 631, 731, 1175, ...
		

Crossrefs

a(n) = A004767(A166091(n)). The leftmost column: A166096. The first five rows: A165469, A166053, A166055, A166057, A166059. Cf. also A112070.
Previous Showing 51-60 of 218 results. Next