Esempio n. 1
0
 def test_isordk_cooo(self):
     isordk = one.readisordk(self.aooneint)
     C = [0.0000000000, 0.0000000000, -0.8802560791]
     O = [0.0000000000, 0.0000000000, 1.0094700459]
     H1 = [0.0000000000, 1.8897261250, -2.7699822041]
     H2 = [0.0000000000, -1.8897261250, -2.7699822041]
     np.testing.assert_almost_equal(isordk["cooo"][0::500], C)
     np.testing.assert_almost_equal(isordk["cooo"][1::500], O)
     np.testing.assert_almost_equal(isordk["cooo"][2::500], H1)
     np.testing.assert_almost_equal(isordk["cooo"][3::500], H2)
Esempio n. 2
0
 def test_isordk_cooo(self):
     isordk = one.readisordk(self.aooneint)
     C = [-3.0015786160, -1.4563174382, 0.0550080378]
     O = [-3.1314330364, 0.8240509816, -0.0184248297]
     H1 = [-1.1728925345, -2.4468589606, 0.1025195320]
     H2 = [-4.7395143797, -2.6116033945, 0.0761219478]
     np.testing.assert_almost_equal(isordk["cooo"][0::120], C)
     np.testing.assert_almost_equal(isordk["cooo"][1::120], O)
     np.testing.assert_almost_equal(isordk["cooo"][2::120], H1)
     np.testing.assert_almost_equal(isordk["cooo"][3::120], H2)
Esempio n. 3
0
 def get_isordk(self):
     """
     Get overlap, nuclear charges and coordinates from AOONEINT
     """
     #
     # Data from the ISORDK section in AOONEINT
     #
     isordk = one.readisordk(filename=self.aooneint)
     #
     # Number of nuclei
     #
     N = isordk["nucdep"]
     #
     # MXCENT , Fix dimension defined in nuclei.h
     #
     mxcent = len(isordk["chrn"]) 
     #
     # Nuclear charges
     #
     self.Z = full.matrix((N,))
     self.Z[:] = isordk["chrn"][:N]
     #
     # Nuclear coordinates
     #
     R = full.matrix((mxcent*3,))
     R[:] = isordk["cooo"][:]
     self.R = R.reshape((mxcent, 3), order='F')[:N, :]
    #
    # Bond center matrix and half bond vector
    #
     noa = self.noa
     self.Rab = full.matrix((noa, noa, 3))
     self.dRab = full.matrix((noa, noa, 3))
     for a in range(noa):
         for b in range(noa):
             self.Rab[a, b, :] = (self.R[a, :] + self.R[b, :])/2
             self.dRab[a, b, :] = (self.R[a, :] - self.R[b, :])/2
Esempio n. 4
0
 def get_molecule_info(self):
     """
  `   Get overlap, nuclear charges and coordinates from AOONEINT
     """
     #
     # Data from the ISORDK section in AOONEINT
     #
     isordk = one.readisordk(filename=self.aooneint)
     #
     # Number of nuclei
     #
     N = isordk["nucdep"]
     #
     # MXCENT , Fix dimension defined in nuclei.h
     #
     mxcent = len(isordk["chrn"])
     #
     # Nuclear charges
     #
     self.Z = full.matrix((N, ))
     self.Z[:] = isordk["chrn"][:N]
     #
     # Nuclear coordinates
     #
     R = full.matrix((mxcent * 3, ))
     R[:] = isordk["cooo"][:]
     self.R = R.reshape((mxcent, 3), order="F")[:N, :]
     #
     # Bond center matrix and half bond vector
     #
     noa = self.noa
     self.Rab = full.matrix((noa, noa, 3))
     self.dRab = full.matrix((noa, noa, 3))
     for a in range(noa):
         for b in range(noa):
             self.Rab[a, b, :] = (self.R[a, :] + self.R[b, :]) / 2
             self.dRab[a, b, :] = (self.R[a, :] - self.R[b, :]) / 2
Esempio n. 5
0
 def test_isordk_chrn(self):
     isordk = one.readisordk(self.aooneint)
     assert isordk["chrn"][:3] == (6.0, 8.0, 1.0)
Esempio n. 6
0
 def test_isordk_nucdep(self):
     isordk = one.readisordk(self.aooneint)
     assert isordk["nucdep"] == 4