Beispiel #1
0
    def test_radi(self):
        grid = gen_grid.Grids(h2o)
        grid.prune_scheme = None
        grid.atomic_radii = radi.becke_atomic_radii_adjust(h2o, \
                numpy.round(radi.COVALENT_RADII, 2))
        grid.radi_method = radi.mura_knowles
        coord, weight = grid.setup_grids()
        self.assertAlmostEqual(numpy.linalg.norm(weight), 1804.5437331817291, 9)

        grid.radi_method = radi.delley
        coord, weight = grid.setup_grids()
        self.assertAlmostEqual(numpy.linalg.norm(weight), 1686.3482864673697, 9)
Beispiel #2
0
    def test_gen_grid(self):
        grid = gen_grid.Grids(h2o)
        grid.prune_scheme = None
        grid.radi_method = radi.gauss_chebyshev
        grid.becke_scheme = gen_grid.original_becke
        grid.atomic_radii = radi.becke_atomic_radii_adjust(h2o, \
                numpy.round(radi.BRAGG_RADII, 2))
        coord, weight = grid.setup_grids()
        self.assertAlmostEqual(numpy.linalg.norm(coord), 185.91245945279027, 9)
        self.assertAlmostEqual(numpy.linalg.norm(weight), 1720.1317185648893, 9)

        grid.becke_scheme = gen_grid.stratmann
        coord, weight = grid.setup_grids()
        self.assertAlmostEqual(numpy.linalg.norm(weight), 1730.3692983091271, 9)