Skip to content

Commit

Permalink
improved electrolyte tutorial
Browse files Browse the repository at this point in the history
  • Loading branch information
simongravelle committed Nov 24, 2023
1 parent f4b119e commit 1d5bac6
Show file tree
Hide file tree
Showing 3 changed files with 108 additions and 86 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ angle_style harmonic
pair_style lj/cut/tip4p/long 1 2 1 1 0.1546 12.0
kspace_style pppm/tip4p 1.0e-4

# System definition
lattice fcc 4.04
region box block -4 4 -4 4 -13 13
create_box 5 box &
Expand All @@ -19,30 +18,23 @@ create_box 5 box &
extra/angle/per/atom 1 &
extra/special/per/atom 2

# create the walls
region rbotwall block -4 4 -4 4 -12 -10
region rtopwall block -4 4 -4 4 10 12
region rwall union 2 rbotwall rtopwall
create_atoms 5 region rwall

# create the fluid
region rliquid block -4 4 -4 4 -9 9
molecule h2omol ../TIP4P2005.txt
lattice sc 4.04
create_atoms 0 region rliquid mol h2omol 482793

# create the ions
create_atoms 3 random 10 52802 rliquid overlap 0.3 maxtry 500
create_atoms 4 random 10 90182 rliquid overlap 0.3 maxtry 500
set type 3 charge 1.0
set type 4 charge -1.0

stop

# settings
include ../PARM.lammps

# run
run 0

