def test_overlap_spherical(): """Test gbasis.integrals.overlap.overlap_spherical.""" basis_dict = parse_nwchem(find_datafile("data_sto6g.nwchem")) basis = make_contractions(basis_dict, ["Kr"], np.array([[0, 0, 0]])) overlap_obj = Overlap(basis) assert np.allclose( overlap_obj.construct_array_spherical(), overlap_integral(basis, coord_type="spherical") )
def test_overlap_spherical_norm_sto6g(): """Test the norm of gbasis.integrals.overlap_spherical on the STO-6G basis set. The contraction coefficients in STO-6G is such that the spherical contractions are not normalized to past 3rd decimal places. """ basis_dict = parse_nwchem(find_datafile("data_sto6g.nwchem")) basis = make_contractions(basis_dict, ["Kr"], np.array([[0, 0, 0]])) overlap_obj = Overlap(basis) assert np.allclose(np.diag(overlap_obj.construct_array_spherical()), 1)