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

A361832 For any number k >= 0, let T_k be the triangle whose base corresponds to the ternary expansion of k (without leading zeros) and other values, say t above u and v, satisfy t = (-u-v) mod 3; the ternary expansion of a(n) corresponds to the left border of T_n (the most significant digit being at the bottom left corner).

Original entry on oeis.org

0, 1, 2, 5, 4, 3, 7, 6, 8, 16, 17, 15, 12, 13, 14, 11, 9, 10, 23, 21, 22, 19, 20, 18, 24, 25, 26, 50, 49, 48, 53, 52, 51, 47, 46, 45, 38, 37, 36, 41, 40, 39, 44, 43, 42, 35, 34, 33, 29, 28, 27, 32, 31, 30, 70, 69, 71, 64, 63, 65, 67, 66, 68, 58, 57, 59, 61, 60
Offset: 0

Views

Author

Rémy Sigrist, Mar 26 2023

Keywords

Comments

This sequence is a variant of A334727.
This sequence is a self-inverse permutation of the nonnegative integers that preserves the number of digits and the leading digit in base 3.

Examples

			For n = 42: the ternary expansion of 42 is "1120" and the corresponding triangle is as follows:
       2
      2 2
     1 0 1
    1 1 2 0
So the ternary expansion of a(42) is "1122", and a(42) = 44.
		

Crossrefs

Cf. A004488, A048328, A334727, A361818, A361833 (fixed points).

Programs

  • PARI
    a(n) = { my (d = digits(n, 3), t = vector(#d)); for (k = 1, #d, t[k] = d[1]; d = vector(#d-1, i, (-d[i]-d[i+1]) % 3);); fromdigits(t, 3); }

Formula

a(floor(n/3)) = floor(a(n)/3).
a(A004488(n)) = A004488(a(n)).
a(n) = n for any n in A048328.
a(n) = n iff b belongs to A361833.

A371636 For any number k >= 0, let T_k be the triangle with values in {-1, 0, +1} whose base corresponds to the balanced ternary expansion of k (without leading zeros) and other values, say t above u and v, satisfy t+u+v = 0 mod 3; this sequence lists the numbers k such that T_k has 3-fold rotational symmetry.

Original entry on oeis.org

0, 1, 4, 13, 19, 25, 40, 103, 112, 121, 154, 214, 364, 442, 505, 595, 673, 763, 826, 913, 1003, 1093, 1144, 1369, 1621, 1915, 2167, 2392, 2776, 3028, 3280, 3628, 4420, 4996, 5668, 6244, 7036, 8203, 9022, 9841, 10459, 10594, 11782, 12304, 13411, 13627, 14419
Offset: 1

Views

Author

Rémy Sigrist, Mar 30 2024

Keywords

Comments

This sequence is a variant of A334556 and A361818.
This sequence is infinite as it contains A003462.
Empirically, for any w > 0, there are A127975(w-1) terms with w balanced ternary digits (ignoring leading zeros).
If k is a term then A338246(k) is also a term.

Examples

			The balanced ternary expansion of 595 is "1T11001" (where T denotes -1), and the corresponding triangle T_595 is as follows:
           1
          T 0
         1 0 0
        1 1 T 1
       0 T 0 1 1
      0 0 1 T 0 T
     1 T 1 1 0 0 1
As this triangle has 3-fold rotational symmetry, 595 belongs to the sequence.
		

Crossrefs

Programs

  • PARI
    \\ See Links section.

A361827 For any number k >= 0, let T_k be the triangle whose base corresponds to the ternary expansion of k (without leading zeros) and other values, say t above u and v, satisfy t = (-u-v) mod 3; this sequence lists the numbers k such that the configurations of 0's, 1's and 2's in T_k are the same up to rotation.

Original entry on oeis.org

3, 5, 6, 7, 11, 15, 19, 21, 84, 93, 102, 140, 149, 158, 168, 177, 186, 196, 205, 214, 308, 318, 351, 377, 410, 420, 528, 532, 574, 588, 702, 715, 2271, 2396, 2523, 2621, 2775, 2873, 2933, 3150, 3185, 3375, 3410, 3627, 3687, 3785, 3939, 4037, 4164, 4289, 4519
Offset: 1

Views

Author

Rémy Sigrist, Mar 26 2023

Keywords

Comments

This sequence is a variant of A361818.
If k belongs to the sequence, then A004488(k) belongs to the sequence.
The ternary lengths of terms belong to A007494 (as the number of values in triangles must be divisible by 3).
This sequence is infinite as it contains the numbers whose ternary digits match the regular expression "(210)+".
Empirically, there are 4*3^floor((w-1)/2) terms with w ternary digits.
No term belongs to A297250.

Examples

			The ternary expansion of 149 is "12112", and the corresponding triangle is:
            0
           1 2
          0 2 2
         0 0 1 0
        1 2 1 1 2
The configurations of 0's, 1's and 2's are the same up to rotation, so 149 belongs to this sequence:
            0            .            .
           . .          1 .          . 2
          0 . .        . . .        . 2 2
         0 0 . 0      . . 1 .      . . . .
        . . . . .    1 . 1 1 .    . 2 . . 2
		

Crossrefs

Programs

  • PARI
    See Links section.
Showing 1-3 of 3 results.