pot = GMINPotential(GMIN) coords = pot.getCoords() nrigid = coords.size / 6 print "I have %d water molecules in the system"%nrigid water = tip4p.water() #water.S = np.identity(3, dtype="float64") #water.S*=10. # define the whole water system system = RBSystem() system.add_sites([deepcopy(water) for i in xrange(nrigid)]) # this is an easy access wrapper for coordinates array ca = system.coords_adapter(coords) #buildingblocks.rotate(3.0, ca.rotRigid[-1:]) #ret = mylbfgs(coords, pot.getEnergyGradient, iprint=0) #coords2 = ret[0] #np.savetxt("coords1_2.txt", coords1) #np.savetxt("coords2_2.txt", coords2) coords1 = np.loadtxt("coords1.txt") coords2 = np.loadtxt("coords2.txt") print pot.getEnergy(coords1), pot.getEnergy(coords2) defaults.NEBquenchParams["nsteps"] = 200 defaults.NEBquenchParams["iprint"] = 1 defaults.NEBquenchParams["maxstep"] = 0.1 defaults.NEBquenchParams["maxErise"] = 0.1
pot = GMINPotential(GMIN) coords = pot.getCoords() nrigid = coords.size / 6 print "I have %d water molecules in the system" % nrigid water = tip4p.water() #water.S = np.identity(3, dtype="float64") #water.S*=10. # define the whole water system system = RBSystem() system.add_sites([deepcopy(water) for i in xrange(nrigid)]) # this is an easy access wrapper for coordinates array ca = system.coords_adapter(coords) #buildingblocks.rotate(3.0, ca.rotRigid[-1:]) #ret = mylbfgs(coords, pot.getEnergyGradient, iprint=0) #coords2 = ret[0] #np.savetxt("coords1_2.txt", coords1) #np.savetxt("coords2_2.txt", coords2) coords1 = np.loadtxt("coords1.txt") coords2 = np.loadtxt("coords2.txt") print pot.getEnergy(coords1), pot.getEnergy(coords2) NEBquenchParams = dict() NEBquenchParams["nsteps"] = 200 NEBquenchParams["iprint"] = 1 NEBquenchParams["maxstep"] = 0.1