Optimizing perturbation terms