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!)
A186006 Lexicographic ordering of N x N x N x N x N, where N={1,2,3,...}. 3
1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 2, 2, 1, 1, 1, 3, 1, 1, 1, 2, 1, 2, 1, 1, 2, 2, 1, 1, 1, 3, 1, 1, 1, 2, 1, 1, 2, 1, 2, 1, 2, 1, 1, 2, 2, 1, 1, 1, 3, 1, 1, 1, 2, 1, 1, 1, 2, 2, 1, 1, 2, 1, 2, 1, 2, 1, 1, 2, 2, 1, 1, 1, 3, 1, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 2, 3, 1, 1, 1, 3, 2, 1, 1, 1, 4, 1, 1, 1, 2, 1, 3, 1, 1, 2, 2, 2, 1, 1, 2, 3, 1, 1, 1, 3, 1, 2, 1, 1, 3, 2, 1, 1, 1, 4, 1, 1, 1, 2, 1, 1, 3 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,10
COMMENTS
By changing a single number, the Mathematica code suffices for other dimensions: N x N (A057555), N x N x N (A057557), N x N x N x N (A057559), and higher.
LINKS
EXAMPLE
First, list the 5-tuples in lexicographic order: (1,1,1,1,1) < (1,1,1,1,2) < (1,1,1,2,1) < (1,1,2,1,1) < ... < (1,2,2,1,1) < (1,1,3,1,1) < ... Then flatten the list, leaving 1,1,1,1,1, 1,1,1,1,2, 1,1,1,2,1, 1,1,2,1,1, ...
MATHEMATICA
lexicographicLattice[{dim_, maxHeight_}]:= Flatten[Array[Sort@Flatten[(Permutations[#1]&)/@IntegerPartitions[#1+dim-1, {dim}], 1]&, maxHeight], 1];
lexicographicLatticeHeightArray[{dim_, maxHeight_, axis_}]:= Array[Flatten@Position[Map[#[[axis]]&, lexicographicLattice[{dim, maxHeight}]], #]&, maxHeight]
Take[Flatten@lexicographicLattice[{5, 12}], 160]
(* Peter J. C. Moses, Feb 10 2011 *)
CROSSREFS
Sequence in context: A081418 A088951 A361633 * A236398 A107453 A164115
KEYWORD
nonn
AUTHOR
Clark Kimberling, Feb 10 2011
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 25 08:27 EDT 2024. Contains 371964 sequences. (Running on oeis4.)