Optimized Maintenance Policies for Deteriorating Structures