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.

A083044 Square table read by antidiagonals forms a permutation of the natural numbers: T(n,0) = floor(n*x/(x-1))+1, T(n,k+1) = ceiling(x*T(n,k)), where x=3/2, n >= 0, k >= 0.

Original entry on oeis.org

1, 2, 4, 3, 6, 7, 5, 9, 11, 10, 8, 14, 17, 15, 13, 12, 21, 26, 23, 20, 16, 18, 32, 39, 35, 30, 24, 19, 27, 48, 59, 53, 45, 36, 29, 22, 41, 72, 89, 80, 68, 54, 44, 33, 25, 62, 108, 134, 120, 102, 81, 66, 50, 38, 28, 93, 162, 201, 180, 153, 122, 99, 75, 57, 42, 31, 140, 243
Offset: 0

Views

Author

Paul D. Hanna, Apr 18 2003

Keywords

Comments

First row is A061419, first column is T(n,0) = A016777(n) = 3n+1 (namely the numbers not of the form ceiling(3*k/2) for any natural number k, in increasing order), main diagonal is A083045, antidiagonal sums give A083046. [further detail on first column added by Glen Whitney, Aug 03 2018]
A083044 is the dispersion of the sequence A007494 of positive integers congruent to (0 or 2) mod 3; see A191655. - Clark Kimberling, Jun 10 2011
If T(n+1,k) - T(n,k) = 2m, then T(n+1,k+1) - T(n,k+1) = ceiling(3T(n+1,k)/2) - ceiling(3T(n,k)/2) = ceiling(3T(n,k)/2 + 3m) - ceiling(3T(n,k)/2) = 3m. Similarly, if T(n+1,k) - T(n,k) = 2m+1, then T(n+1,k+1) - T(n,k+1) = ceiling(3T(n,k)/2 + 3m + 3/2) - ceiling(3T(n,k)/2) = {3m+1 or 3m+2, according to whether T(n,k) is even or odd}. The first differences of the first column T(n,0) are periodic: (3)*. The parities of the first column T(n,0) are periodic: (odd,even)*. Hence by induction using the prior two observations, the first differences and parities of every column will be periodic; e.g., for the second column T(n,2): the first differences are (4,5)* and the parities are (even,even,odd,odd)*; for the third column T(n,3): (6,8,6,7)* and (odd,odd,odd,odd,even,even,even,even)*; for the fourth column T(n,4): (9,12,9,10,9,12,9,11)* and (o,e,e,o,o,e,e,o,e,o,o,e,e,o,o,e)*. Is the period length of the first differences of column k always 2^{k-1}? And is the period length of parities always 2^k? Does every integer > 2 occur as T(n+1,k) - T(n,k) for some n and k? Is the smallest first difference in column k always A061418(k+1)? And is the largest first difference in column k always A061419(k+2)? - Glen Whitney, Aug 03 2018
Consider the following two-player game: Start with two nonempty piles of counters. Players alternate taking turns consisting of first discarding one of the piles and then dividing the remaining pile into two nonempty piles. The smaller pile may always be discarded; the larger pile may only be discarded if the smaller pile is at least half as large. (Either pile may be discarded if they are equal.) The player who cannot move (because the configuration has reached two piles of one counter each) loses. Then the numbers c for which two piles of size c is a losing configuration (for the player whose turn it is) are exactly T(4,k) for k > 1, together with 1,3,5, and 9. - Glen Whitney, Aug 03 2018

Examples

			Table begins:
   1  2  3   5   8  12  18  27  41   62   93  140 ...
   4  6  9  14  21  32  48  72 108  162  243  365 ...
   7 11 17  26  39  59  89 134 201  302  453  680 ...
  10 15 23  35  53  80 120 180 270  405  608  912 ...
  13 20 30  45  68 102 153 230 345  518  777 1166 ...
  16 24 36  54  81 122 183 275 413  620  930 1395 ...
  19 29 44  66  99 149 224 336 504  756 1134 1701 ...
  22 33 50  75 113 170 255 383 575  863 1295 1943 ...
  25 38 57  86 129 194 291 437 656  984 1476 2214 ...
  28 42 63  95 143 215 323 485 728 1092 1638 2457 ...
  31 47 71 107 161 242 363 545 818 1227 1841 2762 ...
		

Crossrefs

Row in which a number occurs: A163491.
Column in which a number occurs: A087088.

Formula

T(A163491(n)-1, A087088(n)-1) = n. - Peter Munn, Jul 16 2020 [corrected Peter Munn, Aug 02 2020]

A087088 Positive ruler-type fractal sequence with 1's in every third position.

Original entry on oeis.org

