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

A349407 The Farkas map: a(n) = x/3 if x mod 3 = 0; a(n) = (3x+1)/2 if x mod 3 <> 0 and x mod 4 = 3; a(n) = (x+1)/2 if x mod 3 <> 0 and x mod 4 = 1, where x = 2*n-1.

Original entry on oeis.org

1, 1, 3, 11, 3, 17, 7, 5, 9, 29, 7, 35, 13, 9, 15, 47, 11, 53, 19, 13, 21, 65, 15, 71, 25, 17, 27, 83, 19, 89, 31, 21, 33, 101, 23, 107, 37, 25, 39, 119, 27, 125, 43, 29, 45, 137, 31, 143, 49, 33, 51, 155, 35, 161, 55, 37, 57, 173, 39, 179, 61, 41, 63, 191, 43
Offset: 1

Views

Author

Paolo Xausa, Nov 16 2021

Keywords

Comments

The map takes a positive odd integer x (= 2*n-1) and produces the positive odd integer a(n).
Farkas proves that the trajectory of the iterates of the map starting from any positive odd integer always reaches 1.
If displayed as a rectangular array with six columns, the columns include A016921, A016813, A016945, A004767, A239129 (see example). - Omar E. Pol, Jan 01 2022

Examples

			From _Omar E. Pol_, Jan 01 2022: (Start)
Written as a rectangular array with six columns read by rows the sequence begins:
   1,  1,  3,  11,  3,  17;
   7,  5,  9,  29,  7,  35;
  13,  9, 15,  47, 11,  53;
  19, 13, 21,  65, 15,  71;
  25, 17, 27,  83, 19,  89;
  31, 21, 33, 101, 23, 107;
  37, 25, 39, 119, 27, 125;
  43, 29, 45, 137, 31, 143;
  49, 33, 51, 155, 35, 161;
  55, 37, 57, 173, 39, 179;
...
(End)
		

References

  • H. M. Farkas, "Variants of the 3N+1 Conjecture and Multiplicative Semigroups", in Entov, Pinchover and Sageev, "Geometry, Spectral Theory, Groups, and Dynamics", Contemporary Mathematics, vol. 387, American Mathematical Society, 2005, p. 121.
  • J. C. Lagarias, ed., The Ultimate Challenge: The 3x+1 Problem, American Mathematical Society, 2010, p. 74.

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{0,0,0,0,0,2,0,0,0,0,0,-1},{1,1,3,11,3,17,7,5,9,29,7,35},100]
    Table[Which[Mod[n,3]==0,n/3,Mod[n,4]==3,(3n+1)/2,True,(n+1)/2],{n,1,200,2}] (* Harvey P. Dale, May 15 2022 *)
  • PARI
    a(n)=if (n%3==2, 2*n\3, if (n%2, n, 3*n-1)) \\ Charles R Greathouse IV, Nov 16 2021
    
  • Python
    def a(n):
        x = 2*n - 1
        return x//3 if x%3 == 0 else ((3*x+1)//2 if x%4 == 3 else (x+1)//2)
    print([a(n) for n in range(1, 66)]) # Michael S. Branicky, Nov 16 2021

