Her departure was abrupt but hardly unforeseen as the latest senior official to leave the administration because of frustrations with the president, or his obvious disappointment.