Bethe lattice in inf dim density of states

def bethe_lattice(energy, hopping):
    """Bethe lattice in inf dim density of states"""
    energy = np.asarray(energy).clip(-2*hopping, 2*hopping)
    return np.sqrt(4*hopping**2 - energy**2) / (2*np.pi*hopping**2)