login
A057557
Lexicographic ordering of NxNxN, where N={1,2,3,...}.
9
1, 1, 1, 1, 1, 2, 1, 2, 1, 2, 1, 1, 1, 1, 3, 1, 2, 2, 1, 3, 1, 2, 1, 2, 2, 2, 1, 3, 1, 1, 1, 1, 4, 1, 2, 3, 1, 3, 2, 1, 4, 1, 2, 1, 3, 2, 2, 2, 2, 3, 1, 3, 1, 2, 3, 2, 1, 4, 1, 1, 1, 1, 5, 1, 2, 4, 1, 3, 3, 1, 4, 2, 1, 5, 1, 2, 1, 4, 2, 2, 3, 2, 3, 2, 2, 4, 1, 3, 1, 3, 3, 2, 2, 3, 3, 1, 4, 1, 2, 4, 2, 1, 5, 1, 1, 1, 1, 6, 1, 2, 5, 1, 3, 4, 1, 4, 3, 1, 5, 2, 1, 6, 1, 2, 1, 5, 2, 2, 4, 2, 3, 3, 2, 4, 2, 2, 5, 1, 3, 1, 4, 3, 2, 3, 3, 3, 2, 3, 4, 1, 4, 1, 3, 4, 2, 2, 4, 3, 1, 5, 1, 2, 5, 2, 1, 6, 1, 1
OFFSET
1,6
EXAMPLE
Flatten the list of ordered lattice points, (1,1,1) < (1,1,2) < (1,2,1) < ..., to 1,1,1, 1,1,2, 1,2,1, ...
MATHEMATICA
lexicographicLattice[{dim_, maxHeight_}]:= Flatten[Array[Sort@Flatten[(Permutations[#1]&)/@IntegerPartitions[#1+dim-1, {dim}], 1]&, maxHeight], 1]; Flatten@lexicographicLattice[{3, 6}]
(* By Peter J. C. Moses, Feb 10 2011 *)
CROSSREFS
A057555: ordering of N^2
A057559: ordering of N^4
A186006: ordering of N^5
A186003: distances to the plane x=0
A186004: distances to the plane y=0
A186005: distances to the plane z=0
Sequence in context: A330098 A189024 A304720 * A353364 A328390 A325599
KEYWORD
nonn
AUTHOR
Clark Kimberling, Sep 07 2000
EXTENSIONS
Corrected and extended by Clark Kimberling,, Feb 10 2011.
STATUS
approved