A new method of diagonalisation of the XY-Hamiltonian of inhomogeneous open
linear chains with periodic (in space) changing Larmor frequencies and coupling
constants is developed. As an example of application, multiple quantum dynamics
of an inhomogeneous chain consisting of 1001 spins is investigated. Intensities
of multiple quantum coherences are calculated for arbitrary inhomogeneous
chains in the approximation of the next nearest interactions.
{\it Key words:} linear spin chain, nearest--neighbour approximation,
three--diagonal matrices, diagonalisation, fermions, multiple--quantum NMR,
multiple--quantum coherence, intensities of multiple--quantum coherences.
{\it PACS numbers:} 05.30.-d; 76.20.+q