A239127 Rectangular companion array to M(n,k), given in A239126, showing the end numbers N(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

5, 11, 17, 17, 35, 53, 23, 53, 107, 161, 29, 71, 161, 323, 485, 35, 89, 215, 485, 971, 1457, 41, 107, 269, 647, 1457, 2915, 4373, 47, 125, 323, 809, 1943, 4373, 8747, 13121, 53, 143, 377, 971, 2429, 5831, 13121, 26243, 39365, 59, 161, 431, 1133, 2915, 7289, 17495, 39365, 78731, 118097
Offset: 1

Views

Author

Wolfdieter Lang, Mar 13 2014

Keywords

Comments

The companion array and triangle for the odd start numbers M(n, k) is given in A239126.
See the comments on A239126 for the Collatz 3x+1 problem and the u and d operations.
This rectangular array is N of the 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 odd M(n, k) from A239126 and ending in odd N(n, k) has length 2*n+1 for each k.
The first row sequences of the array N (columns of triangle TN) are A016969, A239129, ...

Examples

			The rectangular array N(n, k) begins:
n\k      1      2      3      4      5      6     7       8       9      10 ...
1:       5     11     17     23     29     35     41     47      53      59
2:      17     35     53     71     89    107    125    143     161     179
3:      53    107    161    215    269    323    377    431     485     539
4:     161    323    485    647    809    971   1133   1295    1457    1619
5:     485    971   1457   1943   2429   2915   3401   3887    4373    4859
6:    1457   2915   4373   5831   7289   8747  10205  11663   13121   14579
7:    4373   8747  13121  17495  21869  26243  30617  34991   39365   43739
8:   13121  26243  39365  52487  65609  78731  91853 104975  118097  131219
9:   39365  78731 118097 157463 196829 236195 275561 314927  354293  393659
10: 118097 236195 354293 472391 590489 708587 826685 944783 1062881 1180979
...
-------------------------------------------------------------------------------
The triangle TN(m, n) begins (zeros are not shown):
m\n   1   2  3     4    5    6     7     8     9     10 ...
1:    5
2:   11  17
3:   17  35  53
4:   23  53 107  161
5:   29  71 161  323  485
6:   35  89 215  485  971 1457
7:   41 107 269  647 1457 2915  4373
8:   47 125 323  809 1943 4373  8747 13121
9:   53 143 377  971 2429 5831 13121 26243 39365
10:  59 161 431 1133 2915 7289 17495 39365 78731 118097
...
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: N(n, k) = 2*3^n*k - 1 for n >= 1 and k >= 1.
The triangle: TN(m, n) = N(n, m-n+1) = 2*3^n*(m-n+1) - 1 for m >= n >= 1 and 0 for m < n.

A350522 a(n) = 18*n + 16.

Original entry on oeis.org

16, 34, 52, 70, 88, 106, 124, 142, 160, 178, 196, 214, 232, 250, 268, 286, 304, 322, 340, 358, 376, 394, 412, 430, 448, 466, 484, 502, 520, 538, 556, 574, 592, 610, 628, 646, 664, 682, 700, 718, 736, 754, 772, 790, 808, 826, 844, 862, 880, 898, 916, 934, 952, 970
Offset: 0

Views

Author

Omar E. Pol, Jan 03 2022

Keywords

Comments

Sixth column of A006370 (the Collatz or 3x+1 map) when it is interpreted as a rectangular array with six columns read by rows.

Crossrefs

Programs

  • GAP
    List([0..53], n-> 18*n+16)
    
  • Magma
    [18*n+16: n in [0..53]];
    
  • Maple
    seq(18*n+16, n=0..53);
  • Mathematica
    Table[18n+16, {n, 0, 53}]
  • Maxima
    makelist(18*n+16, n, 0, 53);
    
  • PARI
    a(n)=18*n+16
    
  • Python
    [18*n+16 for n in range(53)]

Formula

a(n) = A239129(n+1) - 1.
From Stefano Spezia, Jan 04 2022: (Start)
O.g.f.: 2*(8 + x)/(1 - x)^2.
E.g.f.: 2*exp(x)*(8 + 9*x).
a(n) = 2*a(n-1) - a(n-2) for n > 1. (End)
a(n) = 3*A008588(n+1) - 2. - Leo Tavares, Sep 14 2022
From Elmo R. Oliveira, Apr 12 2024: (Start)
a(n) = 2*A017257(n) = A006370(A016969(n)).
a(n) = 2*(A062728(n+1) - A062728(n)). (End)

A251731 Least k such that k^3 + q is divisible by 3^n where q is the n-th number congruent to 1 or -1 (mod 18).

Original entry on oeis.org

2, 1, 2, 16, 32, 145, 62, 1363, 3458, 19492, 58928, 89308, 70028, 1594318, 1890551, 189871, 31401806, 47918575, 190704887, 163454602, 502048577, 9481323661, 11627845304, 34656488290, 115450061084, 286130228125, 2303721331049, 1569269836240, 22013516320412
Offset: 1

Views

Author

Michel Lagneau, Dec 07 2014

Keywords

Comments

It is known that k always exists if q is congruent to +-1 mod 18.
The numbers congruent to 1 or -1 (mod 18) are 1, 17, 19, 35, 37, ... = {A161705} UNION {A239129}.
For n >= 2, k^3 == (9 - 18*n - 7*(-1)^n)/2 (mod 3^n) if and only if k - a(n) is divisible by 3^(n-1). - Jinyuan Wang, Feb 13 2020

Examples

			a(1) = 2 because the first number of the form +-1 (mod 18) is 1, and 2^3 + 1 = 9 = 3*3^1;
a(2) = 1 because the second number of the form +-1 (mod 18) is 17, and 1^3 + 17 = 18 = 2*3^2;
a(3) = 2 because the third number of the form +-1 (mod 18) is 19, and 2^3 + 19 = 27 = 3^3;
a(4)= 16 because the fourth number of the form +-1 (mod 18) is 35, and 16^3 + 35 = 4131 = 51*3^4.
		

Crossrefs

Programs

  • Maple
    f:= proc(n) local q,R,k;
      if n::odd then q:= 9*n-8 else q:= 9*n-1 fi;
      min(map(subs,[msolve(k^3+q,3^n)],k))
    end proc:
    map(f, [$1..30]); # Robert Israel, Dec 23 2018
  • Mathematica
    lst1={1};Do[lst1=Union[lst1,Union[{18*n+1},{18*n-1}]],{n,1,10}];lst={};Do[k=1;While[Mod[k^3+lst1[[n]],3^n]!=0,k++];Print[n," ",k],{n,1,10}];lst
  • PARI
    a(n) = {if (n % 2, q = 9*(n-1)+1, q = 9*n-1); m = 3^n; k = 1; while ((k^3+q) % m, k++); k;} \\ Michel Marcus, Jan 07 2015
Showing 1-4 of 4 results.