  For a system of N spins 1/2 there are quantum states that can encode a
direction in an intrinsic way. Information on this direction can later be
decoded by means of a quantum measurement. We present here the optimal encoding
and decoding procedure using the fidelity as a figure of merit. We compute the
maximal fidelity and prove that it is directly related to the largest zeroes of
the Legendre and Jacobi polynomials. We show that this maximal fidelity
approaches unity quadratically in 1/N. We also discuss this result in terms of
the dimension of the encoding Hilbert space.
