Esempio n. 1
0
elif(mpi.cpu_count() == 12):
	p = [3, 2, 2];
else:
	print "Unsupported number(" + str(mpi.cpu_count()) + ") of cpu cores, needs 8 or 12";
	exit();
#end

c = 8;

b = usc.sio2DensityToCellSize(2.196);
b = b;
c = np.array([c, c, c]);
s = b*c;

mdm = mdm();
mdm.compile();
mdm.setDir(path);
mdm.setProcessors(p);
mdm.setVolume(s);
mdm.setTemperature(4000);

mdm.makeCristobalite(c);

T = [4000, 3500, 3000, 2500, 2250, 2000, 1750, 1500, 1000, 500, 300];

for temp in T:
	print "T = ", temp, "K"
	mdm.setTemperature(temp);
	mdm.thermalize(therm, dt, 25*dt, 10, thermstep);
	mdm.makeVmdData();
	mdm.analyze(label = "%d_therm"%temp);
Esempio n. 2
0
elif(mpi.cpu_count() == 12):
	p = [3, 2, 2];
else:
	print "Unsupported number(" + str(mpi.cpu_count()) + ") of cpu cores, needs 8 or 12";
	exit();
#end

c = 10;

b = usc.h2oDensityToCellSize(1);
print b;
c = np.array([c, c, c]);
s = b*c;

mdm = mdm();
mdm.compile();
mdm.setDir(path);
mdm.setProcessors(p);
mdm.setVolume(s);
mdm.setTemperature(300);

mdm.makeWater(c);

mdm.thermalize(therm, dt, 25*dt, 10, thermstep);
mdm.simulate(stab, dt, stabstep);
mdm.noseHoover(sim, dt, 25*dt, step);

mdm.makeVmdData();
# mdm.visualize();
mdm.radialDistribution(1024, label = "amorph", states = range(0,stableStates));
mdm.angularDistribution(1024, label = "amorph", states = range(0,stableStates));
for i in range(0, len(dirs)):
	n = 0;
	for f in os.listdir(dirs[i]):
		if(f.endswith(".xyz") and f != "combined.xyz" and f != "sorted.xyz"):
			n += 1;
		#end
	#end
	if(n == nP):
		stableStates += 1;
	else:
		print str(i) + " is unstable";
		break;
	#end
#end

mdm.setDir(runName + "/analyzed");
mdm.loadSimulation(runName, stableStates);
print stableStates

# t = 25*np.arange(stableStates + 1, 25);
# mdm.numberOfSilanol(3259.46268694, t, states = range(0, stableStates + 1, 25));

# mdm.makeVmdData();

# L = 12*0.716;

# A = L*L;

# dt = 0.25*50;

# step = 25;