An optimality-based model of the dynamic feedbacks between natural vegetation and the water balance