1, 2, 3, 1, 4, 2, 1, 5, 3, 1, 2, 6, 1, 4, 2, 1, 3, 7, 1, 2, 5, 1, 3, 2, 1, 4, 8, 1, 2, 3, 1, 6, 2, 1, 4, 3, 1, 2, 5, 1, 9, 2, 1, 3, 4, 1, 2, 7, 1, 3, 2, 1, 5, 4, 1, 2, 3, 1, 6, 2, 1, 10, 3, 1, 2, 4, 1, 5, 2, 1, 3, 8, 1, 2, 4, 1, 3, 2, 1, 6, 5, 1, 2, 3, 1, 4, 2, 1, 7, 3, 1, 2, 11, 1, 4, 2, 1, 3, 5, 1, 2, 6, 1, 3, 2
Offset: 1

Views

Author

Enrico T. Federighi (rico125162(AT)aol.com), Aug 08 2003

Keywords

Comments

If all the terms in the sequence are reduced by one and then all zeros are removed, the result is the same as the original sequence.
From Benoit Cloitre, Mar 07 2009: (Start)
To construct the sequence:
Step 1: start from a sequence of 1's and leave two undefined places between every pair of 1's giving: 1,(),(),1,(),(),1,(),(),1,(),(),1,(),(),1,...
Step 2: replace the first undefined place with a 2 and henceforth leave two undefined places between two 2's giving: 1,2,(),1,(),2,1,(),(),1,2,(),1,(),2,1,...
Step 3: replace the first undefined place with a 3 and henceforth leave two undefined places between two 3's giving: 1,2,3,1,(),2,1,(),3,1,2,(),1,(),2,1,...
Step 4: replace the first undefined place with a 4 and leave 2 undefined places between two 4's giving: 1,2,3,1,4,2,1,(),3,1,2,(),1,4,2,1,... Iterating the process indefinitely yields the sequence: 1,2,3,1,4,2,1,5,3,1,2,6,1,4,2,1,... (End)
From Peter Munn, Jul 10 2020: (Start)
For k >= 1, the number k occurs in a pattern with fundamental period 3^k, and with points of mirror symmetry at intervals of (3^k)/2. Those points have an extrapolated common origin (for k >= 1) at an offset 1.5 to the left of the sequence's initial "1". The snake format illustration in the example section may be useful for visualizing this.
(End)
For k >= 1, k first occurs at position A061419(k) and its k-th occurrence is at position A083045(k-1). - Peter Munn, Aug 23 2020
(a(n)) is the unique fixed point of the two-block substitution a,b -> 1,a+1,b+1, where a,b are natural numbers. - Michel Dekking, Sep 26 2022

Examples

			From _Peter Munn_, Jul 03 2020: (Start)
Listing the terms in a snake format (with period 27) illustrates periodic and mirror symmetries. Horizontal lines mark points of mirror symmetry for 3's. Vertical lines mark further points of mirror symmetry for 2's. 79 terms are shown. (Referred to the extrapolated common origin of periodic mirror symmetry, the initial term is at offset 1.5 and the last shown is at offset 79.5 = 3^4 - 1.5.) Observe also mirror symmetry of 4's (seen vertically).
    1  2  3  1  4  2  1  5   3  1  2  6
             |             |            1 --
    1  2  3  1  5  2  1  7   3  1  2  4
_ 4
  8
    1  2  3  1  6  2  1  4   3  1  2  5
             |             |            1 --
    1  2  3  1  7  2  1  4   3  1  2  9
_ 5
  4
    1  2  3  1  6  2  1 10   3  1  2  4
             |             |            1 --
    1  2  3  1  4  2  1  8   3  1  2  5
(End)
From _Peter Munn_, Aug 22 2020: (Start)
The start of the sequence is shown below in conjunction with related sequences, aligning their points of mirror symmetry. The longer, and shorter, vertical lines indicate points of mirror symmetry for terms valued less than 4, and less than 3, respectively. Note each term of A051064 is the minimum of two terms displayed nearest below it, and each term of A254046 is the minimum of the two terms displayed diagonally above it.
        |                          |                          |
A051064:| 1 1 2 1 1 2 1 1 3 1 1 2 1 1 2 1 1 3 1 1 2 1 1 2 1 1 4 1 1 2
        |        |        |        |        |        |        |
[a(n)]: |  1 2 3 1 4 2 1 5 3 1 2 6 1 4 2 1 3 7 1 2 5 1 3 2 1 4 8 1 2 3
        |        |        |        |        |        |        |
A254046:|1 2 1 1 3 1 1 2 1 1 2 1 1 4 1 1 2 1 1 2 1 1 3 1 1 2 1 1 2 1 1
        |                          |                          |
(End)
		

Crossrefs

Sequences with equivalent symmetries: A051064, A254046.
Records are given by A061419: a(A061419(n))=n.
Essentially the odd bisection of A335933.
Sequence with similar definition: A087165.
Ordinal transform of A163491, with which this sequence has a joint relationship to A083044, A083045.
See also the comment in A024629.

