lexicographic order
Let $A$ be a set equipped with a total order^{} $$, and let ${A}^{n}=A\times \mathrm{\cdots}\times A$ be the $n$fold Cartesian product^{} of $A$. Then the lexicographic order^{} $$ on ${A}^{n}$ is defined as follows:
If $a=({a}_{1},\mathrm{\dots},{a}_{n})\in {A}^{n}$ and $b=({b}_{1},\mathrm{\dots},{b}_{n})\in {A}^{n}$, then $$ if $$ or
${a}_{1}$  $=$  ${b}_{1},$  
$\mathrm{\vdots}$  
${a}_{k}$  $=$  ${b}_{k},$  
${a}_{k+1}$  $$  ${b}_{k+1}$ 
for some $k=1,\mathrm{\dots},n1$.
Examples

•
The lexicographic order yields a total order on the field of complex numbers.

•
The lexicographic order of words of finite length consisting of letters ${}^{\prime}\mathit{\hspace{1em}}{}^{\prime}$ (space) $$ is the dictionary order. To compare words of different length, one simply pads the shorter with ${}^{\prime}\mathit{\hspace{1em}}{}^{\prime}$s from the right. For example, $$.
Properties

•
The lexicographic order is a total order.

•
If the original set is wellordered, the lexicographic ordering on the product is also a wellordering.
Title  lexicographic order 

Canonical name  LexicographicOrder 
Date of creation  20130322 15:14:05 
Last modified on  20130322 15:14:05 
Owner  matte (1858) 
Last modified by  matte (1858) 
Numerical id  13 
Author  matte (1858) 
Entry type  Definition 
Classification  msc 06A99 
Defines  dictionary order 