Optimal Rejuvenation Scheduling of Distributed Computation Based on Dynamic Programming