Maximal constrained moments of inertia