def windex(self, w, atol=0.001): """ Find the index of the **closest** frequency in ``wpoints``. """ if np.iscomplex(w): iw = bs_index(self.imag_wpoints.imag, w.imag, atol=atol) iw += self.nrew else: iw = bs_index(self.real_wpoints.real, w, atol=atol) return iw
def windex(self, w, atol=0.001): """ Find the index of the **closest** frequency in `wpts`. """ if np.iscomplex(w): iw = bs_index(self.imag_wpts.imag, w, atol=atol) iw += self.nrew else: iw = bs_index(self.real_wpts.real, w, atol=atol) return iw