Exemplo n.º 1
0
 def test_cell_plus_imgs(self):
     numpy.random.seed(2)
     cl1 = pbcgto.M(a = numpy.random.random((3,3))*3,
                    mesh = [3]*3,
                    atom ='''He .1 .0 .0''',
                    basis = 'ccpvdz')
     cl2 = tools.cell_plus_imgs(cl1, cl1.nimgs)
     self.assertAlmostEqual(lib.finger(cl2.atom_coords()), 465.86333525744129, 9)
Exemplo n.º 2
0
 def test_cell_plus_imgs(self):
     numpy.random.seed(2)
     cl1 = pbcgto.M(a = numpy.random.random((3,3))*3,
                    gs = [1]*3,
                    atom ='''He .1 .0 .0''',
                    basis = 'ccpvdz')
     cl2 = tools.cell_plus_imgs(cl1, cl1.nimgs)
     self.assertAlmostEqual(finger(cl2.atom_coords()), 105.02255167975048, 9)
Exemplo n.º 3
0
 def test_cell_plus_imgs(self):
     numpy.random.seed(2)
     cl1 = pbcgto.M(a=numpy.random.random((3, 3)) * 3,
                    gs=[1] * 3,
                    atom='''He .1 .0 .0''',
                    basis='ccpvdz')
     cl2 = tools.cell_plus_imgs(cl1, cl1.nimgs)
     self.assertAlmostEqual(finger(cl2.atom_coords()), 22.233540464902909,
                            9)
Exemplo n.º 4
0
 def test_cell_plus_imgs(self):
     numpy.random.seed(2)
     cl1 = pbcgto.M(a = numpy.random.random((3,3))*3,
                    mesh = [3]*3,
                    atom ='''He .1 .0 .0''',
                    basis = 'ccpvdz')
     self.assertTrue(numpy.all(cl1.nimgs == numpy.array([8, 15, 11])))
     cl2 = tools.cell_plus_imgs(cl1, [3,4,5])
     self.assertAlmostEqual(lib.fp(cl2.atom_coords()), 4.791699273649499, 9)
     self.assertAlmostEqual(lib.fp(cl2._bas[:,gto.ATOM_OF]), -681.993543446207, 9)
Exemplo n.º 5
0
 def test_cell_plus_imgs(self):
     numpy.random.seed(2)
     cl1 = pbcgto.M(a=numpy.random.random((3, 3)) * 3,
                    mesh=[3] * 3,
                    atom='''He .1 .0 .0''',
                    basis='ccpvdz')
     self.assertTrue(numpy.all(cl1.nimgs == numpy.array([7, 14, 10])))
     cl2 = tools.cell_plus_imgs(cl1, [3, 4, 5])
     self.assertAlmostEqual(lib.finger(cl2.atom_coords()),
                            4.791699273649499, 9)