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.

A375602 Triangle read by rows, where row n is a block of length n*(n^2 + 1)/2, which is a permutation of the numbers of its constituents; see Comments.

This page as a plain text file.
%I A375602 #10 Apr 26 2025 20:08:44
%S A375602 1,2,4,3,5,6,7,10,13,16,8,11,14,17,19,9,12,15,18,20,21,22,26,30,34,38,
%T A375602 42,46,23,27,31,35,39,43,47,50,24,28,32,36,40,44,48,51,53,25,29,33,37,
%U A375602 41,45,49,52,54,55
%N A375602 Triangle read by rows, where row n is a block of length n*(n^2 + 1)/2, which is a permutation of the numbers of its constituents; see Comments.
%C A375602 The sequence is an intra-block permutation of positive integers.
%C A375602 Generalization of the Cantor numbering method for n (n > 1) adjacent diagonals. In this approach, the block number n combines n neighboring diagonals.
%C A375602 Each block is filled sequentially, starting from the top of the leftmost vertical strip and moving downwards and then rightwards to the next strip. In block number n the first (n - 1)*n/2 + 1 strips each have a length of n. The remaining n - 1 strips have lengths that decrease sequentially from n - 1 down to 1. See Example the array of permutations of the triangle read upward antidiagonals.
%H A375602 Boris Putievskiy, <a href="/A375602/b375602.txt">Table of n, a(n) for n = 1..9316</a>
%H A375602 Boris Putievskiy, <a href="https://arxiv.org/abs/2310.18466">Integer Sequences: Irregular Arrays and Intra-Block Permutations</a>, arXiv:2310.18466 [math.CO], 2023.
%H A375602 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>.
%F A375602 Linear sequence:
%F A375602 a(n)  = P(n) + (L(n) - 1)*L*(L(n)^2 - L(n) + 2)/8, where L(n) =ceiling((sqrt(4*Sqrt(8*n + 1) - 3) - 1)/2), Ld(n) = ceiling((Sqrt(8*n + 1) - 1)/2), Ld(n) = A002024(n), Rd(n) = n - (Ld(n) - 1)*Ld(n)/2, Rd(n) = A002260(n),
%F A375602 P(n) =  L(n)*Rd(n) + Ld(n) - L(n)*(L(n) + 1)/2 - Max[Rd(n) - (L(n)^2 - L(n) + 2)/2, 0]*(Max[Rd(n) - (L(n)^2 - L(n) + 2)/2, 0] + 1)/2.
%F A375602 Triangular array T(n,k) for 1 <= k <= n(n^2+1)/2 (see Example):
%F A375602 T(n,k) = (n - 1)*n*(n^2 - n + 2)/8 + P(n,k), T(n,k) = A002817(n-1) + P(n,k), where P(n,k) = n*Rd(n,k) + Ld(n,k) - n - Max[Rd(n,k) - (n^2 - n + 2)/2, 0]*(Max[Rd(n,k) - (n^2 - n + 2)/2, 0] + 1)/2, where Ld(n,k) = Ceiling[(Sqrt[(n^2 - n + 1)^2 + 8*k] - (n^2 - n + 1))/2].
%e A375602 Triangle begins:
%e A375602      k = 1   2   3   4   5   6   7   8   9  10  11  12  13  14  15
%e A375602   n=1:   1;
%e A375602   n=2:   2,  4,  3,  5,  6;
%e A375602   n=3:   7, 10, 13, 16,  8, 11, 14, 17, 19,  9, 12, 15, 18, 20, 21;
%e A375602 Subtracting (n - 1)*n*(n^2-n+2)/8 from each term in row n is a permutation of 1 .. n(n^2+1)/2:
%e A375602   1,
%e A375602   1, 3, 2,  4, 5,
%e A375602   1, 4, 7, 10, 2, 5, 8, 11, 13, 3, 6, 9, 12, 14, 15,
%e A375602   ...
%e A375602 The triangle's rows of permutations can be arranged as n successive upward antidiagonals in an array:
%e A375602    1, 3, 5, 10, 13, 15, ...
%e A375602    1, 4, 7, 11, 14, ...
%e A375602    2, 4, 8, 12, ...
%e A375602    1, 5, 9, ...
%e A375602    2, 6, ...
%e A375602    3, ...
%t A375602 a[n_]:=Module[{L,Ld,Rd,P,Result},L=Ceiling[(Sqrt[4*Sqrt[8*n+1]-3]-1)/2];
%t A375602 Ld=Ceiling[(Sqrt[8*n+1]-1)/2]; Rd=n-(Ld-1)*Ld/2; P=L*Rd+Ld-L*(L+1)/2-Max[Rd-(L^2-L+2)/2,0]*(Max[Rd-(L^2-L+2)/2,0]+1)/2; Result=P+(L-1)*L*(L^2-L+2)/8; Result]
%t A375602 Nmax= 21; Table[a[n],{n,1,Nmax}]
%Y A375602 Cf. A002024, A002260, A002817, A006003 (row lengths),
%K A375602 nonn,tabf
%O A375602 1,2
%A A375602 _Boris Putievskiy_, Aug 20 2024