  Let G be a special orthogonal group or an inner form of a symplectic group
over a number field F such that there exists a non-empty set S of real places
of F at which G has discrete series and outside of which G is quasi-split. We
prove Arthur's multiplicity formula for automorphic representations of G having
algebraic regular infinitesimal character at all places in S.