Programs

Formula

a(n) = 1 when n == 1 (mod 3), otherwise a(n) = a(n-ceiling(n/3)) + 1.
a(n) = 3 + A244040(3*(n-1)) - A244040(3*n). - Tom Edgar and James Van Alstine, Aug 04 2014
From Peter Munn, Aug 22 2020: (Start)
For m >= 0, a(3*m+1) = 1; a(3*m+2) = a(2*m+1) + 1; a(3*m+3) = a(2*m+2) + 1.
For n >= 1, the following identities hold.
a(n) = A335933(2*n+1).
A083044(A163491(n) - 1, a(n) - 1) = n.
A051064(n+1) = min(a(n), a(n+1)).
A254046(n+2) = min(a(n), a(n+2)). (End)

Extensions

More terms from Paul D. Hanna, Aug 21 2003
Offset changed by M. F. Hasler (following remarks by Peter Munn), Jul 13 2020
Thanks to Allan C. Wechsler for suggesting the new name. - N. J. A. Sloane, Jul 14 2020

A163491 A fractal sequence (if we delete the first occurrence of n we get the sequence itself).

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 3, 1, 2, 4, 3, 1, 5, 2, 4, 6, 3, 1, 7, 5, 2, 8, 4, 6, 9, 3, 1, 10, 7, 5, 11, 2, 8, 12, 4, 6, 13, 9, 3, 14, 1, 10, 15, 7, 5, 16, 11, 2, 17, 8, 12, 18, 4, 6, 19, 13, 9, 20, 3, 14, 21, 1, 10, 22, 15, 7, 23, 5, 16, 24, 11, 2, 25, 17, 8, 26, 12
Offset: 1

Views

Author

Benoit Cloitre, Jul 29 2009

Keywords

Comments

Write the positive integers with two spaces between each integer: 1,,,2,,,3,,,4,,,5,,,6,..., and fill undefined places with the sequence itself. A003602 is obtained by starting from 1,,2,,3,,4,,5,_,6,....
From Peter Munn, Aug 02 2020: (Start)
a(n) - 1 is the row of A083044 in which n occurs.
The m-th occurrence of m is at position A083045(m-1).
(End)

Examples

			  1,_,_,2,_,_,3,_,_,4,... -->
  1,1,_,2,_,_,3,_,_,4,... -->
  1,1,1,2,_,_,3,_,_,4,... -->
  1,1,1,2,1,_,3,_,_,4,... -->
  1,1,1,2,1,2,3,_,_,4,... -->
  1,1,1,2,1,2,3,_,_,4,... -->
  1,1,1,2,1,2,3,1,_,4,... -->
  1,1,1,2,1,2,3,1,2,4,... -->
  ...
		

Crossrefs

Ordinal transform of A087088.

Programs

  • Mathematica
    a[n_] := a[n] = If[Mod[n, 3] == 1, (n+2)/3, a[Floor[2n/3]]];
    Array[a, 100] (* Jean-François Alcover, Jan 10 2022 *)
  • PARI
    a(n) = n+=2; my(q,r); while([q,r]=divrem(n,3); r, n-=q); q; \\ Kevin Ryde, Jan 16 2021
  • Python
    def a(n): return (n+2)//3 if n%3==1 else a(n*2//3)
    print([a(n) for n in range(1, 78)]) # Michael S. Branicky, Jan 16 2021
    

Formula

a(3n-2) = n.
A083044(a(n) - 1, A087088(n) - 1) = n. - Peter Munn, Aug 02 2020
From Rémy Sigrist, Jan 15 2021: (Start)
a(n+ceiling(n/2)) = a(n).
a(n) = 1 iff n belongs to A061419.
(End)
a(n) = (n+2)/3 if n == 1 (mod 3), otherwise a(n) = a(floor(n*2/3)). - Michael S. Branicky and Kevin Ryde, Jan 16 2021

Extensions

Terms after a(70) corrected by Jon E. Schoenfield, Nov 26 2015

A083046 Antidiagonal sums of table A083044.

Original entry on oeis.org

1, 6, 16, 35, 67, 118, 197, 319, 506, 789, 1215, 1860, 2830, 4290, 6481, 9771, 14708, 22120, 33239, 49921, 74946, 112490, 168807, 253286, 380008, 570095, 855228, 1282931, 1924490, 2886828, 4330341, 6495613, 9743524, 14615392, 21923196
Offset: 0

Views

Author

Paul D. Hanna, Apr 18 2003

Keywords

Crossrefs

Formula

a(n) = Sum_{k=0..n} T(k, n-k), where T(n, 0) = floor(n*x/(x-1))+1, T(n, k+1) = ceiling(x*T(n, k)), for n>=0, k>=0, with x=3/2.
Showing 1-4 of 4 results.