A three field weak formulation for integration of the equations of motion of multibody systems subject to equality constraints