def _bcs_gap(x):
        """Defines the self-consistent equation for the BCS state vector.

        Args:
            x: the superconducting gap
        """

        s = 0.0
        for i in range(n_site):
            s += 1.0 / np.sqrt(hop_erg[i] ** 2 + x**2)
        return 1 + s * u / (2 * n_site)
Defines the self-consistent equation for the BCS state vector.

        Args:
            x: the superconducting gap
        
examples/bcs_mean_field.py