Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

npt.lmp 2.1 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
  1. #############################
  2. ### Configure system type ###
  3. #############################
  4. units metal
  5. boundary p p p
  6. atom_style charge
  7. ################################
  8. ### Define system parameters ###
  9. ################################
  10. region myRegion block 0.0 32.65 0.0 32.65 0.0 32.65
  11. create_box 2 myRegion
  12. ##############################################################
  13. ### Read input file and assign types and elementary groups ###
  14. ##############################################################
  15. # We start from a xyz file
  16. read_dump {{ input_trajectory }} 0 x y z box no add yes format xyz
  17. set atom 1*500 type 1
  18. set atom 501*1000 type 2
  19. mass 1 22.989
  20. mass 2 35.453
  21. set atom 1*500 charge 1
  22. set atom 501*1000 charge -1
  23. group Na type 1
  24. group Cl type 2
  25. velocity all create {{ temperature }} 132465
  26. ########################################
  27. ### Define forcefield for simulation ###
  28. ########################################
  29. kspace_style pppm 1.0e-4
  30. # order: A, rho, sigma, C, D
  31. pair_style born/coul/long 10.0
  32. pair_style born/coul/long 10.0 8.
  33. pair_coeff 1 1 0.26370336 0.31699740062 2.340 1.048573120 0.49932058
  34. pair_coeff 1 2 0.21096269 0.31699740062 2.755 6.990487130 8.67580800
  35. pair_coeff 2 2 0.15822202 0.31699740062 3.170 72.40147522 145.42710039
  36. # ***************************************** #
  37. # *********** Run NPT Simulation ********** #
  38. # ***************************************** #
  39. timestep {{ timestep }}
  40. fix myBarostat all npt temp {{ temperature }} {{ temperature }} $(50*dt) iso {{ pressure }} {{ pressure }} $({{ barostat_factor }}*dt)
  41. # Compute the pressure.
  42. compute myTemp all temp
  43. # Set the dump file to dump every {{ dump_interval }} time steps.
  44. dump myDump1 all custom {{ dump_interval }} {{ dump_file }} id type element x y z
  45. dump_modify myDump1 element Na Cl
  46. dump_modify myDump1 sort id
  47. dump_modify myDump1 append yes
  48. log {{ log_file }} append
  49. # Define the output and run.
  50. thermo {{ thermo_intervall }}
  51. thermo_style custom step time temp density press
  52. run {{ steps }}
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...