login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A275078 Triangle read by rows in which row n lists the lexicographic composition of the elements of symmetric group S_n. 0
1, 2, 1, 2, 1, 3, 3, 4, 1, 2, 2, 4, 1, 5, 3, 5, 4, 2, 6, 1, 3, 4, 7, 5, 1, 3, 2, 6, 8, 1, 2, 3, 4, 7, 6, 5, 6, 9, 2, 1, 7, 8, 5, 4, 3, 2, 8, 9, 4, 6, 7, 10, 5, 1, 3, 5, 1, 6, 10, 8, 11, 9, 2, 7, 3, 4, 7, 1, 9, 5, 6, 2, 12, 4, 8, 11, 10, 3 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
EXAMPLE
Triangle begins:
1
2 1
2 1 3
3 4 1 2
2 4 1 5 3
5 4 2 6 1 3
4 7 5 1 3 2 6
8 1 2 3 4 7 6 5
6 9 2 1 7 8 5 4 3
2 8 9 4 6 7 10 5 1 3
5 1 6 10 8 11 9 2 7 3 4
7 1 9 5 6 2 12 4 8 11 10 3
For the third row, the 6 permutations of 123 in lexical order are 123, 132, 213, 231, 312, and 321. Consecutively applying each permutation to 123 results in the sequence: 123, 132, 312, 123, 312, 213. The final element with commas inserted gives us the row: 2,1,3.
PROG
(Python)
from itertools import count, permutations
for size in count(1):
row = tuple(range(1, size + 1))
for p in permutations(range(size)):
row = tuple(row[i] for i in p)
print(row)
CROSSREFS
Sequence in context: A318362 A213237 A029334 * A286478 A340756 A030273
KEYWORD
nonn,tabl
AUTHOR
David Nickerson, Jul 15 2016
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 09:22 EDT 2024. Contains 371905 sequences. (Running on oeis4.)