A Link Availability Prediction Model for Wireless Ad Hoc Networks