A spectral analysis method using the optical potential as a wave absorber