Latin rectangle

In combinatorial mathematics, a Latin rectangle is an $r &times; n$ matrix (where $r ≤ n$), using $n$ symbols, usually the numbers $1, 2, 3, ..., n$ or $0, 1, ..., n − 1$ as its entries, with no number occurring more than once in any row or column.

An $n &times; n$ Latin rectangle is called a Latin square. Latin rectangles and Latin squares may also be described as the optimal colorings of rook's graphs, or as optimal edge colorings of complete bipartite graphs.

An example of a 3 × 5 Latin rectangle is:


 * {| class="wikitable"


 * 0|| 1|| 2|| 3|| 4
 * 3|| 4 ||0 ||1|| 2
 * 4|| 0|| 3|| 2|| 1
 * }
 * 4|| 0|| 3|| 2|| 1
 * }
 * }

Normalization
A Latin rectangle is called normalized (or reduced) if its first row is in natural order and so is its first column.

The example above is not normalized.

Enumeration
Let $L$($k, n$) denote the number of normalized $k$ × $n$ Latin rectangles. Then the total number of $k$ × $n$ Latin rectangles is
 * $$\frac{n! (n-1)! L(k,n)}{(n-k)!}.$$

A 2 × $n$ Latin rectangle corresponds to a permutation with no fixed points. Such permutations have been called discordant permutations. An enumeration of permutations discordant with a given permutation is the famous problème des rencontres. The enumeration of permutations discordant with two permutations, one of which is a simple cyclic shift of the other, is known as the reduced problème des ménages.

The number of normalized Latin rectangles, $L(k, n)$, of small sizes is given by
 * {| class="wikitable" style="text-align:center;"

! k\n !!1!!2!!3!!4!!5!!6!!7!!8 ! 1 ! 2 ! 3 ! 4 ! 5 ! 6 ! 7 ! 8
 * 1||1||1||1||1||1||1||1
 * ||1||1||3||11||53||309||2119
 * || ||1||4||46||1064||35792||1673792
 * || || ||4||56||6552||1293216||420909504
 * || || || ||56||9408||11270400||27206658048
 * || || || || ||9408||16942080||335390189568
 * || || || || || ||16942080||535281401856
 * || || || || || || ||535281401856
 * }

When $k$ = 1, that is, there is only one row, since the Latin rectangles are normalized there is no choice for what this row can be. The table also shows that $L(n &minus; 1, n) = L(n, n)$, which follows since if only one row is missing, the missing entry in each column can be determined from the Latin square property and the rectangle can be uniquely extended to a Latin square.

Extendability
The property of being able to extend a Latin rectangle missing one row to a Latin square mentioned above, can be significantly strengthened. Namely, if $r < n$, then it is possible to append $n &minus; r$ rows to an $r &times; n$ Latin rectangle to form a Latin square, using Hall's marriage theorem.

Semi-Latin squares
A semi-Latin square is another type of incomplete Latin square. A semi-Latin square is an $n$ × $n$ array, $L$, in which some positions are unoccupied and other positions are occupied by one of the integers ${0, 1, ..., n − 1}$, such that, if an integer $k$ occurs in $L$, then it occurs $n$ times and no two $k$'s belong to the same row or column. If $m$ different integers occur in $L$, then $L$ has index $m$.

For example, a semi-Latin square of order 5 and index 3 is:
 * {| class="wikitable"


 * 1 ||  || 0 ||   || 2
 * || 2 || 1 ||  || 0
 * 0 || 1 ||  || 2 ||
 * 2 || 0 ||  || 1 ||
 * ||  || 2 || 0 || 1
 * }
 * 2 || 0 ||  || 1 ||
 * ||  || 2 || 0 || 1
 * }
 * ||  || 2 || 0 || 1
 * }

A semi-Latin square of order $n$ and index $m$ will have $nm$ filled positions. The question arises, can a semi-Latin square be completed to a Latin square? Somewhat surprisingly, the answer is always.

Let $L$ be a semi-Latin square of order $n$ and index $m$, where $m < n$. Then $L$ can be completed to a Latin square.

One way to prove this is to observe that a semi-Latin square of order $n$ and index $m$ is equivalent to an $m$ × $n$ Latin rectangle. Let $L = ||a_{ij}||$ be a Latin rectangle and $S = ||b_{ij}||$ be a semi-Latin square, then the equivalence is given by
 * $$b_{ij} = k \text{ if and only if  } a_{kj} = i.$$

For instance, the 3×5 Latin rectangle
 * {| class="wikitable"

is equivalent to this semi-Latin square of order 5 and index 3:
 * 0 || 1 || 2 || 3 || 4
 * 3 || 4 || 1 || 0 || 2
 * 1 || 0 || 4 || 2 || 3
 * }
 * 1 || 0 || 4 || 2 || 3
 * }
 * }
 * {| class="wikitable"

since, for example, $a$10 = 3 in the Latin rectangle so $b$30 = 1 in the semi-Latin square.
 * 0 || 2 || || 1 ||
 * 2 || 0 || 1 ||  ||
 * ||  || 0 || 2 || 1
 * 1 ||  ||   || 0 || 2
 * || 1 || 2 ||  || 0
 * }
 * 1 ||  ||   || 0 || 2
 * || 1 || 2 ||  || 0
 * }
 * || 1 || 2 ||  || 0
 * }

Applications
In statistics, Latin rectangles have applications in the design of experiments.