write_data system.data
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -969,6 +969,7 @@ Atoms # full
1636 119 2 0.5564 8.394477170306812 7.54961819821307 -32.80198083383997 0 0 0
1638 120 1 -1.1128 11.883267209474226 7.785724417045466 -32.21816463449936 0 0 0
1640 120 2 0.5564 12.765351040149566 7.9691516261697055 -31.891352588953286 0 0 0
4929 0 3 1 8.41908576262141 2.6144123780235695 -33.235115755160855 0 0 0
1283 1 2 0.5564 -15.479243700977465 15.814252738095156 -36.18814650941444 0 -1 0
1284 2 1 -1.1128 -12.180997837656868 15.775476820791258 -36.32215607112906 0 -1 0
1287 3 1 -1.1128 -8.10592619791106 15.805678225107165 -36.52369143715744 0 -1 0
Expand Down Expand Up @@ -1447,6 +1448,7 @@ Atoms # full
2046 256 1 -1.1128 11.774093259793796 12.044485023134671 -24.07369609190117 0 0 0
2047 256 2 0.5564 11.964527314567448 12.158189506309556 -25.006078374706025 0 0 0
2048 256 2 0.5564 12.621379425638759 12.157325470555776 -23.64022553339281 0 0 0
4935 0 3 1 13.233014488347347 13.354505653863075 -29.752819927350068 0 0 0
2049 257 1 -1.1128 -16.135983298847744 -16.03812716118043 -20.570919376312187 0 0 0
2054 258 2 0.5564 -12.590566670351507 -15.537454922326306 -20.140766858781998 0 0 0
2074 265 2 0.5564 -15.680544398622242 -12.378142916209802 -20.762130617933405 0 0 0
Expand Down Expand Up @@ -1783,7 +1785,7 @@ Atoms # full
2420 380 2 0.5564 -3.6755738881416855 12.77926711844302 -15.94771621461904 0 0 0
2421 381 1 -1.1128 -0.19457839982506203 11.809714857053116 -16.02261968522401 0 0 0
2423 381 2 0.5564 -0.05043448045000434 12.053647284203873 -16.938175822220284 0 0 0
4934 0 3 1 -0.23976473201055448 10.274149098635721 -18.306223266248693 0 0 0
4937 0 3 1 -0.23976473201055448 10.274149098635721 -18.306223266248693 0 0 0
4948 0 4 -1 -2.4184065577473532 12.400983940251628 -18.771561429431458 0 0 0
2064 262 1 -1.1128 3.6552833392202344 16.12095833298702 -20.258989945374733 0 -1 0
2065 262 2 0.5564 4.149174344975692 15.927026609770792 -19.460871707790698 0 -1 0
Expand Down Expand Up @@ -2110,7 +2112,7 @@ Atoms # full
2767 496 2 0.5564 12.668168742232387 4.413912067997334 -7.665021607857323 0 0 0
2768 496 2 0.5564 11.57253409406366 4.0297047845271745 -8.639177092141361 0 0 0
2769 497 1 -1.1128 15.810802057255842 8.0633761338406 -8.255486234095901 -1 0 0
4931 0 3 1 14.866923827522864 2.4687691767834004 -14.122003053204157 0 0 0
4933 0 3 1 14.866923827522864 2.4687691767834004 -14.122003053204157 0 0 0
2434 385 2 0.5564 -15.471625879144094 15.989351363868263 -11.789052295336203 0 -1 0
2436 386 1 -1.1128 -12.159780628694504 16.02042322135352 -11.756755180431515 0 -1 0
2438 386 2 0.5564 -12.28582796560544 15.551027675472888 -12.582771783693874 0 -1 0
Expand Down Expand Up @@ -2307,7 +2309,6 @@ Atoms # full
3086 602 2 0.5564 -12.442050053651933 -3.3431096371268874 -0.15209048319132068 0 0 0
3087 603 1 -1.1128 -8.19643283900268 -4.102033704322839 -0.3682474548856553 0 0 0
3110 610 2 0.5564 -12.569689411432483 -0.6377608142130904 -0.05953576319964196 0 0 0
4936 0 3 1 -12.971006120150447 -5.299861368546198 -1.9125476008805222 0 0 0
2683 468 2 0.5564 -3.949886478995917 -8.076149635540634 -7.302586983305671 0 0 0
2732 484 2 0.5564 -4.1231075170290215 -0.26546429831905427 -7.348477083796247 0 0 0
2874 532 1 -1.1128 -4.403190639478307 -8.06051787919063 -4.183958260840106 0 0 0
Expand All @@ -2325,7 +2326,6 @@ Atoms # full
3091 604 2 0.5564 -3.337021789290605 -4.295709271809977 -0.2300884049191282 0 0 0
3114 612 1 -1.1128 -4.267246390450198 -0.3183621898021524 -0.003945710548754049 0 0 0
3117 613 1 -1.1128 -0.17144910609769015 -0.35145428042254445 -0.009801392297757776 0 0 0
4938 0 3 1 -0.7733560873443981 -5.155759997310005 -6.611118275826385 0 0 0
2878 533 2 0.5564 0.455847067069672 -7.6878730734316 -4.54094530180849 0 0 0
2881 534 2 0.5564 4.609651236695367 -7.559635348659356 -3.9087583577267915 0 0 0
2885 535 2 0.5564 8.078129490971683 -7.613880349814205 -3.4113244852019067 0 0 0
Expand Down Expand Up @@ -2376,7 +2376,7 @@ Atoms # full
3112 611 2 0.5564 -8.094448529102932 0.0024997402826426873 -0.7824904228201653 0 0 0
3134 618 2 0.5564 -12.612292633202323 3.463815729524134 -0.19535500953627472 0 0 0
3137 619 2 0.5564 -8.61465086032112 4.0271608820793645 -0.5713908860044105 0 0 0
4929 0 3 1 -9.009109772690158 3.0920503965262576 -5.555217562241118 0 0 0
4930 0 3 1 -9.009109772690158 3.0920503965262576 -5.555217562241118 0 0 0
2752 491 2 0.5564 -7.727976381174211 3.6495583930128026 -7.500223324182448 0 0 0
2920 547 2 0.5564 -7.354848578536944 0.08194759945737773 -3.757252272523222 0 0 0
2924 548 2 0.5564 -4.52958612421079 0.5030024964882631 -4.38611825364582 0 0 0
Expand Down Expand Up @@ -2432,7 +2432,7 @@ Atoms # full
3127 616 2 0.5564 11.873524820523254 0.04221873409381033 -0.7416022079885022 0 0 0
3131 617 2 0.5564 16.001963802586207 4.431374451143391 -0.6590557861814113 -1 0 0
3151 624 2 0.5564 12.695184939774945 3.9437857978831135 -0.5219304387244572 0 0 0
4930 0 3 1 13.396050211096203 6.2958978939316665 -1.1792175534829568 0 0 0
4932 0 3 1 13.396050211096203 6.2958978939316665 -1.1792175534829568 0 0 0
2818 513 2 0.5564 -15.995029873630578 15.525942279012181 -4.46809103513317 0 -1 0
2821 514 2 0.5564 -11.691690696754122 15.983090255125656 -4.670682450541891 0 -1 0
2964 562 1 -1.1128 -12.167874058009234 8.465037520098374 -4.089650349306149 0 0 0
Expand Down Expand Up @@ -2720,7 +2720,6 @@ Atoms # full
3360 694 1 -1.1128 3.6748384156970966 7.957085995206641 3.972471196700583 0 0 0
3361 694 2 0.5564 4.49286977378188 7.5616656542469425 3.66751544393425 0 0 0
3363 695 1 -1.1128 7.846185702311417 7.766437652219096 4.044527996303261 0 0 0
4937 0 3 1 5.444273947255816 3.9922315284573635 2.509422261486492 0 0 0
4939 0 4 -1 1.7173302572766929 1.4096340493716468 2.608802525814994 0 0 0
3128 616 2 0.5564 12.63596710795434 0.17661145613693047 0.561329018553672 0 0 0
3130 617 2 0.5564 16.131031923326503 3.3892255021810507 0.4337737590292117 -1 0 0
Expand Down Expand Up @@ -3115,7 +3114,7 @@ Atoms # full
3758 826 2 0.5564 -11.928231142826021 11.36551505494625 12.200505298617081 0 0 0
3759 827 1 -1.1128 -8.30941851252899 11.932246691346842 11.864800439462023 0 0 0
3760 827 2 0.5564 -8.48508177717413 12.761531987068793 12.311968054292935 0 0 0
4932 0 3 1 -9.933365281453991 15.049714602758044 9.524989247492044 0 0 0
4934 0 3 1 -9.933365281453991 15.049714602758044 9.524989247492044 0 0 0
3402 708 1 -1.1128 -4.274682873772702 15.851858018425816 8.025379102448596 0 -1 0
3403 708 2 0.5564 -3.385246546978151 15.978465608553922 7.691606577066156 0 -1 0
3405 709 1 -1.1128 -0.18589849481044335 15.81765323425331 8.115375360210063 0 -1 0
Expand Down Expand Up @@ -3550,6 +3549,7 @@ Atoms # full
4153 958 2 0.5564 4.089793014786024 12.30916700589838 19.442211922726436 0 0 0
4154 958 2 0.5564 3.8640081391829275 11.612316321307627 20.769023793277157 0 0 0
4156 959 2 0.5564 7.720515651132769 11.883942766596258 19.546123669202444 0 0 0
4931 0 3 1 2.639302850477076 15.723007968162658 18.618572046951662 0 0 0
3778 833 2 0.5564 15.571914107880193 16.10338197132119 16.673279312673106 -1 -1 0
3797 839 2 0.5564 8.196628380902558 16.130992792409877 15.386656394171471 0 -1 0
3799 840 2 0.5564 11.344506213863921 16.071932287592624 16.217963231411467 0 -1 0
Expand Down Expand Up @@ -3988,7 +3988,7 @@ Atoms # full
4788 1170 1 -1.1128 -12.007233662454013 -8.243497881982536 36.69699135033957 0 0 0
4790 1170 2 0.5564 -12.778749207194707 -8.457549714410625 36.17023797753818 0 0 0
4791 1171 1 -1.1128 -8.369521278400091 -8.314866552995657 36.241568137152555 0 0 0
4933 0 3 1 -14.633119543377832 -15.960165551211762 30.369556763809896 0 0 0
4936 0 3 1 -14.633119543377832 -15.960165551211762 30.369556763809896 0 0 0
4556 1092 2 0.5564 -3.795365492148161 -15.528384959192916 31.927928159906436 0 0 0
4557 1093 1 -1.1128 -0.32802671995260047 -16.00860984364211 32.17003178318367 0 0 0
4576 1099 2 0.5564 -7.619208885518404 -12.694039949176048 32.58581188096993 0 0 0
Expand Down Expand Up @@ -4224,7 +4224,7 @@ Atoms # full
4894 1205 2 0.5564 0.2696505924307807 7.434330803301269 36.00942031300124 0 0 0
4896 1206 1 -1.1128 3.8412915669631196 7.752842473896192 36.279415347282104 0 0 0
4897 1206 2 0.5564 4.7574884028203694 7.94784422715695 36.07671301826146 0 0 0
4935 0 3 1 2.5002507369687095 5.714136233084901 33.22725628025236 0 0 0
4938 0 3 1 2.5002507369687095 5.714136233084901 33.22725628025236 0 0 0
4643 1121 2 0.5564 16.083703717671042 0.7333464155544195 32.582461124923796 -1 0 0
4660 1127 2 0.5564 8.728718722320302 0.16931815712744003 32.723734630020864 0 0 0
4663 1128 2 0.5564 11.522101188151513 0.4075298449939623 32.02176736139489 0 0 0
Expand Down Expand Up @@ -5920,6 +5920,7 @@ Velocities
1636 0 0 0
1638 0 0 0
1640 0 0 0
4929 0 0 0
1283 0 0 0
1284 0 0 0
1287 0 0 0
Expand Down Expand Up @@ -6398,6 +6399,7 @@ Velocities
2046 0 0 0
2047 0 0 0
2048 0 0 0
4935 0 0 0
2049 0 0 0
2054 0 0 0
2074 0 0 0
Expand Down Expand Up @@ -6734,7 +6736,7 @@ Velocities
2420 0 0 0
2421 0 0 0
2423 0 0 0
4934 0 0 0
4937 0 0 0
4948 0 0 0
2064 0 0 0
2065 0 0 0
Expand Down Expand Up @@ -7061,7 +7063,7 @@ Velocities
2767 0 0 0
2768 0 0 0
2769 0 0 0
4931 0 0 0
4933 0 0 0
2434 0 0 0
2436 0 0 0
2438 0 0 0
Expand Down Expand Up @@ -7258,7 +7260,6 @@ Velocities
3086 0 0 0
3087 0 0 0
3110 0 0 0
4936 0 0 0
2683 0 0 0
2732 0 0 0
2874 0 0 0
Expand All @@ -7276,7 +7277,6 @@ Velocities
3091 0 0 0
3114 0 0 0
3117 0 0 0
4938 0 0 0
2878 0 0 0
2881 0 0 0
2885 0 0 0
Expand Down Expand Up @@ -7327,7 +7327,7 @@ Velocities
3112 0 0 0
3134 0 0 0
3137 0 0 0
4929 0 0 0
4930 0 0 0
2752 0 0 0
2920 0 0 0
2924 0 0 0
Expand Down Expand Up @@ -7383,7 +7383,7 @@ Velocities
3127 0 0 0
3131 0 0 0
3151 0 0 0
4930 0 0 0
4932 0 0 0
2818 0 0 0
2821 0 0 0
2964 0 0 0
Expand Down Expand Up @@ -7671,7 +7671,6 @@ Velocities
3360 0 0 0
3361 0 0 0
3363 0 0 0
4937 0 0 0
4939 0 0 0
3128 0 0 0
3130 0 0 0
Expand Down Expand Up @@ -8066,7 +8065,7 @@ Velocities
3758 0 0 0
3759 0 0 0
3760 0 0 0
4932 0 0 0
4934 0 0 0
3402 0 0 0
3403 0 0 0
3405 0 0 0
Expand Down Expand Up @@ -8501,6 +8500,7 @@ Velocities
4153 0 0 0
4154 0 0 0
4156 0 0 0
4931 0 0 0
3778 0 0 0
3797 0 0 0
3799 0 0 0
Expand Down Expand Up @@ -8939,7 +8939,7 @@ Velocities
4788 0 0 0
4790 0 0 0
4791 0 0 0
4933 0 0 0
4936 0 0 0
4556 0 0 0
4557 0 0 0
4576 0 0 0
Expand Down Expand Up @@ -9175,7 +9175,7 @@ Velocities
4894 0 0 0
4896 0 0 0
4897 0 0 0
4935 0 0 0
4938 0 0 0
4643 0 0 0
4660 0 0 0
4663 0 0 0
Expand Down
Loading

0 comments on commit 1d5bac6

Please sign in to comment.