Application of Homotopy Perturbation Method to an SIR Epidemic Model