Advertisement
shihab2196

Compare_Densities_Old_and_New_Simulations_Specific

Oct 22nd, 2024
34
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.16 KB | None | 0 0
  1. # -*- coding: utf-8 -*-
  2. """
  3. Author: Shihab Ahmed
  4. Created on Mon Oct 14 12:34:17 2024
  5. """
  6. import magnolia.log_parser_FHB as lfp
  7. import matplotlib.pyplot as plt
  8.  
  9. # mplt.custom_plot_features(minorticks=True)
  10. plt.style.use('default')
  11. plt.rcParams['font.size']=15
  12.  
  13. fig, ax = plt.subplots(dpi=350)
  14.  
  15. #---NPT1:600K,2atm(100ps)---NPT2:600->300K,2->1atm(50ps)---NPT3:300K,1atm(100ps)
  16. dirr=r"C:\Users\arup2\OneDrive - University of California Merced\Desktop\LAMMPS\borgstore\ARLOI\ARLOI-V1\8_ARLOI_Down_to_300K\A0001\Equilibration\Sim-2_48-cores"
  17. logfile = dirr+r'\log.lammps'
  18. thermo = lfp.thermo_panda(logfile, serial=[2,3,4], timestep=0.25, zero_ref='time')
  19. ax.plot(thermo['Time'],thermo['Density'], label='Eq$_{new}$')
  20.  
  21. #---NPT:300K,1atm(400ps)
  22. dirr=r"C:\Users\arup2\OneDrive - University of California Merced\Desktop\LAMMPS\borgstore\ARLOI\ARLOI-V1\4_ARLOI_24-09-07--22-34-03\20_PAO-OH_15_A0001\Equilibrate\Sim-1"
  23. logfile = dirr+r'\log.lammps'
  24. thermo = lfp.thermo_panda(logfile, serial=3, timestep=0.25, zero_ref='time')
  25. ax.plot(thermo['Time'],thermo['Density'], label='Eq$_{old}$')
  26.  
  27. ax.set_xlabel('Time (ps)')
  28. ax.set_ylabel('Density (g/cm$^3$)')
  29. plt.legend()
  30. plt.grid()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement