The asymptotic iteration method for the eigenenergies of the complex potential