  We analyse numerically the linear stability of the fully developed flow of a
liquid metal in a rectangular duct subject to a transverse magnetic field. The
walls of the duct perpendicular to the magnetic field are perfectly conducting
whereas the parallel ones are insulating. In a sufficiently strong magnetic
field, the flow consists of two jets at the insulating walls and a
near-stagnant core. We use a vector stream function formulation and Chebyshev
collocation method to solve the eigenvalue problem for small-amplitude
perturbations. Due to the two-fold reflection symmetry of the base flow the
disturbances with four different parity combinations over the duct
cross-section decouple from each other. Magnetic field renders the flow in a
square duct linearly unstable at the Hartmann number Ha 5.7 with respect to a
disturbance whose vorticity component along the magnetic field is even across
the field and odd along it. For this mode, the minimum of the critical Reynolds
number Re_c 2018, based on the maximal velocity, is attained at Ha ~ 10.
Further increase of the magnetic field stabilises this mode with Re_c growing
approximately as Ha. For Ha>40, the spanwise parity of the most dangerous
disturbance reverses across the magnetic field. At Ha ~ 46 a new pair of most
dangerous disturbances appears with the parity along the magnetic field being
opposite to that of the previous two modes. The critical Reynolds number, which
is very close for both of these modes, attains a minimum Re_c ~ 1130 at Ha ~ 70
and increases as Re_c ~ Ha^1/2 for Ha >> 1. The asymptotics of the critical
wavenumber is k_c ~ 0.525Ha^1/2 while the critical phase velocity approaches
0.475 of the maximum jet velocity.
