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: Boris Putievskiy

Boris Putievskiy's wiki page.

Boris Putievskiy has authored 106 sequences. Here are the ten most recent ones:

A383722 a(n) = A378762(A382679(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, May 07 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is a self-inverse permutation of the positive integers.
In particular, the initial {a(1), a(2), ..., a(A000384(n+1))} is self-inverse.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.

Examples

			Triangle array begins:
  k=    1   2   3   4   5  6   7   8   9
  n=1:  1;
  n=2:  5,  3,  6,  2,  4;
  n=3:  14, 8, 12, 10, 15, 9, 13, 7, 11;
(1, 5, 3, ..., 7, 11) = (1, 2, 3, ..., 12, 11) (1, 5, 3, ..., 7, 15). The first permutation on the right-hand side is from Example A378762 and the second from Example A382679.
(1, 5, 3, ..., 7, 11) = (1, 5, 3, ..., 7, 11)^(-1).
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  4, 10, 11, ...
   5,  2, 12,  7, 23, ...
   6,  8, 13, 19, 24, ...
  14,  9, 25, 18, 40, ...
  15, 17, 26, 32, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 5, 1, 3;
  8, 2, 6, 4, 9, 3, 7, 1, 5.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = 2m - 1 - k if k < m and k == 1 (mod 2), P(n, k) = k if k < m and k == 0 (mod 2), P(n, k) = 3m - 1 - k if k >= m and k == 1 (mod 2), P(n, k) = 2m - 1 - k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A383723 a(n) = A378762(A376214(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, May 07 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is a self-inverse permutation of the positive integers.
In particular, the initial {a(1), a(2), ..., a(A000384(n+1))} is self-inverse.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.

Examples

			Triangle array begins:
  k=    1  2  3   4   5   6   7   8   9
  n=1:  1;
  n=2:  2, 3, 6,  5,  4;
  n=3:  9, 8, 7, 10, 15, 12, 13, 14, 11;
(1, 2, 3, ..., 14, 11) = (1, 2, 3, ..., 12, 11) (1, 2, 3, ..., 12, 15). The first permutation on the right-hand side is from Example A378762 and the second from Example A376214.
(1, 2, 3, ..., 14, 11) = (1, 2, 3, ..., 14, 11)^(-1).
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  4, 10, 11, ...
   2,  5,  7, 14, 16, ...
   6,  8, 13, 19, 24, ...
   9, 12, 18, 25, 31, ...
  15, 17, 26, 32, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  1, 2, 5, 4, 3;
  3, 2, 1, 4, 9, 6, 7, 8, 5.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = m - 1 - k if k < m and k == 1 (mod 2), P(n, k) = k if k < m and k == 0 (mod 2), P(n, k) = 3m - 1 - k if k >= m and k == 1 (mod 2), P(n, k) = k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A383724 a(n) = A378762(A382680(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, May 07 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is a self-inverse permutation of the positive integers.
In particular, the initial {a(1), a(2), ..., a(A000384(n+1))} is self-inverse.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.

Examples

			Triangle array begins:
  k=     1  2   3   4   5  6   7  8   9
  n=1:   1;
  n=2:   5, 3,  6,  2,  4;
  n=3:  12, 8, 14, 10, 15, 7, 13, 9, 11;
(1, 5, 3, ..., 9, 11) = (1, 2, 3, ..., 12, 11) (1, 5, 3, ..., 9, 15). The first permutation on the right-hand side is from Example A378762 and the second from Example A382680.
(1, 5, 3, ..., 9, 11) = (1, 5, 3, ..., 9, 11)^(-1).
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  4, 10, 11, ...
   5,  2, 14,  9, 27, ...
   6,  8, 13, 19, 24, ...
  12,  7, 25, 18, 42, ...
  15, 17, 26, 32, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 5, 1, 3;
  6, 2, 8, 4, 9, 1, 7, 3, 5.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = m + k if k < m and k == 1 (mod 2), P(n, k) = k if k < m and k == 0 (mod 2), P(n, k) = 3m - 1 - k if k >= m and k == 1 (mod 2), P(n, k) = - m + k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A383590 a(n) = A378762(A382499(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, May 01 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.
A378762, A381968 and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the direct product of the dihedral group D4 and the cyclic group C2. The list of the 16 elements of that group: this sequence, A000027 (the identity permutation), A383419 (the inverse permutation), A381968, A381662, A382499, A380817, A382679, A376214, A382680, A378762, A383589, A056023, A383722, A383723, A383724. For subgroups and the Cayley table of the group D4xC2 see Boris Putievskiy link. - Boris Putievskiy, Jun 02 2025

Examples

			Triangle array begins:
  k=    1   2   3  4   5  6   7  8   9
  n=1:  1;
  n=2:  5,  3,  6, 2,  4;
  n=3: 14, 10, 12, 8, 15, 7, 13, 9, 11;
(1, 5, 3, ..., 9, 11) = (1, 2, 3, ..., 12, 11) (1, 5, 3, ..., 7, 15). The first permutation on the right-hand side is from Example A378762 and the second from Example A382499.
Ord(1, 5, 3, ... , 9, 11) = 4.
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  4,  8, 11, ...
   5,  2, 12,  9, 23, ...
   6, 10, 13, 19, 24, ...
  14,  7, 25, 18, 40, ...
  15, 21, 26, 34, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 5, 1, 3;
  8, 4, 6, 2, 9, 1, 7, 3, 5.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

ord(a(1), a(2), ..., a(A000384(n+1))) = 4, where ord is the order of the permutation.
T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = 2m - 1 - k if k < m and k == 1 (mod 2), P(n, k) = m + 1 - k if k < m and k == 0 (mod 2), P(n, k) = 3m - 1 - k if k >= m and k == 1 (mod 2), P(n, k) = - m + k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A383589 a(n) = A378762(A381662(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, May 01 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is a self-inverse permutation of the positive integers.
In particular, the initial {a(1), a(2), ..., a(A000384(n+1))} is self-inverse.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.

Examples

			Triangle array begins:
  k=    1   2  3  4   5   6   7   8   9
  n=1:  1;
  n=2:  2,  3, 6, 5,  4;
  n=3:  7, 10, 9, 8, 15, 12, 13, 14, 11;
(1, 2, 3, ..., 14, 11) = (1, 2, 3, ..., 12, 11) (1, 2, 3, ..., 12, 15). The first permutation on the right-hand side is from Example A378762 and the second from Example A381662.
(1, 2, 3, ..., 14, 11) = (1, 2, 3, ..., 14, 11)^(-1).
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  4,  8, 11, ...
   2,  5,  9, 14, 20, ...
   6, 10, 13, 19, 24, ...
   7, 12, 18, 25, 33, ...
  15, 21, 26, 34, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  1, 2, 5, 4, 3;
  1, 4, 3, 2, 9, 6, 7, 8, 5.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = k if k < m and k == 1 (mod 2), P(n, k) = m + 1 - k if k < m and k == 0 (mod 2), P(n, k) = 3m - 1 - k if k >= m and k == 1 (mod 2), P(n, k) = k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A383419 a(n) = A378762(A381968(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, May 01 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.
A378762, A381968 and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the direct product of the dihedral group D4 and the cyclic group C2. The list of the 16 elements of that group: this sequence, A000027 (the identity permutation), A383590 (the inverse permutation), A381968, A381662, A382499, A380817, A382679, A376214, A382680, A378762, A383589, A056023, A383722, A383723, A383724. For subgroups and the Cayley table of the group D4xC2 see Boris Putievskiy link. - Boris Putievskiy, Jun 02 2025

Examples

			Triangle array begins:
  k=    1   2   3  4   5  6   7  8   9
  n=1:  1;
  n=2:  5,  3,  6, 2,  4;
  n=3: 12, 10, 14, 8, 15, 9, 13, 7, 11;
(1, 5, 3, ..., 7, 11) = (1, 2, 3, ..., 12, 11) (1, 5, 3, ..., 9, 15). The first permutation on the right-hand side is from Example A378762 and the second from Example A381968.
Ord(1, 5, 3, ..., 7, 11) = 4.
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  4,  8, 11, ...
   5,  2, 14,  7, 27, ...
   6, 10, 13, 19, 24, ...
  12,  9, 25, 18, 42, ...
  15, 21, 26, 34, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 5, 1, 3;
  6, 4, 8, 2, 9, 3, 7, 1, 5.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

ord(a(1), a(2), ..., a(A000384(n+1))) = 4, where ord is the order of the permutation.
T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = m + k if k < m and k == 1 (mod 2), P(n, k) = m + 1 - k if k < m and k == 0 (mod 2), P(n, k) = 3m - 1 - k if k >= m and k == 1 (mod 2), P(n, k) = 2m - 1 - k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A382680 a(n) = A382499(A380817(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, Apr 03 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is a self-inverse permutation of the positive integers.
In particular, the initial {a(1), a(2), ..., a(A000384(n+1))} is self-inverse.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.
A381968 and and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the dihedral Group D4. The list of the 8 elements of that group: this sequence, A382679 (the inverse permutation), A000027 (the identity permutation), A381968, A381662, A382499, A380817, A376214. For subgroups and the Cayley table of the group D4 see Putievskiy (D4 (I)) link. - Boris Putievskiy, Apr 27 2025
A378762, A381968 and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the direct product of the dihedral group D4 and the cyclic group C2. The list of the 16 elements of that group: this sequence, A000027 (the identity permutation), A381968, A381662, A382499, A380817, A382679, A376214, A378762, A383419, A383589, A383590, A056023, A383722, A383723, A383724. For subgroups and the Cayley table of the group D4xC2 see Putievskiy link. - Boris Putievskiy, Jun 02 2025

Examples

			Triangle array begins:
  k=    1   2   3  4   5  6   7  8   9
  n=1:  1;
  n=2:  5,  3,  4, 2,  6;
  n=3: 12, 10, 14, 8, 11, 7, 13, 9, 15;
(1,5,3,...,9,15) = (1,5,3,...,9,15)^(-1).
(1,5,3,...,9,15) = (1,5,3,...,7,15) (1,2,3,...,10,7,...,14,15). The first permutation on the right-hand side is from Example A382499 and the second from Example A380817.
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
    1,  3,  6,  8, 15, ...
    5,  2, 14,  9, 27, ...
    4, 10, 13, 19, 26, ...
   12,  7, 25, 18, 42, ...
   11, 21, 24, 34, 41, ...
   ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1,
  4, 2, 3, 1, 5,
  6, 4, 8, 2, 5, 1, 7, 3, 9.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = m + k if k < m and k == 1 (mod 2), P(n, k) = m - k + 1 if k < m and k == 0 (mod 2), P(n, k) = k if k >= m and k == 1 (mod 2), P(n, k) = - m + k if k >= m and k == 0 (mod 2), where m = 2n - 1.

A382679 a(n) = A381968(A380817(n)).

Original entry on oeis.org

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

Author

Boris Putievskiy, Apr 03 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is a self-inverse permutation of the positive integers.
In particular, the initial {a(1), a(2), ..., a(A000384(n+1))} is self-inverse.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.
A381968 and and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the dihedral Group D4. The list of the 8 elements of that group: this sequence, A382680 (the inverse permutation), A000027 (the identity permutation), A381968, A381662, A382499, A380817, A376214. For subgroups and the Cayley table of the group D4 see Boris Putievskiy (2025 D4 (I)) link. - Boris Putievskiy, Apr 27 2025
A378762, A381968 and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the direct product of the dihedral group D4 and the cyclic group C2. The list of the 16 elements of that group: this sequence, A000027 (the identity permutation), A381968, A381662, A382499, A380817, A376214, A382680, A378762, A383419, A383589, A383590, A056023, A383722, A383723, 383724. For subgroups and the Cayley table of the group D4xC2 see Boris Putievskiy (2025 D4xC2) link. - Boris Putievskiy, May 27 2025

Examples

			Triangle array begins:
  k=    1   2   3  4   5  6   7  8   9
  n=1:  1;
  n=2:  5,  3,  4, 2,  6;
  n=3: 14, 10, 12, 8, 11, 9, 13, 7, 15;
(1,5,3,...,7,15) = (1,5,3,...,7,15)^(-1).
(1,5,3,...,7,15) = (1,5,3,...,9,15) (1,2,3,...,10,7,...,14,15).  The first permutation on the right-hand side is from Example A381968 and the second from Example A380817.
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  6,  8, 15, ...
   5,  2, 12,  7, 23, ...
   4, 10, 13, 19, 26, ...
  14,  9, 25, 18, 40, ...
  11, 21, 24, 34, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 3, 1, 5;
  8, 4, 6, 2, 5, 3, 7, 1, 9.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = 2m - 1 - k if k < m and k == 1 (mod 2), P(n, k) = m + 1 - k if k < m and k == 0 (mod 2), P(n, k) = k if k >= m and k == 1 (mod 2), P(n, k) = 2m - 1 - k if k >= m and k == 0 (mod 2),
where m = 2n - 1.

A382499 Inverse permutation to A381968.

Original entry on oeis.org

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

Author

Boris Putievskiy, Mar 29 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.
A381968 and and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the dihedral group D4. The list of the 8 elements of that group: this sequence, A381968 (the inverse permutation), A000027 (the identity permutation), A381662, A380817, A382679, A376214, A382680. For subgroups and the Cayley table of the group D4 see Boris Putievskiy (2025 D4 (I)) link. - Boris Putievskiy, Apr 17 2025
A378762, A381968 and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the direct product of the dihedral group D4 and the cyclic group C2. The list of the 16 elements of that group: this sequence, A000027 (the identity permutation), A381968 (the inverse permutation), A381662, A380817, A382679, A376214, A382680, A378762, A383419, A383589, A383590, A056023, A383722, A383723, A383724. For subgroups and the Cayley table of the group D4xC2 see Boris Putievskiy (2025 D4xC2) link. - Boris Putievskiy, May 27 2025

Examples

			Triangle array begins:
  k=     1  2   3   4   5  6   7  8   9
  n=1:   1;
  n=2:   5, 3,  4,  2,  6;
  n=3:  12, 8, 14, 10, 11, 9, 13, 7, 15;
(1,5,3,...,7,15)^(-1) = (1,5,3,...,9,15). The permutation on the right-hand side is from Example A381968.
ord(1,5,3,...,7,15) = 4.
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  6, 10, 15, ...
   5,  2, 14,  7, 27, ...
   4,  8, 13, 19, 26, ...
  12,  9, 25, 18, 42, ...
  11, 17, 24, 32, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 3, 1, 5;
  6, 2, 8, 4, 5, 3, 7, 1, 9.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

ord(a(1), a(2), ..., a(A000384(n+1))) = 4, where ord is the order of the permutation.
T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n, k) = k + m if k < m and k == 1 (mod 2), P(n, k) = k if k < m and k == 0 (mod 2), P(n, k) = k if k >= m and k == 1 (mod 2), P(n, k) = -k + 2m - 1 if k >= m and k == 0 (mod 2), where m = 2n - 1.

A381968 a(a(n)) = A381662(n).

Original entry on oeis.org

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

Author

Boris Putievskiy, Mar 12 2025

Keywords

Comments

This sequence can be regarded as a triangular array read by rows. Each row is a permutation of a block of consecutive numbers; the blocks are disjoint and every positive number belongs to some block. The length of row n is 4n-3 = A016813(n-1), n > 0.
The sequence can also be regarded as a table read by upward antidiagonals. For n > 1 row n joins two consecutive antidiagonals.
The sequence is an intra-block permutation of the positive integers.
Generalization of the Cantor numbering method.
This sequence and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the dihedral group D4. The list of the 8 elements of that group: this sequence, A382499 (the inverse permutation), A000027 (the identity permutation), A381662, A380817, A382679, A376214, A382680. For subgroups and the Cayley table of the group D4 see Putievskiy (D4 (I)) link. - Boris Putievskiy, Jun 09 2025
This sequence, A378762 and A380817 generate via composition a finite non-abelian group of permutations of positive integers, isomorphic to the direct product of the dihedral group D4 and the cyclic group C2. The list of the 16 elements of that group: this sequence, A000027 (the identity permutation), A382499 (the inverse permutation), A381662, A380817, A382679, A376214, A382680, A378762, A383419, A383589, A383590, A056023, A383722, A383723, A383724. For subgroups and the Cayley table of the group D4xC2 see Putievskiy link. - Boris Putievskiy, Jun 09 2025

Examples

			Triangle array begins:
  k=     1  2   3   4   5   6   7   8   9
  n=1:   1;
  n=2:   5, 3,  4,  2,  6;
  n=3:  14, 8, 12, 10, 11,  7, 13,  9, 15;
(1,5,3,...,9,15) (1,5,3,...,9,15) = (1,2,3,...,12,15). The permutation on the right-hand side is from Example A381662.
ord(1,5,3,...,9,15) = 4.
For n > 1, each row of triangle array joins two consecutive upward antidiagonals in the table:
   1,  3,  6, 10, 15, ...
   5,  2, 12,  9, 23, ...
   4,  8, 13, 19, 26, ...
  14,  7, 25, 18, 40, ...
  11, 17, 24, 32, 41, ...
  ...
Subtracting (n-1)*(2*n-3) from each term in row n produces a permutation of numbers from 1 to 4*n-3:
  1;
  4, 2, 3, 1, 5;
  8, 2, 6, 4, 5, 1, 7, 3, 9.
		

Programs

  • Mathematica
    T[n_,k_]:=(n-1)*(2*n-3)+Module[{m=2*n-1},If[k
    				

Formula

ord(a(1), a(2), ..., a(A000384(n+1))) = 4, where ord is the order of the permutation.
T(n,k) for 1 <= k <= 4n - 3: T(n,k) = A000384(n-1) + P(n,k), P(n,k) = - k + 2m - 1 if k < m and k == 1 (mod 2), P(n,k) = k if k < m and k == 0 (mod 2), P(n,k) = k if k >= m and k == 1 (mod 2), P(n,k) = k - m if k >= m and k == 0 (mod 2), where m = 2n - 1.