Smart Water Management in Agriculture: a Proposal for an Optimal Scheduling Formulation of a Gravity Water Distribution System