Simultaneous force stabilization for rigid and flexible mechanisms under compliant contacts