#Section 2############################ #Overlap Matrix S = Ints.getS(basisSet) #Follwing Two matrices compose the core Hamiltonian #KE Matrix KE = Ints.getT(basisSet) #External Potential, Nuclear - Electron Attraction Vext = Ints.getV(basisSet, molecule) #Form Hcore Hcore = KE + Vext #calculate two electron integrals elecRepulsion = Ints.get2ints(basisSet) #Section 3############################ #Calculate Transformation Matrix X from Overlap matrix X = linalg.SymOrth(S) #Section 4############################ #guess density matrix from Core Hamiltonian #diagnolize Hamiltonian and transform hamiltonian to get guess orbitals eVal, eVec = eigh(linalg.simx(Hcore, X)) #transform orbitals from AO to MO basis orbitals = matrixmultiply(Hcore, X) #guess Density from guess orbitals and number of closed electron shells