Compare commits

...

1016 Commits

Author SHA1 Message Date
a83489e511 whitespace 2025-04-30 16:14:32 -04:00
79ccd302c2 Merge branch 'develop' into rigid-shear 2025-04-30 16:14:04 -04:00
64b23c90a6 port ghost atom velocity bugfix to KOKKOS 2025-04-30 16:02:30 -04:00
d00f376453 update gitignore 2025-04-30 08:32:28 -06:00
d556bfe0c4 Langevin corrections for rigid bodies in shear 2025-04-30 08:14:57 -06:00
440e24c60e Merge pull request #4559 from lammps/gcmc-eatom
Added atomic energy option for energy change calculation in fix sgcmc
2025-04-28 22:26:15 -04:00
c886fff624 Merge branch 'develop' into gcmc-eatom 2025-04-28 17:55:48 -06:00
2c27ea3706 Fix spelling in comment
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-26 13:32:21 -04:00
40d8e1b95f Merge pull request #4535 from Bibobu/plot_forces_tool
Adding python tool to plot tabulated forces
2025-04-26 00:50:32 -04:00
4b2163666c Merge pull request #4545 from jtclemm/rheo
Small patches to various packages
2025-04-26 00:46:49 -04:00
f577dcb28b Merge pull request #4570 from akohlmey/collected-small-changes
More small changes to recover builds of "develop"
2025-04-25 16:30:16 -04:00
d416202b71 restore missing blank 2025-04-25 16:16:15 -04:00
46f4f5a3c0 move JSON class back to try recover legacy builds 2025-04-25 16:11:11 -04:00
9b258d4c82 try another variant 2025-04-25 15:51:39 -04:00
1597019419 another small tweak 2025-04-25 15:44:52 -04:00
c8b841b08e small tweak 2025-04-25 15:31:32 -04:00
3b9ddf7a1f spelling 2025-04-25 14:59:42 -04:00
cab78b2c0d correct docs related to adding explicit Coulomb interactions 2025-04-25 14:15:01 -04:00
734bc915e2 must include third_party folder with legacy build 2025-04-25 14:14:20 -04:00
3c5e85a7c0 Merge pull request #4550 from akohlmey/collected-small-fixes
Collected small changes and fixes
2025-04-25 13:46:59 -04:00
9e26d8b569 Missing derivative for RK0 2025-04-25 10:19:28 -06:00
43fcf6eccc use ioffset variable. 2025-04-25 11:44:03 -04:00
d25d0cbc7e Merge pull request #4562 from mateors6/lj/pirani
Add pair style lj/pirani
2025-04-25 11:27:58 -04:00
83e5146ec9 add velocity remapping of rigid body VCM 2025-04-24 17:04:29 -06:00
8e07d48518 GitHub has stopped support for subversion in 2024. Remove note from 2016. 2025-04-24 18:42:19 -04:00
f7a2833829 indexing bug fix for ghost comm of remapped velocities across PBC when group all is not used 2025-04-24 13:20:00 -06:00
d4ba5d1fe6 Fixing bug in minimum density 2025-04-24 10:53:17 -06:00
a1fc036e25 Fix typo in src/timer.cpp
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-24 07:53:05 -04:00
20d3d47fe3 Update pair_lj_pirani.rst 2025-04-24 09:18:41 +02:00
2d70947044 two more workarounds for compilation with -DFMT_STATIC_THOUSANDS_SEPARATOR 2025-04-23 21:00:40 -04:00
4126c9ed75 implement workaround for compilers that require -DFMT_STATIC_THOUSANDS_SEPARATOR 2025-04-23 14:20:10 -04:00
2e8b95f0c1 Update pair_lj_pirani.rst
Documentation update
2025-04-23 19:34:06 +02:00
f9dc879033 add comment to indicate that setting the pointer to null has no effect in sfree.
You need Memory::destroy() but that can't be applied to all use cases.
2025-04-23 08:41:56 -04:00
b1159dc528 fix up to Copilot suggested code change 2025-04-23 05:58:10 -04:00
1352257cf4 Use modern C++ code pattern to build c-style argument list
This was suggested by GitHub Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-23 05:51:53 -04:00
6629ecff2d implement function to add request for single occasional neighbor list 2025-04-22 21:44:45 -04:00
9e9caf7d14 dummy implementation of single neighbor list build 2025-04-22 16:02:51 -04:00
290ca2a095 Update pair_lj_pirani.rst
Corrections
2025-04-22 21:13:22 +02:00
73fe2f7915 Update extract(), document, and test 2025-04-22 11:28:17 -04:00
d10e5dded2 Add OPENMP package version of pair style lj/pirani 2025-04-22 11:27:41 -04:00
bbc025632d apply clang-format 2025-04-22 10:50:24 -04:00
dbe98e2cfb update embedded JSON class to version 3.12.0 2025-04-22 10:37:29 -04:00
25307b049c Update and rename mol-pair-lj_improved_cut.yaml to mol-pair-lj_pirani.yaml
New name
2025-04-22 14:55:38 +02:00
da903e6d44 Update and rename pair_lj_improved_cut.h to pair_lj_pirani.h
New name
2025-04-22 14:53:15 +02:00
f9ba8caf4a Update and rename pair_lj_improved_cut.cpp to pair_lj_pirani.cpp
New name
2025-04-22 14:51:27 +02:00
7221e3993a Update .gitignore
New name
2025-04-22 14:48:11 +02:00
0673ac6acf Update pair_style.rst
New name
2025-04-22 14:47:24 +02:00
fcc4092e83 Update and rename pair_lj_improved_cut.rst to pair_lj_pirani.rst
New name
2025-04-22 14:45:52 +02:00
26ab7cd20d Update Commands_pair.rst
New name
2025-04-22 14:44:05 +02:00
385f350918 Removed debug code from unrelated files in MANYBODY and MC 2025-04-21 15:50:14 -06:00
04732e2efd Removed debug code from unrelated files in MANYBODY and MC 2025-04-21 10:08:27 -06:00
7bfc15ff2c Address akohlmey comments 2025-04-21 10:06:50 -06:00
d5c4f9c158 Fixed whitespace 2025-04-20 11:01:38 -06:00
0ff17967b0 Merge branch 'fix_omp_detection' of github.com:rbberger/lammps into collected-small-fixes 2025-04-20 10:37:04 -04:00
4e69046e54 cmake: fix omp.h detection
CMAKE_REQUIRED_LINK_OPTIONS needs to be a ;-separated list.
See https://cmake.org/cmake/help/latest/module/CheckIncludeFileCXX.html.
Fixes OpenMP detection with AppleClang when libomp is manually provided.
2025-04-20 00:40:24 -06:00
75d620c0a7 Fixed doc page 2025-04-19 18:21:39 -06:00
fc0a41fb71 Added atomic/energy keyword, EAM support, correct for examples/MC/in.sgcmc.eam in serial 2025-04-19 18:15:43 -06:00
6988c2f13e Typo in rheo doc 2025-04-19 10:55:19 -06:00
c088ce2f51 fix typo 2025-04-19 11:05:52 -04:00
699e5bee07 Merge branch 'fix_cmake_list' of github.com:alinelena/lammps into collected-small-fixes 2025-04-19 11:02:45 -04:00
bd427ecf7a do not make CMAKE_CXX_FLAGS a list of springs, ends up adding ; to the flags breaking compilation 2025-04-19 08:57:54 +01:00
8adc2d3391 Update pair_lj_improved_cut.cpp
Corrected energy calculation for r-RESPA
2025-04-18 13:48:10 +02:00
95a0c0a69a add another small optimization 2025-04-18 07:31:39 -04:00
f385633f97 Update pair_lj_improved_cut.cpp 2025-04-18 12:32:57 +02:00
a59a2e4dba address multiple issues with formatting, references, non-ASCII characters, spelling 2025-04-18 00:48:28 -04:00
0895b77a93 replace slow pow(x,2.0) with square(x) and cache repeatedly used pow() calls 2025-04-18 00:36:24 -04:00
71da769b11 add force style test 2025-04-18 00:35:01 -04:00
9a08f7b23b add test for indented output 2025-04-17 16:26:03 -04:00
bd34c5f315 Update .gitignore 2025-04-17 22:14:38 +02:00
18dca0eeb1 Update pair_lj_improved_cut.rst 2025-04-17 21:58:50 +02:00
942e77d976 Update and rename pair_ilj_cut.rst to pair_lj_improved_cut.rst 2025-04-17 21:57:18 +02:00
25fd039457 Add files via upload 2025-04-17 21:52:52 +02:00
96f7dc79cc Delete src/EXTRA-PAIR/pair_ilj_cut.h 2025-04-17 21:51:48 +02:00
8ef9759856 Delete src/EXTRA-PAIR/pair_ilj_cut.cpp 2025-04-17 21:51:33 +02:00
e1e87cc9ef Fixing indexing error in fix rheo arg parsing 2025-04-17 13:49:36 -06:00
e7a8cc6646 Update .gitignore 2025-04-17 21:29:30 +02:00
80361d0bd6 Merge branch 'lammps:develop' into lj/improved/cut 2025-04-17 21:25:20 +02:00
7806244713 Update pair_style.rst 2025-04-17 21:09:43 +02:00
e15e7f699e Update Commands_pair.rst 2025-04-17 21:05:58 +02:00
6e2d7f48d7 alternate approach to include header from thirdparty dir 2025-04-17 14:10:03 -04:00
51aa87d4ce Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-04-17 13:58:14 -04:00
7ca493917a Merge pull request #4542 from akohlmey/add-json-lib
Integrate header-only JSON library
2025-04-17 13:56:16 -04:00
5938dee2d9 Delete doc/pair_ilj_cut.html 2025-04-17 18:44:31 +02:00
854e9c7a19 Merge branch 'develop' into ILJ/CUT 2025-04-17 18:31:59 +02:00
a7760e82e1 Merge pull request #4536 from akohlmey/remove-cmake-tune-flags
Remove CMAKE_TUNE_FLAGS
2025-04-17 11:02:04 -04:00
0f80a5c93d Add files via upload 2025-04-17 14:06:57 +02:00
82bb366126 Delete doc/pair_ilj_cut.rst 2025-04-17 14:06:14 +02:00
ab75943e39 Add files via upload 2025-04-17 14:02:32 +02:00
ae19abdd7a Add files via upload 2025-04-17 14:01:14 +02:00
27d8e103eb move json.hpp class to thirdparty folder and add wrapper for use with LAMMPS 2025-04-16 15:54:59 -04:00
a9fe42bea4 fix bug reported in issue #4551 2025-04-16 06:21:11 -04:00
4553108035 add minimal unit test for JSON class 2025-04-15 22:11:44 -04:00
c4c76dd96c catch JSON library exceptions 2025-04-15 21:31:03 -04:00
b131659a43 modify include guard and namespace to avoid clashes with the original version 2025-04-15 21:31:03 -04:00
d2d7248e3a import original version 3.11.3 files 2025-04-15 21:31:03 -04:00
689b542da6 make minimize work with KOKKOS package without -suffix or suffix command 2025-04-14 10:59:54 -04:00
b081d289c1 Merge pull request #4546 from akohlmey/lammps-gui-enhancements
LAMMPS-GUI enhancements
2025-04-14 10:49:54 -04:00
0b0383bc64 Merge pull request #4548 from jrgissing/bond/react-create+rate_limit_bugfix
bond/react: refactor reaction counting
2025-04-14 09:38:10 -04:00
7be6e95647 Rephrasing suggested by @simongravelle 2025-04-14 06:28:29 -04:00
31df721767 update documentation 2025-04-13 20:01:06 -04:00
0bab80a26e not much use for editing x axis label. better give more space to other options 2025-04-13 19:33:07 -04:00
f181ca6aec support setting graph colors in preferences 2025-04-13 16:56:21 -04:00
1eb61936ab refactor reaction counting
previously, the rate_limit keyword did not work when also creating atoms
2025-04-13 12:56:01 -04:00
00673999af Merge remote-tracking branch 'github/develop' into lammps-gui-enhancements 2025-04-13 05:41:26 -04:00
994b7b4937 Merge pull request #4540 from evoyiatzis/fix-adapt-dihedral
extend fix adapt to treat dihedrals
2025-04-13 05:39:58 -04:00
bb09088731 add new tab to preferences for charts window settings 2025-04-12 11:49:41 -04:00
1ad2df84d8 add checkbox to automatically open tutorial website, if available 2025-04-12 06:49:44 -04:00
d0c3564216 update TODO list 2025-04-12 00:53:45 -04:00
2dd53c440e Add mini ToC for HowTo only and reorganize the introduction 2025-04-12 00:47:35 -04:00
ed1f4cc381 add functionality to edit the plot title and x- and y-axis labels 2025-04-11 23:25:56 -04:00
3aa3d45a9f Merge pull request #4532 from akohlmey/collected-small-fixes
Collected small fixes and changes
2025-04-11 21:02:02 -04:00
2ca9e188c0 Prevent BPM bonds breaking during setup 2025-04-11 12:53:51 -06:00
b8e14cd0c9 correct and rephrase one more time 2025-04-11 14:04:33 -04:00
3810be6c8b correct / clarify embedded docs 2025-04-11 14:04:27 -04:00
7a40e78c7a Merge conflict 2025-04-11 11:21:56 -06:00
e79171c1de Merge branch 'develop' into rheo 2025-04-11 11:18:53 -06:00
f786707699 Cleaning up granular restitution example 2025-04-11 11:14:34 -06:00
02c627db82 Merge branch 'collected-small-fixes' of github.com:akohlmey/lammps into collected-small-fixes 2025-04-11 12:34:45 -04:00
190ecd2666 clarify 2025-04-11 12:34:31 -04:00
a5b83224e4 rephrase to be less ambiguous and provide a couple more details 2025-04-11 12:29:03 -04:00
90797c7b62 document that also molecules from the molecule command can be visualized 2025-04-10 11:51:13 -04:00
83c785740b improve phrasing 2025-04-10 10:49:27 -04:00
dfc10e5b59 small improvements of molecule visualization. 2025-04-10 08:56:57 -04:00
bc031bdd7a initial attempt to allow viewing molecules. 2025-04-10 08:23:04 -04:00
f2bf0d0a8b add optional create_atoms group keyword to add new atoms to a custom group 2025-04-10 05:36:26 -04:00
980bf70310 improve error messages 2025-04-10 05:00:41 -04:00
227b4ed12d remove unused class members and plug memory leaks 2025-04-10 04:39:56 -04:00
32592e6660 add feature idea for LAMMPS-GUI 2025-04-10 01:13:44 -04:00
2f861b83d7 correct embedded documentation 2025-04-10 00:01:40 -04:00
d1f452fcb6 fix whitespace issues 2025-04-09 17:45:54 -04:00
6e7cbbeb9c add errorurl(36) message to all "boost neigh_modify one" errors 2025-04-09 17:35:42 -04:00
e9695df0e8 Provide some additional explanations for the "boost neigh_modify one" error 2025-04-09 17:29:34 -04:00
8fd1bf23c9 only compute special neighbors of a template if it has bonds 2025-04-09 16:41:46 -04:00
f16f65c8dc add missing entries 2025-04-09 10:45:51 -04:00
813e65026e fixing whitespaces 2025-04-08 15:53:45 +02:00
a237bdc753 Merge remote-tracking branch 'github/develop' into remove-cmake-tune-flags 2025-04-07 22:50:50 -04:00
af718e8162 remove one more use to CMAKE_TUNE_FLAGS 2025-04-07 22:50:38 -04:00
c9f25a69e5 remove rarely working hack 2025-04-07 22:48:44 -04:00
b6dae216d3 no need to set build type specific flags 2025-04-07 22:48:18 -04:00
3d13227287 convert compiler workaround from augmenting compiler flags to target_compile_definition() 2025-04-07 22:17:08 -04:00
647bc7538d programming style fix 2025-04-07 21:46:09 -04:00
fc3d295560 add missing entry to OpenMP reduction clause. 2025-04-07 21:29:53 -04:00
dcb04032fb avoid memory leak on element names 2025-04-07 18:18:16 -04:00
99b484a0cc add Kokkos/OpenMP version of mliap unified test 2025-04-07 18:06:31 -04:00
c505bfbdfe make sure OpenMP has a sufficient number of threads allocated 2025-04-07 18:06:07 -04:00
8ea6c5c395 avoid memory leak for element names 2025-04-07 18:05:35 -04:00
6c337ba655 manage cutghost array for KOKKOS, if requested by pair style command 2025-04-07 18:00:56 -04:00
52ce35adbc make sure cutghost is initialized 2025-04-07 17:59:45 -04:00
bfd496bee7 plug memory leaks in pyx files 2025-04-07 17:59:12 -04:00
9a06ac9585 Merge branch 'develop' into fix-adapt-dihedral 2025-04-07 23:15:52 +02:00
499192a1b2 restore option to request neighbor lists with neighbors of ghosts 2025-04-07 16:27:16 -04:00
809d5b5b93 Fix typo in dihedral_charmm.cpp 2025-04-07 21:08:35 +02:00
7b0c5f3e04 Fix typo indihedral_charmmfsw.cpp 2025-04-07 21:07:52 +02:00
d012d13c19 fix typo in dihedral_quadratic.cpp 2025-04-07 20:52:55 +02:00
fe9915f307 disable support for neighbors of ghosts. see also bff980b56f 2025-04-07 14:37:35 -04:00
fdbae98345 Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-04-07 14:05:27 -04:00
6372178caa Merge pull request #4538 from bathmatt/mliap-coefs-bug
Fixed invalid ref of coeffs in pair style mliap/kk
2025-04-07 13:58:55 -04:00
4ce473a649 Merge branch 'lammps:develop' into fix-adapt-dihedral 2025-04-07 19:54:18 +02:00
ef875b5973 fixed whitespace 2025-04-07 14:16:49 +02:00
239eb64cbb modifications in fix adapt.cpp 2025-04-07 11:58:24 +02:00
2b38b6d1c0 extract() implementation for dihedral class2 2025-04-07 11:35:20 +02:00
e93709d34e extract() implementation for dihedral helix 2025-04-07 11:20:53 +02:00
7655a4cb84 extract() implementation for dihedral multi/harmonic 2025-04-07 09:30:44 +02:00
e956e5ccda extract() implementation for dihedral charmm and charmmfsw 2025-04-07 09:24:44 +02:00
55964c1233 extract() implementation for dihedral cosine squared restricted 2025-04-07 09:11:42 +02:00
27ac8c0ea1 extract() implementation for dihedral opls 2025-04-07 09:05:42 +02:00
477f78b28c Fixed invalid ref 2025-04-07 08:42:57 +02:00
7034e930fd update date 2025-04-06 15:03:39 -04:00
6267389801 must force OMP_NUM_THREADS=1 for all tests to pass 2025-04-06 11:30:41 -04:00
911b3eb811 cleanup format 2025-04-06 11:16:58 -04:00
2a1fb835ad must not allocate eatom and vatom when called from KOKKOS version (which sets copymode to 1) 2025-04-06 10:33:05 -04:00
d4bcd3b7eb plug memory leak in SO3 descriptor for pair style mliap/kk 2025-04-06 10:25:56 -04:00
cf3ffb9dfc simplify fingerprint to match more suppression cases 2025-04-06 10:25:31 -04:00
c6d2812d2d Revert "match documentation to return 0 when checking for size of columns on 1d arrays"
This reverts commit 6272acd9c6.
Which isn't needed
2025-04-06 07:51:52 -04:00
ac76176dd5 must set lj cutoff to avoid uninitialized data access 2025-04-06 07:29:35 -04:00
cdea2737c7 remove CMAKE_TUNE_FLAGS 2025-04-06 07:06:20 -04:00
da2bc03ae6 do explicit loop over nlocal to avoid out-of-bounds access with implicit loop 2025-04-06 06:21:39 -04:00
6272acd9c6 match documentation to return 0 when checking for size of columns on 1d arrays 2025-04-06 06:19:34 -04:00
6ab7d7d818 Made plot_forces executable 2025-04-06 10:37:54 +02:00
ece0df7f7e Small modification of Tools.rst to include plot_forces + typo 2025-04-06 10:37:23 +02:00
94e6022210 Changed --recompute option of plot_forces to -d for consistency 2025-04-06 10:34:28 +02:00
b357540e92 Added plot_forces description to README.md 2025-04-06 10:33:30 +02:00
f8757abe92 Moved plot_forces to the tools/tabulate/ folder 2025-04-06 10:31:29 +02:00
2eaf1e52f0 add even more suppressions and generalize some 2025-04-06 03:49:11 -04:00
860a3cbbd3 add suppressions for dlopen() and friends 2025-04-06 03:02:34 -04:00
8d5459393f Added the plot_forces file from previous PR 2025-04-05 23:32:36 +02:00
2939e7d509 Merge branch 'develop' of github.com:lammps/lammps into plot_forces_tool 2025-04-05 23:28:52 +02:00
0cc6fb8e18 fix acks2/reaxff/kk should use post_constructor() like base class for order of operations 2025-04-05 16:36:20 -04:00
3fc0868db9 enable and apply clang-format 2025-04-05 15:48:10 -04:00
0bfa5b210b plug memory leak 2025-04-05 15:42:04 -04:00
25f1dac9b6 more suppressions for MPICH and Kokkos 2025-04-05 01:42:44 -04:00
7c2ca8c8e5 must not call plain ev_init() from KOKKOS without setting alloc to 0 to avoid memory leak 2025-04-05 01:42:18 -04:00
c60bff2b97 reformat source 2025-04-05 00:53:28 -04:00
e0847f2195 fix memory leak in test 2025-04-05 00:26:20 -04:00
b9228a854e no need to call allocate() of the base class 2025-04-04 17:17:40 -04:00
be6acff029 must not allocate eatom and vatom in base class to avoid big memory leak 2025-04-04 17:17:08 -04:00
bff980b56f cutghost is not used anyware; remove to plug memory leaks 2025-04-04 17:15:56 -04:00
a970f946a7 some more MPICH suppressions 2025-04-04 12:05:58 -04:00
0c71daabbe Merge pull request #4530 from akohlmey/collected-small-fixes
Collected small fixes and changes.
2025-04-04 12:04:46 -04:00
d1dd05bf4e update unit test for quadratic dihedral 2025-04-04 17:19:54 +02:00
996faf7a94 update documentation 2025-04-04 17:11:30 +02:00
3182dc26da extract() implementation for dihedral quadratic 2025-04-04 17:06:29 +02:00
0879548737 change fix adapt header file 2025-04-04 17:03:58 +02:00
54d7f46151 modifications in dihedral & dihedral_hybrid 2025-04-04 17:00:52 +02:00
ccd6eeb8af unit test 2025-04-04 16:53:57 +02:00
5086c639e2 improve docs and use dtype as parameter name to avoid confusion with type 2025-04-04 10:41:35 -04:00
f4f0a22ee1 improve valgind suppression information and format 2025-04-04 10:19:38 -04:00
66fbc40944 add valgrind suppression for Kokkos 2025-04-04 10:09:33 -04:00
af31dd3a6b update suppressions so they work with both the library interface and the standalone executable 2025-04-04 09:16:23 -04:00
5d32a1e61a don't mix malloc() and delete 2025-04-04 06:53:12 -04:00
50f42f203d make consistent, remove ghost member map 2025-04-04 06:52:02 -04:00
e3016072ad Merge branch 'develop' of github.com:lammps/lammps into develop 2025-04-04 10:22:41 +02:00
d06bfbf180 add missing index 2025-04-04 03:41:22 -04:00
a3de234873 update valgrind suppressions for Fedora 41 2025-04-04 03:40:25 -04:00
fdf5f8dd22 avoid division by zero 2025-04-04 03:39:56 -04:00
cadac64ab6 plug memory leak detected by coverity scan 2025-04-04 03:39:39 -04:00
9d61ff4bba add support for compiling fully static LAMMPS executable with libcurl 2025-04-04 00:45:19 -04:00
daf58e72dc update for recent changes 2025-04-03 22:45:37 -04:00
91283d98cc allow to set https_proxy via preferences if not set via environment variable 2025-04-03 22:27:57 -04:00
1892189eaa looking for libcurl components fails for some installations 2025-04-03 18:46:16 -04:00
f447a0476c discuss using a proxy with geturl, e.g. on a cluster compute node 2025-04-03 18:45:14 -04:00
65992f7ba2 mention LAMMPS tutorial files download support 2025-04-03 18:44:40 -04:00
999e6d95d4 list post_constructor methods and modernize description 2025-04-03 13:47:53 -04:00
609b60c211 set LAMMPS-GUI version 2025-04-03 08:56:05 -04:00
216b9218cb flag development version 2025-04-03 08:52:54 -04:00
75e12e2004 add missing overrides 2025-04-02 17:11:17 -04:00
7b4c33630d Merge pull request #4524 from akohlmey/next_release
Step version strings for next feature release
2025-04-02 16:04:25 -04:00
0a7f55688b Merge pull request #4463 from bathmatt/lammps-kokkos-mliap-comms
Added code which provides callbacks from external ML-IAP functions to…
2025-04-02 14:28:24 -04:00
91e4cbb564 update a couple more pending version tags 2025-04-02 14:20:57 -04:00
0043bca33d Merge branch 'develop' into next_release 2025-04-02 14:11:45 -04:00
9cfcb971b9 whitespace 2025-04-02 12:04:18 -06:00
cb8550465e Merge pull request #4507 from navlalli/qeqr
Add fix qeq/rel/reaxff
2025-04-02 13:19:55 -04:00
8df9f3404b Merge pull request #4467 from evoyiatzis/patch-2
extend fix adapt to treat improper angles
2025-04-02 12:18:40 -04:00
92321f4cad Merge pull request #4521 from stanmoore1/kk_update_4.6.0
Update Kokkos library in LAMMPS to v4.6.0
2025-04-02 11:30:17 -04:00
9f7653dd37 Merge pull request #4519 from fxcoudert/extxyz2
Add extended XYZ dump style extxyz
2025-04-02 10:59:18 -04:00
38df714672 Merge branch 'develop' into lammps-kokkos-mliap-comms 2025-04-02 08:32:44 +02:00
8defe0e798 Merge pull request #4482 from rbberger/dihedral_multi_harmonic_kokkos
add dihedral multi/harmonic/kk
2025-04-01 21:37:51 -04:00
d51017c878 Set pending version tags to 2Apr2025 2025-04-01 21:30:53 -04:00
5bd3218372 update version strings 2025-04-01 21:29:59 -04:00
5933eca83f Merge pull request #4515 from akohlmey/collected-small-fixes
Collected small fixes and updates
2025-04-01 21:16:16 -04:00
5371aa8670 Merge pull request #4335 from jrgissing/bond/react-molmap_option
Bond/react: molmap option
2025-04-01 21:14:19 -04:00
144637c0a1 Merge pull request #4523 from evoyiatzis/patch-7
enable lj96/cut, lj/cubic and lj/gromacs with fix adapt
2025-04-01 21:12:09 -04:00
618c92aeee fix typos 2025-04-01 19:25:48 -04:00
b0ca9ed0d4 enable lj/cubic for fix adapt 2025-04-01 16:19:37 +02:00
76e3900128 add line in the end of pair_lj_gromacs.cpp 2025-04-01 15:38:50 +02:00
db8dae3300 enable lj/gromacs for fix adapt 2025-04-01 15:36:44 +02:00
fd77c935ab Precompute terms in overlap integral 2025-04-01 12:47:55 +01:00
c99ae613de enable lj96 for fix adapt 2025-04-01 11:34:11 +02:00
6964156b6f fix syntax error 2025-04-01 00:00:22 -04:00
e577528099 switch CWD to home if default is "/" or contains "AppData" 2025-03-31 23:47:45 -04:00
bba860f959 Update docs for KOKKOS update 2025-03-31 12:36:40 -06:00
a4f7c7e4c5 Update CMake for KOKKOS package 2025-03-31 12:29:08 -06:00
3b69cf6011 Merge branch 'develop' of github.com:lammps/lammps into kk_update_4.6.0 2025-03-31 11:46:30 -06:00
084ba674a5 Remove atomics units and distance function 2025-03-31 17:44:17 +01:00
9d2b5302b9 modernize some error messages 2025-03-31 01:28:25 -04:00
1c609ef3e4 cosmetic, more LAMMPS style 2025-03-30 23:37:11 -04:00
677e8dd681 documentation fixes 2025-03-30 23:35:45 -04:00
6e395424bc better align with LAMMPS' programming conventions 2025-03-30 23:30:15 -04:00
935e323d08 Merge branch 'develop' into bond/react-molmap_option 2025-03-30 23:27:50 -04:00
578b1cf936 fix typo
Co-authored-by: Shern Tee <shernren@gmail.com>
2025-03-30 01:32:02 -04:00
2da463a773 missed renames 2025-03-29 18:55:13 -04:00
367dd4635b Merge remote-tracking branch 'github/develop' into qeqr 2025-03-29 18:41:36 -04:00
fc9d7bc181 rename fix qeqr/reaxff to fix qeq/rel/reaxff 2025-03-29 18:40:47 -04:00
2396668965 Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-29 16:31:17 -04:00
285baf27b5 Merge pull request #4518 from akohlmey/file-formats
Add a general description of common file formats in LAMMPS
2025-03-29 16:30:31 -04:00
7ff9ee51e5 small tweaks 2025-03-29 15:56:34 -04:00
990007c87b whitespace, rewrap, and comments 2025-03-28 23:55:38 -04:00
4dbf18e2c9 small suggested changes 2025-03-28 23:15:33 -04:00
1172a8c6c8 Merge pull request #4506 from fxcoudert/mac
Update macOS info
2025-03-28 18:50:45 -04:00
aeed7a425f we only need to worry about Python3 now 2025-03-28 18:25:42 -04:00
b7b9a4a599 Update Kokkos library in LAMMPS to v4.6.0 2025-03-28 15:29:14 -06:00
9661c21052 comment out possible additional sections 2025-03-28 09:56:06 -04:00
c0321b5f00 More doc 2025-03-28 10:58:54 +01:00
9a55856758 forgot handling addstep_compute in setup() 2025-03-28 00:32:28 -04:00
09242c0b12 forgot handling addstep_compute in setup() 2025-03-28 00:31:01 -04:00
a17ec2a8d3 fix bug with addstep_compute skipping on first step 2025-03-28 00:18:32 -04:00
0263774595 must use addstep_compute() on next time based or variable step dump output 2025-03-28 00:17:59 -04:00
9ac09e839f trigger computes only if next variable step or time based dump present 2025-03-28 00:05:14 -04:00
963083b2d5 must use addstep_compute() on next variable dump output 2025-03-27 23:50:37 -04:00
8949a6262d Use "Contact the LAMMPS developers" consistently and add an errorurl() to such errors 2025-03-27 19:04:32 -04:00
c3309bc0b3 error message and programming style updates 2025-03-27 18:35:40 -04:00
c9be07df9c fix bug with addstep_compute skipping on first step 2025-03-27 18:28:06 -04:00
fc78806bc7 apply clang-format 2025-03-27 17:14:35 -04:00
f652687a3a add support for outputting the same temperature, pressure, and potential energy as the thermo output 2025-03-27 17:14:06 -04:00
738fb4a502 add info about restart files 2025-03-27 16:29:13 -04:00
d12f4b076b Dump pe, temp, press 2025-03-27 21:05:38 +01:00
032c1c39b0 Handle mass better 2025-03-27 20:14:29 +01:00
fce3246439 detect misformatted Sphinx directives 2025-03-27 13:37:13 -04:00
c9d557a9f2 add test for version related tags missing a colon 2025-03-27 13:20:08 -04:00
8eceb2b944 small updates and clarifications 2025-03-27 12:52:48 -04:00
dcb844b01b Safer printf 2025-03-27 17:27:08 +01:00
0c7c21925f Update .github/CODEOWNERS
Co-authored-by: Axel Kohlmeyer <akohlmey@gmail.com>
2025-03-27 16:55:35 +01:00
b0a8391413 Update CODEOWNERS 2025-03-27 16:23:58 +01:00
bb6470eb1a More flexibility: forces, vel, mass 2025-03-27 15:59:42 +01:00
855737cf04 implement derived extxyz dump style 2025-03-27 14:38:33 +01:00
2ad0cc1820 document extxyz dump style 2025-03-27 14:38:08 +01:00
f5dbf30965 improve error messages 2025-03-27 14:37:27 +01:00
f0b3b20653 add a write permission check before opening a pipe for compressed writes 2025-03-26 23:09:39 -04:00
dd313465e1 add support for writing one file per timestep with '*' wildcard 2025-03-26 22:44:35 -04:00
9661d020c1 Merge branch 'develop' into collected-small-fixes 2025-03-26 20:10:20 -04:00
c45558b640 some tweaks for local table of contents 2025-03-26 20:09:54 -04:00
2542b989ee small tweak 2025-03-26 19:59:52 -04:00
7f0b71f7c0 spelling 2025-03-26 17:36:27 -04:00
637b572600 Merge remote-tracking branch 'github/develop' into file-formats 2025-03-26 17:33:00 -04:00
465171d58f Merge pull request #4514 from akohlmey/library-handle-argument-errors
Improve handling argument errors with library interface functions
2025-03-26 14:35:30 -04:00
dcbc3c9dbc whitespace 2025-03-26 09:52:19 -04:00
194b3408f7 add section about molecule files 2025-03-26 09:51:09 -04:00
bc1b22a2f8 finish (for now) the summary of the data file format 2025-03-26 09:01:07 -04:00
8a373ab5d8 spelling 2025-03-26 09:00:25 -04:00
cf5d74b315 add pair style pedone to list of pair styles compatible with fix adapt 2025-03-26 05:54:21 -04:00
d515af2e2b Merge branch 'develop' into library-handle-argument-errors 2025-03-26 05:13:10 -04:00
811f79abc6 error out or ignore on displacements in z-direction with 2d system 2025-03-26 04:57:01 -04:00
c22716f5c0 error out on non-existing groups and improve error messages 2025-03-26 04:45:13 -04:00
a9f2bdf326 remove misplaced excess error call 2025-03-26 04:17:36 -04:00
c95d43f647 plug memory leaks 2025-03-26 04:16:54 -04:00
24389a55dc remove argument expansion since it would take only the first expanded argument only.
this is better made explicit.
2025-03-26 04:11:51 -04:00
16f836bef5 Merge branch 'develop' into lammps-kokkos-mliap-comms 2025-03-26 07:21:53 +01:00
d658c589f7 update formulations some more 2025-03-25 21:47:04 -04:00
a98a743f2e Fix tabs->spaces in last commit 2025-03-25 15:13:11 -07:00
bc791da69e Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-25 17:53:23 -04:00
faa6e806bf Merge remote-tracking branch 'github/develop' into file-formats 2025-03-25 17:53:02 -04:00
7878ec170c Merge pull request #4501 from lammps/errors-more-cleanup
[Community Project] More Error and Warning Messages Cleanup
2025-03-25 17:52:08 -04:00
3c055fe93b Clean up cupy vs. torch in exchanges 2025-03-25 15:39:20 -06:00
bb788cb1a2 Merge remote-tracking branch 'github/develop' into file-formats 2025-03-25 17:36:55 -04:00
0b43649e74 Merge pull request #4513 from akohlmey/howto-bulk-to-slab
Add a Howto showing how to convert a bulk system to a slab
2025-03-25 16:54:38 -04:00
227b7840e7 add disclaimer and improve some formulations 2025-03-25 15:42:11 -04:00
2d0c1af656 Merge remote-tracking branch 'github/develop' into howto-bulk-to-slab 2025-03-25 15:40:55 -04:00
fecd93783b spelling 2025-03-25 15:40:40 -04:00
d850d93dad Make Pytorch optional 2025-03-25 13:01:56 -06:00
678e90f669 make spellchecker happy 2025-03-25 14:55:30 -04:00
bafd2a8d6b Merge remote-tracking branch 'github/develop' into file-formats 2025-03-25 14:22:55 -04:00
2ea5cf1206 Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-25 14:16:04 -04:00
9e241df062 Merge pull request #4182 from akohlmey/group-bitmap-accessor
Refactor code to use group bitmap accessor
2025-03-25 14:12:27 -04:00
32e4a0d36b Merge branch 'develop' into lammps-kokkos-mliap-comms 2025-03-25 18:44:52 +01:00
5dbeacb1e8 Merge pull request #4508 from jewettaij/master
Fixed the Moltemplate HowTo docs
2025-03-25 13:02:31 -04:00
bdf1b541b1 Merge branch 'mac' of https://github.com/fxcoudert/lammps into collected-small-fixes 2025-03-25 11:38:54 -04:00
66d5fbd4bd Merge pull request #4516 from Eddy-Barraud/dpd_charged
wrong qi*qj in the cuda code
2025-03-25 11:28:21 -04:00
183486d813 implement suggestions from @ndtrung81 2025-03-25 11:27:19 -04:00
e9ac9e77db add option to return an entire column, row, or array as flat array with lammps_extract_fix() 2025-03-25 11:20:15 -04:00
3efddff01a Changed use of varient on LHS 2025-03-25 09:59:41 +01:00
3872fa16d4 small update to internal command documentation 2025-03-25 04:37:15 -04:00
7fba02f865 fix logic bug when writing coeffs to data file 2025-03-25 03:02:17 -04:00
5a62d0a129 correct data in data file and pair_coeff changes are no longer needed
also re-create reference log files
2025-03-25 03:01:38 -04:00
3ed03c4044 add post_constructor() method to computes for symmetry with fixes 2025-03-24 22:59:36 -04:00
15026cfa56 cosmetic 2025-03-24 22:59:05 -04:00
b4ff184a0a complete refactoring of handle check and error handling 2025-03-24 17:19:31 -04:00
d830412228 added boolean
the read_data is not reading slater boolean of pair_coeff
2025-03-24 16:04:40 +01:00
bbd057891a wrong qi*qj cuda code
correction of cutsq[mtype].z instead of extra[j].x !
2025-03-24 15:35:34 +01:00
b45c811fbb more argument error improvements 2025-03-24 09:15:19 -04:00
7b5c281596 when calling Error we must wrap the code in BEGIN/END capture 2025-03-24 05:52:47 -04:00
350fa4ddec more library interface argument checking and error handling 2025-03-24 05:25:11 -04:00
e0322b96ec sync new library interface function across all interfaced derived packages 2025-03-24 04:33:27 -04:00
15cdba0bf0 have Error::set_show_error() return the previous setting 2025-03-24 04:13:24 -04:00
e79fcfb4ef implement improved version of go-to-top button with javascript requiring only one click 2025-03-24 00:14:50 -04:00
3a18ca5197 updates, recover failed tests with -DLAMMPS_BIGBIG 2025-03-23 23:17:53 -04:00
9577343429 use a global constant for a common string buffer size 2025-03-23 22:21:05 -04:00
2b718d3b86 add interface to lammps_set_show_error() 2025-03-23 22:20:34 -04:00
aabfef6d0b update packaging to conform with suggested packaging changes 2025-03-23 22:20:02 -04:00
b4e4ea1069 we don't need lammps_throw_error. just call lmp->error->xxx 2025-03-23 21:23:24 -04:00
ccbf47c66d forgot exceptions in two cases 2025-03-23 19:02:10 -04:00
6fca985d5d add method that allows suppressing printing error messages immediately 2025-03-23 19:01:25 -04:00
a26ea958c6 throw suitable exception when trying to extract unknown or incompatible compute or fix data 2025-03-23 18:07:08 -04:00
a64863caa6 fix sphinx directive error in embedded docs 2025-03-23 16:37:20 -04:00
824b1b0b66 relax epsilon to pass tests on macos-arm64 2025-03-23 16:36:16 -04:00
3d5430bfe4 Merge branch 'develop' into errors-more-cleanup 2025-03-23 16:01:00 -04:00
adaa313990 Merge pull request #4502 from akohlmey/collected-small-fixes
Collected small changes and fixes
2025-03-23 15:59:38 -04:00
88cecbd11d alternate implementation of jump to top by @rbberger 2025-03-22 18:54:49 -04:00
c65c8819e3 cosmetic changes and re-wrap paragraphs 2025-03-22 16:06:17 -04:00
f4b92a23ae small clarification cherry-picked from PR #4502 2025-03-22 15:47:52 -04:00
6f24e1edd5 remove leftover pieces of obsolete warning 2025-03-22 15:42:51 -04:00
12cc12b4f4 Typos and alternate wording suggestions 2025-03-22 12:57:28 -06:00
cb5e45ff1f small tweaks 2025-03-22 11:24:53 -04:00
8a0900f0ab revert broken change to print angstrom character 2025-03-22 11:20:37 -04:00
9d0c25fbab improve wording 2025-03-22 11:15:26 -04:00
c289ad9471 forgot to include upward arrow image 2025-03-22 06:08:48 -04:00
725b34a70a add snapshot images to show the initial and final geometry and box 2025-03-22 06:08:16 -04:00
410d3e84b0 add a Howto demonstrating how to convert a bulk molecular system to a slab 2025-03-22 04:41:34 -04:00
1b58a4695b add explanations for "before/after simulation box is defined" errors 2025-03-21 20:30:47 -04:00
649fd86e11 add errorurl(11) with explanation to "Energy/Stess was not tallied by pair style" 2025-03-21 19:57:57 -04:00
3834169c92 first attempt to implement a "jump to top" anchor in the sidebar 2025-03-21 19:30:28 -04:00
3ab91e4e1a fix up uses of errorurl(21) 2025-03-20 23:12:21 -04:00
c037ec07a2 make utils::errorurl() point to generic page with error code 0 2025-03-20 22:45:41 -04:00
e9bc334a14 add some more missing errorurl() calls and error pointers 2025-03-20 22:45:01 -04:00
3b61bcf890 more error reporting updates 2025-03-20 12:31:08 -04:00
bbed85a410 Remove dead code 2025-03-20 15:08:02 +01:00
829a0868e8 fixed whitespace 2025-03-20 15:08:02 +01:00
f85a19d0b1 Added code which provides callbacks from external ML-IAP functions to exchange data
This is designed for message passing ML models.  Currently FP32/64 values can be communicated
but these are passed via doubles in MPI,
Work completed by
Forrest Glines <fglines@nvidia.com>
Matt Bettencourt <mattb@nvidia.com>
2025-03-20 15:08:01 +01:00
2e98ae9de9 Improve qtpie/reaxff docs and add qeqr/reaxff docs 2025-03-20 13:19:50 +00:00
e11245d0fd Add examples for fix qeqr/reaxff 2025-03-20 10:42:12 +00:00
e4c96459e5 flag some more compatible time and out-of-bounds errors with errorurl()s 2025-03-20 06:16:59 -04:00
ca575e395e fix spelling and duplicate references issues 2025-03-19 20:39:06 -04:00
643afe6eff fix segfault issue for optional arguments 2025-03-19 20:28:42 -04:00
04bb57f8e2 update a bunch more error messages 2025-03-19 17:17:47 -04:00
37248a011e deleted trailing whitespace in the Howto_moltemplate.rst file (for PR #4508) 2025-03-19 15:30:06 -04:00
63b8e86a4b tried to minimize the differences between my version and the existing version 2025-03-19 13:58:46 -04:00
6700a3bed1 Fixed the Moltemplate HowTo docs. (I also added a very simple polymer example.) This needed to be done because the file names and @atom types in the old version of this HowTo are no longer accurate. OPLSAA has changed. Now this HowTo is compatible with the latest version of OPLSAA. More importantly, after this update, the HowTo documentation should never need to be updated again because OPLSAA force field files are named according to the OPLSAA version/date. For example, the "oplsaa.lt" file has been renamed to "oplsaa2024.lt". Future OPLSAA updates will go in other files with different names. So the @atom types in this HowTo example should never need to be updated in the future, regardless what happens with OPLSAA. 2025-03-19 13:36:09 -04:00
db8abdb592 Update macOS info 2025-03-19 13:57:49 +01:00
bb8b6590d5 Remove unused header files and add affiliation 2025-03-19 11:22:04 +00:00
5bcfc35cd1 Reimplement warning through fix qtpie/reaxff 2025-03-19 10:23:22 +00:00
ee78e3e201 add -f option to install.py to install into externally-managed environments 2025-03-19 03:14:34 -04:00
b936673935 consolidate calls to utils::errorurl() with corresponding error class calls. 2025-03-19 02:23:10 -04:00
8a04dc036d Merge remote-tracking branch 'github/develop' into errors-more-cleanup 2025-03-19 01:39:22 -04:00
4cd3fa1e38 spelling 2025-03-18 20:24:04 -04:00
90cd786c2d document how to address "externally managed environment" errors with install-python 2025-03-18 20:20:56 -04:00
d02e26d3ba document DOWNLOAD_POTENTIALS with CMake 2025-03-18 19:49:04 -04:00
056733fb1f Add warning if fix efield is not in use
fix qeqr/reaxff leads to the same charges as fix qeq/reaxff when an
electric field is not applied, but at a slightly increased computational
cost. Therefore, fix qeq/reaxff should be used instead of fix
qeqr/reaxff when fix efield is not in use.
2025-03-18 18:14:37 +00:00
78bfa5b59b Create fix qeqr/reaxff 2025-03-18 17:51:30 +00:00
69881baa0c add false positives 2025-03-17 23:33:47 -04:00
4aece11628 add note about need to run ldconfig on Linux system after make install 2025-03-17 23:33:39 -04:00
7d6c19f51b adjust for macos_arm64 arch 2025-03-17 18:12:33 -04:00
f0b988904d add some notes about releasing a stable release update 2025-03-17 17:59:32 -04:00
e502d40491 Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-17 17:40:29 -04:00
6f0a59372c Merge pull request #4500 from akohlmey/remove-smallsmall
Remove support for -DLAMMPS_SMALLSMALL
2025-03-17 17:16:54 -04:00
b329d01e5e small clarification 2025-03-17 12:25:06 -04:00
aee02c7ed4 remove entries that are now covered by Errors_details.rst 2025-03-17 12:20:30 -04:00
afaf440895 expand/clarify some discussions 2025-03-17 12:20:07 -04:00
68c92f3267 add new explanation for warning about multiple time integrations 2025-03-17 12:18:32 -04:00
d42330edbd consolidate errors #6 and #7 plus handle non-numeric box. add missing entries. 2025-03-17 11:40:36 -04:00
9e8b9e55be Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-17 11:01:42 -04:00
0a7b528d39 don't silence format errors 2025-03-17 11:01:16 -04:00
368e0a22a0 adding WHAM dialog is postponed 2025-03-16 19:21:08 -04:00
d65b0ce666 update to WHAM version 2.1.0 2025-03-16 17:28:57 -04:00
afbae53a0a convert remaining errors to print coeff status 2025-03-16 06:03:23 -04:00
035aefcc26 address issues flagged by coverity scan 2025-03-15 21:38:18 -04:00
73585e1dcc revert broken change to print angstrom character 2025-03-15 21:17:00 -04:00
111817ce32 also print pair coeff setflag status when not all pair coeffs are set 2025-03-15 21:16:07 -04:00
b34b6b80e4 refactor info code so coeffs status can be appended to error 2025-03-15 20:11:33 -04:00
7b915b2983 error message does not exist anymore 2025-03-15 20:10:37 -04:00
96f135c294 some more small tweaks of explanation and spelling fixes 2025-03-15 16:38:12 -04:00
bca920a021 Merge remote-tracking branch 'github/develop' into errors-more-cleanup 2025-03-15 16:21:03 -04:00
589c026465 Tweaked the description of numbering order 2025-03-15 14:09:38 -06:00
2240430d5e Merge pull request #4495 from lammps/use-pandoc-for-fasthtml
Use pandoc for make fasthtml
2025-03-15 15:55:00 -04:00
067f998eac Update Build_manual.rst 2025-03-15 10:57:28 -06:00
546ea917c7 fix a few more .rst formatting issues flagged by pandoc 2025-03-15 12:35:12 -04:00
b9218528cf CSS style tweaks to make pandoc output more similar to sphinx output 2025-03-15 12:34:48 -04:00
54be0adfb8 resolve some issues in .rst files detected by pandoc 2025-03-15 12:00:53 -04:00
5b5b700318 copy image files to fasthtml folder 2025-03-15 12:00:16 -04:00
48570e01ba Merge branch 'develop' into use-pandoc-for-fasthtml 2025-03-15 11:05:12 -04:00
2c3824bdd0 update remaining places that used to support -DLAMMPS_SMALLSMALL 2025-03-15 02:11:50 -04:00
07c0c435ef Merge branch 'develop' into remove-smallsmall 2025-03-15 02:11:02 -04:00
ee930935f5 remove "self-explanatory" explanations. 2025-03-14 21:23:07 -04:00
aafdac1917 update intros to three pages with errors and warnings and cross-reference them 2025-03-14 21:06:23 -04:00
81ab0b7504 Merge pull request #4456 from akohlmey/add-error-explanations
Add short explanations and URL to them for common errors and warnings
2025-03-14 20:18:34 -04:00
3aba21f6e2 Merge pull request #4481 from akohlmey/collected-small-fixes
Collected small fixes and changes
2025-03-14 18:10:14 -04:00
361914f3f1 remove references to SMALLSMALL from GPU library 2025-03-14 16:31:30 -04:00
557d279774 remove references to SMALLSMALL from examples 2025-03-14 16:31:09 -04:00
55eeaca69c Merge pull request #4498 from evoyiatzis/patch-4
implement extract() in pair_style yukawa
2025-03-14 13:27:44 -04:00
4e0d37ecc2 ensure that df[] array is always initialized 2025-03-14 12:19:00 -04:00
4c3260a0dc fix bug missing a read_int() when reading general triclinic rotation matrix 2025-03-14 12:18:42 -04:00
cea31e463d remove references to -DLAMMPS_SMALLSMALL and trigger error when used 2025-03-14 10:20:31 -04:00
a0d1deea44 small clarification. add version tag for universe keyword 2025-03-14 09:54:55 -04:00
fcb2eee686 corrections for documentation of bosonic PIMD fix styles 2025-03-14 09:54:26 -04:00
e97807b92e clarify. mention using timer command to re-enable regular runs 2025-03-14 07:00:30 -04:00
29558a1141 key word -> keyword 2025-03-14 06:59:33 -04:00
5ab442f10b Include yukawa in the list of supported pair styles in fix_adapt.rst 2025-03-14 09:32:10 +01:00
7374d38b44 Update mol-pair-yukawa.yaml 2025-03-14 09:27:32 +01:00
419b18bd16 implement extract() in pair_yukawa.cpp 2025-03-14 09:25:28 +01:00
b11672a99f define extract() in pair_yukawa.h 2025-03-14 09:16:57 +01:00
d784706a68 small changes to appease coverity scan 2025-03-14 02:47:14 -04:00
e3de43f2b0 modernize use of \it and \sf 2025-03-13 22:25:14 -04:00
8ff5855e40 modernize boldface font selection in LaTeX sections 2025-03-13 22:14:07 -04:00
9da8a7f73a improve error pointers and out-of-range message for dump custom 2025-03-13 22:05:44 -04:00
bf1a5e05fd correctly flag out-of-range access for thermo data, where possible 2025-03-13 18:11:18 -04:00
03f71259c1 Merge pull request #4494 from lammps/example-input-fixes
fixed issues with several input scripts, added reference log files
2025-03-13 14:34:44 -04:00
34b3dd9ebd Proofreading errors doc page 2025-03-13 11:34:09 -06:00
889f91763f explain image flag related errors and warnings 2025-03-13 09:36:58 -04:00
bfdfd322df make compatible with C++20 and later 2025-03-13 05:41:32 -04:00
9d70c8b8ae provide error information for two more cases 2025-03-13 05:31:41 -04:00
0f10741f71 update tests for variable commands 2025-03-13 04:38:58 -04:00
f6394b2a61 remove obsolete line 2025-03-13 04:21:20 -04:00
c449bed814 apply clang-format 2025-03-13 04:15:49 -04:00
b53449ff10 free communicator only if not NULL 2025-03-13 04:15:41 -04:00
a1c0d93953 limit to 1 processor per partition 2025-03-13 04:15:16 -04:00
8c9e1fe6a2 update pimd/*/bosonic examples 2025-03-13 04:00:54 -04:00
009a7b1916 print detailed version string also for multi-replica runs 2025-03-13 03:58:51 -04:00
0812d3c772 must use delete[] on array allocated with new 2025-03-13 03:58:33 -04:00
71c8c2aaa2 improve error messages 2025-03-13 03:58:12 -04:00
933f618eb4 update .gitignore 2025-03-13 03:57:41 -04:00
0a4a2f6deb Merge branch 'develop' into collected-small-fixes 2025-03-13 03:06:14 -04:00
bdb661451d revert unintended commit 2025-03-13 03:00:24 -04:00
a892495575 revert unintended commit 2025-03-13 02:59:43 -04:00
24444f2f7c use minimal CSS file and explicit template 2025-03-12 23:45:48 -04:00
fd06c20a6a fix copy-n-paste error 2025-03-12 22:58:33 -04:00
f158b5195e add explanation for "did not assign all atoms" 2025-03-12 22:51:29 -04:00
33ac6c8836 address several issues related to variables and improve error messages 2025-03-12 22:33:07 -04:00
16ed78f435 Merge remote-tracking branch 'github/develop' into add-error-explanations 2025-03-12 20:36:18 -04:00
6d6fce7866 provide explanation for "variable evaluated before simulation box is defined" 2025-03-12 20:36:01 -04:00
084bdb2da6 Merge pull request #4496 from gplummer317/ctip
CTIP citation update
2025-03-12 19:59:17 -04:00
c3976a444c Merge branch 'develop' into use-pandoc-for-fasthtml 2025-03-12 19:54:58 -04:00
377c423e42 Update pair_coul.rst
Updated CTIP citation
2025-03-12 15:17:31 -07:00
063d595233 Update pair_coul.rst
Updated CTIP citation
2025-03-12 15:16:59 -07:00
9c4181e42e Update fix_qeq.rst
Updated CTIP citation
2025-03-12 15:15:35 -07:00
bd7420e496 Merge remote-tracking branch 'github/develop' into add-error-explanations 2025-03-12 18:08:53 -04:00
130b898e26 update documentation for new "make fasthtml" 2025-03-12 17:50:27 -04:00
c7f5d07a68 modernize LaTeX for formatting text in math mode 2025-03-12 17:14:11 -04:00
42219ac784 modernize LaTeX for formatting text in math mode 2025-03-12 17:08:56 -04:00
1931427a57 handle custom \AA macro for pandoc processing 2025-03-12 17:06:07 -04:00
24ce7bedcd Merge pull request #4493 from ssande7/correlate_first
Add `type first` option to correlation fixes
2025-03-12 16:33:38 -04:00
f097e8d951 Merge pull request #4479 from yotamfe/bosonic-pimd-langevin
Adding support for bosonic path integral molecular dynamics simulations
2025-03-12 15:28:51 -04:00
1b31064921 replace "fast" Sphinx build with build using pandoc for "fasthtml" target 2025-03-12 15:14:31 -04:00
38903fb7d2 replace (evil) tabs with spaces 2025-03-12 14:30:33 -04:00
9aba2c91c9 add citation reminder to fix qtpie/reaxff 2025-03-12 14:25:58 -04:00
3e62e660e5 Update fix_pimd_bosonic.rst - delete trailing whitespace 2025-03-12 18:20:30 +02:00
4a2d78fd99 Update fix_pimd.rst - delete trailing whitspace 2025-03-12 18:19:48 +02:00
d0aabe57bc better grammar 2025-03-12 11:59:34 -04:00
1cc69bd0df support referencing the general advice paragraphs 2025-03-12 11:58:30 -04:00
e3bf1a194d fix typos 2025-03-12 11:56:40 -04:00
930d3ddc17 resolve spelling and formatting issues 2025-03-12 11:53:57 -04:00
508eeddf87 Merge branch 'develop' into add-error-explanations 2025-03-12 11:39:13 -04:00
ebf6ba36bf remove leading 0 in single-digit url codes 2025-03-12 07:39:45 -06:00
90c713d065 update details on errors 6, 7, 8, 10, 13, and warning 28 2025-03-12 07:33:07 -06:00
d1671c24c4 add url for warning 28 2025-03-12 07:28:58 -06:00
fa262967e6 add url for error 10 2025-03-12 07:28:22 -06:00
6d42040b9d add url for error 13 2025-03-12 07:26:59 -06:00
70faf86040 add urls for error 08 2025-03-12 07:25:09 -06:00
ab63993226 add urls for error 07 2025-03-12 07:23:56 -06:00
2c2eaf09e6 add urls for error 06 2025-03-12 07:22:47 -06:00
1507d3511f Update fix_pimd.rst - added related commands 2025-03-12 12:45:24 +02:00
aa020c0ad3 Update fix_pimd_bosonic.rst - added related commands 2025-03-12 12:43:37 +02:00
d076b1c582 Update fix.rst - changed pimd/* to pimd/*/bosonic where needed 2025-03-12 12:38:09 +02:00
c144fc0fc6 Fix constant i for type first 2025-03-12 08:14:48 +10:00
5068406c03 fixed incorrect path to the potential file 2025-03-11 16:41:41 -05:00
0004a384fe fixed issues with several input scripts, added reference log files 2025-03-11 16:10:04 -05:00
1d3b93b042 Add type first option to fix ave/correlate 2025-03-11 20:54:38 +10:00
6fb382af3d Updated the documentation of pimd commands for distinguishable/bosonic particles. 2025-03-11 11:58:29 +02:00
b88accc50e Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-03-11 11:00:00 +02:00
242f77fce9 Changed the names of fix pimdb/* commands to pimd/*/bosonic; Changed file names accordingly. 2025-03-11 10:56:07 +02:00
1e819efcf8 update examples for consistency 2025-03-10 17:11:53 -04:00
01698ddc2e improve error messages for easier debugging 2025-03-10 17:06:37 -04:00
08f8be18e5 rework SPIN restart/data file examples 2025-03-10 17:04:16 -04:00
8af31ca28c fix minor memory leaks 2025-03-10 16:04:35 -04:00
9c494d0a25 include space in custom formats to show how spaces can be used to separate columns 2025-03-10 13:30:08 -04:00
5a1aed7957 properly tally the SYNC time contributions to the ALL time entry
this way its contribution is not double counted when determining
the "Other" time data.
2025-03-10 12:16:51 -04:00
6ff0f645e0 formatting 2025-03-10 06:28:45 -04:00
4cafb49c34 report which variable name was incorrect 2025-03-10 06:28:28 -04:00
312bdcbddd correct and clarify statements about the potentials and their relations to each other 2025-03-10 06:26:37 -04:00
79d2346eaa resolve spelling and formatting issues 2025-03-10 06:25:11 -04:00
4be39d6d2b fix typos 2025-03-09 22:46:03 -04:00
9ee1648af2 document removed compute atom/molecule and its equivalent using chunks 2025-03-09 22:21:51 -04:00
ca3d2de44b fix broken URL due to typo 2025-03-09 22:10:52 -04:00
ce10be7492 Merge branch 'develop' into collected-small-fixes 2025-03-08 22:28:31 -05:00
4246fab500 Merge pull request #4462 from jtclemm/BPM
Elastic-plastic bond style
2025-03-08 22:26:05 -05:00
15b7dd78f0 Revert "add some more tests for delete_atom"
This reverts commit 2ff078f973.
2025-03-08 18:00:57 -05:00
e3cf1dec27 restore original delete_atoms implementation. new version spun off as PR #4492 2025-03-08 17:52:26 -05:00
388f279633 set stores_ids flag for some fixes as suggested by @sjplimp 2025-03-07 12:43:32 -05:00
0a1e3fa26a Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-07 12:34:08 -05:00
976b73a2f2 fix typo 2025-03-07 12:05:38 -05:00
9af8fdc91e add MPI stub for MPI_Iprobe() 2025-03-07 11:50:53 -05:00
24fc6eb10a modernize error messages 2025-03-07 11:40:41 -05:00
6e94d83cff add option to synchronize fix halt stop requests across multi-partition runs 2025-03-07 11:40:27 -05:00
2ff078f973 add some more tests for delete_atom 2025-03-07 02:24:12 -05:00
7bd7be8f86 error out when trying unsupported pimd method with multiple processors per bead 2025-03-07 01:59:41 -05:00
22fa86a1b7 add "condense" keyword to delete_atoms what will compact the atom IDs while preserving their order 2025-03-06 20:44:05 -05:00
a61f67ceb7 Merge pull request #4490 from gsalkuin/fix-move-rotate
Add option to rotate dipoles in fix move rotate or transrot
2025-03-06 18:41:52 -05:00
9b1dca201f rewrite incorrect statement 2025-03-06 15:45:24 -05:00
46393cc930 modernize error messages 2025-03-06 13:15:24 -05:00
916ab55a31 reverse normalization between type pairs if the types were swapped on input 2025-03-06 13:15:09 -05:00
09c8dc07d8 update statements about what packages support and what not 2025-03-06 11:08:22 -05:00
3f9167be59 modernize error messages 2025-03-06 11:07:34 -05:00
1531810cc5 add versionadded tag 2025-03-06 03:59:47 -05:00
c16bbf6bb0 Merge branch 'develop' into fix-move-rotate 2025-03-06 03:08:53 -05:00
abc14c00a0 use different method to enforce the C locale in LAMMPS GUI 2025-03-05 17:40:36 -05:00
47cea8e1ba use pairwise cutoff for trimming unless a custom cutoff if given 2025-03-05 04:23:07 -05:00
b433c8cb77 only trim if neighbor list request has a custom cutoff 2025-03-05 04:16:13 -05:00
07c457221d Add checks, update flags 2025-03-05 00:19:27 -05:00
711d76531f Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-03-04 23:34:36 -05:00
505d295d16 small correction 2025-03-04 23:34:24 -05:00
6da1c6270c Merge pull request #4351 from dhairyaiitb/develop
Revised velocity verlet scheme to prevent unphysical sticking in DEM simulations.
2025-03-04 23:31:59 -05:00
cc70b5bb89 document some internal styles 2025-03-04 23:15:41 -05:00
389b07418b add false positives 2025-03-04 21:44:20 -05:00
16c3198d27 delete unused variables 2025-03-04 21:39:26 -05:00
885099cf77 Merge branch 'develop' into dhairyaiitb_develop 2025-03-04 21:29:40 -05:00
037251238b Add type first option to fix ave/correlate/long 2025-03-05 10:46:37 +10:00
a229b148d1 Update fix_move.rst 2025-03-04 18:09:19 -05:00
43f3db1867 Update fix_move.cpp
Make update dipole optional
2025-03-04 17:33:14 -05:00
61daafca62 Update fix_move.cpp 2025-03-04 15:27:16 -05:00
ac2214e5f2 Update fix_move.h 2025-03-04 15:26:41 -05:00
71b86b102d enable use of Sphinx 8.2.x 2025-03-03 21:08:45 -05:00
0f20eca322 Merge branch 'develop' into collected-small-fixes 2025-03-03 21:02:19 -05:00
16db8e1515 Merge pull request #4483 from Yuanlab-SUSTECH/mybranch
fix the bug of pair_ylz.cpp
2025-03-03 20:59:05 -05:00
700eb0c0e6 Merge pull request #4485 from akohlmey/fix-dispersion-d3-issues
Address several issues with pair style dispersion/d3
2025-03-03 20:58:29 -05:00
42923179e5 clarify which damping is documented where 2025-03-03 16:32:50 -05:00
2e3c1dfcc6 error explanations for net charge warning err_0029 2025-03-03 10:59:23 -07:00
bc3aafd324 update log files after bugfix to pair_style ylz 2025-03-03 08:06:33 -07:00
7fc4ba9628 move documentation of sign() function to logical location and add version tag 2025-03-02 12:40:32 -05:00
38f8299cfb Merge remote-tracking branch 'github/develop' into fix-dispersion-d3-issues 2025-03-01 00:44:14 -05:00
ea48161a51 update CODEOWNERS 2025-03-01 00:42:43 -05:00
e3b81ec784 cosmetic changes 2025-03-01 00:24:00 -05:00
98159e7c14 improve error detection and messages 2025-03-01 00:22:54 -05:00
169c051308 require metal units 2025-03-01 00:20:50 -05:00
9f78d5797b rename "zero" keyword for damping function to "original"
this avoids conflicts with pair style zero when used as a hybrid sub-style.
for backward compatibility the "zero" keyword is still recognized but
is undocumented.
2025-03-01 00:20:00 -05:00
3j
5d02e140d4 There is a wrong equation in the line490, MY_4PI should be MY_PI*zt 2025-02-28 17:43:54 +08:00
f4d2c518e8 make certain variable indices are initialized 2025-02-28 03:43:58 -05:00
1f4b955a34 add dihedral multi/harmonic/kk 2025-02-28 00:07:46 -07:00
c6ebb57b41 make certain that nstyle is always initialized and detect partial variable setups 2025-02-27 23:28:19 -05:00
ef5c797a84 Merge remote-tracking branch 'github/develop' into collected-small-fixes 2025-02-27 23:21:34 -05:00
4ed7d95bf9 Update bosonic_exchange.cpp
updated documentation of reduced/physical beta convention
2025-02-27 15:31:08 +02:00
4882fe8e8b Update bosonic_exchange.cpp
Typo
2025-02-27 12:46:45 +02:00
dbdc71433c Merge branch 'develop' into bosonic-pimd-langevin 2025-02-27 12:25:18 +02:00
c182fbd1c6 fix email 2025-02-27 12:24:43 +02:00
7f4d5bf0eb comment was removed at 8780cd8 but mistakenly not added somewhere else 2025-02-27 12:23:42 +02:00
aaa81b2576 Merge pull request #4475 from lasergyro/patch-1
Update fix_press_langevin.rst to include full equation 13
2025-02-27 03:02:39 -05:00
e1ba18aff9 Adding missing settings to restart files 2025-02-26 13:04:06 -07:00
f6c2f5bc74 Merge pull request #4454 from evoyiatzis/patch-4
Add support to region plane for having the normal vector read from variables
2025-02-26 13:50:07 -05:00
dc99e204d3 bugfix from Trung to avoid problems with read_dump when not all MPI ranks have atoms 2025-02-26 13:40:19 -05:00
a99a567f0c add note that dynamic groups are only supported without averaging 2025-02-26 11:12:58 -05:00
9bf19159a4 add block to list of regions with all-variable shape options 2025-02-26 10:42:52 -05:00
b89046d82f Merge branch 'develop' into patch-4 2025-02-26 10:40:41 -05:00
361f0dbe3c Update README
Corrected typo
2025-02-26 12:58:33 +02:00
d46edfed6d Added example input files for fix pimdb/nvt and fix pimdb/langevin 2025-02-26 11:37:41 +02:00
2c7e3dddbc add test to detect if a potential file was incorrectly used with lgvdw yes 2025-02-25 21:37:38 -05:00
7ceb8c461f Merge pull request #4477 from akohlmey/collected-small-changes
Collected small changes and bug fixes
2025-02-25 17:32:14 -05:00
1e2752bc5f correct indexing for static decomposition check 2025-02-24 21:31:18 -05:00
b3e75a6f84 adjust BondStyle:class2 epsilon for aarch64 and ppc64le builds 2025-02-24 12:09:51 -07:00
d79be293f5 move precomputation for factor_sqrt to individual Pair::compute() functions
the special_lj values may be changed for individual hybrid sub-styles
with pair_modify pair special. thus the factor_sqrt[] array may have
incorrect values when computed during Pair::init_style().
2025-02-24 08:19:28 -05:00
9f6f957f7c improve error messages for fix balance 2025-02-23 18:33:32 -05:00
6264a2b202 improve error messages for balance command 2025-02-23 18:22:02 -05:00
5532117417 re-order initializer and remove unused variables 2025-02-23 17:43:40 -05:00
8780cd89a5 move long comment 2025-02-23 20:26:01 +02:00
aee34a92d3 Merge pull request #2 from akohlmey/bosonic-pimd-langevin
Updates to LAMMPS pull request 4479
2025-02-23 20:15:19 +02:00
df360f0d55 fix email 2025-02-23 20:08:37 +02:00
c7e288eb8c apply clang-format 2025-02-23 12:46:34 -05:00
f4275ae44c PIMPLify access to BosonicExchange class 2025-02-23 12:45:35 -05:00
f1ef94aade apply clang-format 2025-02-23 12:33:26 -05:00
16b2988106 make filter_args() fully C++ compatible 2025-02-23 12:32:44 -05:00
35fca290fc enumerators must be defined within the scope of the class, not globally 2025-02-23 12:20:45 -05:00
f29a433fa9 apply clang-format and follow LAMMPS programming conventions more closely 2025-02-23 12:12:36 -05:00
0448651a90 reformatting and correcting doc page issues and appy spelling fixes and false positives 2025-02-23 12:05:53 -05:00
cef81881f9 homepage and developer email 2025-02-23 18:25:13 +02:00
cce060caa8 file permissions 2025-02-23 17:53:49 +02:00
e87e6dc5b0 more 2025-02-23 17:45:19 +02:00
f46d066e5b more 2025-02-23 17:43:15 +02:00
1cb47dc066 trailing whitespaces 2025-02-23 17:40:12 +02:00
63d49f50d1 Merge branch 'develop' of https://github.com/lammps/lammps into bosonic-pimd-langevin 2025-02-23 16:54:55 +02:00
c37bc484b6 added a note about filtered_args in the h file 2025-02-23 16:47:57 +02:00
d4011262f1 Made filtered_args in filter function local 2025-02-23 16:40:04 +02:00
f1e1099ac2 fix typo 2025-02-23 04:46:34 -05:00
4d453a65e6 fix bug in utils::strcompress()
calling back() on empty strings is undefined behavior.
2025-02-21 23:33:15 -07:00
3141723c24 restore more compact implementation using fmt::runtime() 2025-02-21 22:03:27 -05:00
b77c3bf8c7 make compatible with more strict consteval format requirements of C++20 2025-02-21 21:54:28 -05:00
1e078665f6 fix bug in angle style cosine/delta 2025-02-21 16:18:56 -05:00
29931c030f Added a filter of keywords instead of enable_esynch flag 2025-02-20 16:26:18 +02:00
7952281f78 Merge branch 'develop' into sync_verlet 2025-02-19 12:33:54 -07:00
a31f4f79b8 Merge branch 'develop' into sync_verlet 2025-02-19 12:32:29 -07:00
632d88912d Tweaking synchronization flag checks 2025-02-19 12:21:42 -07:00
dafbe5541a Changing default log to sync on, adding wall 2025-02-19 12:15:36 -07:00
8641486249 Swapping nx variable names 2025-02-19 11:29:40 -07:00
abc8954c5c Adding line breaks 2025-02-19 11:28:05 -07:00
11f66b4da1 fix copy and paste bug 2025-02-19 07:36:20 -05:00
fe8ebb308d Merge github.com:lammps/lammps into develop 2025-02-19 12:25:01 +01:00
90c2175056 Updated rotation and documentation 2025-02-18 20:16:31 -06:00
d772833f67 cr 2025-02-18 23:44:28 +02:00
6fb1f4466c fixed_whitespace 2025-02-18 13:10:07 -06:00
0a1b10faef updated version based on feedback 2025-02-18 12:58:09 -06:00
f0bc9ddcc9 Merge pull request #4473 from akohlmey/collected-small-changes
Collected small changes and fixes
2025-02-18 12:58:28 -05:00
f5099b7c16 Update fix_press_langevin.rst to include full equation 13
Completest equation 13 to match the [paper](https://pubs.aip.org/jcp/article/141/19/194108/152571/Constant-pressure-and-temperature-discrete-time) and the [implementation](36e739b734/src/fix_press_langevin.cpp (L485-L487)).
2025-02-18 17:15:01 +01:00
c19389a205 bug fix for pointing to the command name 2025-02-18 10:54:52 -05:00
816fb83d1a improve errors for atom_modify 2025-02-18 00:40:41 -05:00
3138f62ac8 renumber error 30 to 5 to match list of errors. Update error calls 2025-02-18 00:26:15 -05:00
0e07eab97f add some calls to utils::errorurl(22) 2025-02-18 00:05:12 -05:00
9be6b5a05b improve error handling for thermo output 2025-02-17 23:43:01 -05:00
fe5d6b154a simplify building of mini TOC at the top, renumber and reformat block 22 2025-02-17 23:42:04 -05:00
1c1749b6bf Merge branch 'add-error-explanations' of github.com:akohlmey/lammps into add-error-explanations 2025-02-17 23:06:44 -05:00
841e459b67 provide URL to explain fmt::format_error 2025-02-17 23:05:42 -05:00
25774943d5 Added advice on error 21 2025-02-17 17:25:07 -07:00
6f925e12dd Merge branch 'develop' into add-error-explanations 2025-02-17 15:39:22 -05:00
3ed6b617f0 tweaked number 11 2025-02-17 13:08:42 -07:00
5d4a277623 add versionadded tag 2025-02-16 22:51:00 -05:00
9f02f20023 add compute vacf/chunk command 2025-02-16 22:43:28 -05:00
77ab5bd624 minor rearrangement of if logic 2025-02-16 14:52:25 +02:00
52437e2152 Fixed a bug regarding keyword reading in pimdb_langevin; made sure the new esynch keyword in pimdb is not allowed in pimd 2025-02-16 11:02:15 +02:00
eaf624c0f0 Merge branch 'develop' into patch-2 2025-02-15 17:15:33 +01:00
89abf65751 python: remove unused import in core.py 2025-02-15 00:36:06 -07:00
5e61e6c0dc move update to cutneighmin from neighbor lists requests with explicit cutoff to a better location 2025-02-14 19:11:07 -05:00
33026e5fd3 correctly compute cutneighmin when multiple requests with different cutoff exist 2025-02-14 18:41:08 -05:00
79ed41837a fix some more errors 2025-02-14 17:17:04 -05:00
344bcc2304 Fix view with wrong label 2025-02-14 15:03:36 -07:00
ca5015eaea correct compute argument count check, avoid segfault 2025-02-14 16:55:09 -05:00
7f82dcd835 improve and modernize error messages 2025-02-14 15:23:16 -05:00
0fb79ae3ff Updated reference 2025-02-14 10:30:50 -06:00
c83ae0365e fix typo ncite in test_improper_style.cpp 2025-02-14 09:09:10 +02:00
2a35452c13 fix typo and add new line 2025-02-14 06:40:01 +00:00
52312fcd1d test for extract() in improper class 2025-02-14 06:22:29 +00:00
d83121878e make certain that Contact::varflag is initialized 2025-02-13 20:54:46 -05:00
b42cc2f588 make C++11 compatible 2025-02-13 20:39:18 -05:00
00b33b749b Merge remote-tracking branch 'github/develop' into collected-small-changes 2025-02-13 20:35:14 -05:00
36e739b734 Merge pull request #4470 from akohlmey/bye-bye-python-zwei
Remove support for Python 2.x and show corresponding errors.
2025-02-13 19:44:07 -05:00
53213fb6ff fix spelling issues 2025-02-13 18:27:08 -05:00
f4d2653cda add dummy section that is referenced from local TOC 2025-02-13 17:57:31 -05:00
ad51ef5aff don't use :ref: on a docpage 2025-02-13 17:56:14 -05:00
8dc7d254dc add section about segmentation faults 2025-02-13 17:55:55 -05:00
966ca42463 merge 'develop' 2025-02-13 17:13:28 -05:00
67ef0407bd must have a move constructor for some compilers 2025-02-13 17:01:44 -05:00
1c65907d72 Merge branch 'develop' into bye-bye-python-zwei 2025-02-13 17:01:39 -05:00
2a2e9919cf remove preliminary (and broken) code for creating planes and update docs, so the PR can be merged 2025-02-13 17:01:13 -05:00
f84ed6f9a4 must have a move constructor for some compilers 2025-02-13 16:54:28 -05:00
8ab8491da5 Merge branch 'develop' into collected-small-changes 2025-02-13 16:43:27 -05:00
52f068d1c5 Merge pull request #4466 from akohlmey/collected-small-changes
Collected small changes and fixes
2025-02-13 16:32:23 -05:00
bedcc59f83 remove preliminary (and broken) code for creating planes and update docs, so the PR can be merged 2025-02-13 15:32:36 -05:00
583f7b70b4 Fix rare bug in KOKKOS, manifest when load balancing on GPUs and exchange comm is on host 2025-02-13 12:41:16 -07:00
73852524dd Merge branch 'develop' into bye-bye-python-zwei 2025-02-13 03:17:53 -05:00
0f972a87fd adjust some wording for the removal of Python 2.x compatibility 2025-02-12 22:04:18 -05:00
ea2eb930c5 clarify 2025-02-12 21:47:11 -05:00
63d8915562 make use of SafeFilePtr 2025-02-12 21:47:02 -05:00
926f336962 add some note about build prerequisites 2025-02-12 21:46:37 -05:00
adfe84913f fix bogus array size bug 2025-02-12 17:58:34 -05:00
2e398bd17c improve error messages 2025-02-12 16:31:51 -05:00
1d362a7627 must call region->prematch() before creating graphics to update variables 2025-02-12 16:31:14 -05:00
98f3a0a1ba refactor cone visualization to match what LAMMPS is showing 2025-02-12 15:28:13 -05:00
66ec1ff360 make resolution of VMD graphics primitives a compile time constant. 2025-02-12 12:09:29 -05:00
7af11fe604 make more use of SafeFilePtr class. 2025-02-12 10:35:02 -05:00
944e50b06a need to define another constructor to make the SafeFilePtr class work for more cases 2025-02-12 10:34:21 -05:00
5b7bf1951e simplify logic for drawing a cylinder region 2025-02-12 05:42:51 -05:00
5479ac32d4 Adding errorurl for missing bond atom error 2025-02-11 16:06:20 -07:00
c1fb8cbf69 allowing bonds to break/create faster 2025-02-11 15:15:25 -07:00
d8893ea501 Heading to rheo citeme's 2025-02-11 14:55:52 -07:00
ac1221602b revert unnecessary renaming in improper harmonic
and sqdistharm files
2025-02-11 20:23:21 +00:00
47977a2821 Avoiding assumptions that array pointers are unchanged, misc clean ups in RHEO 2025-02-11 12:16:05 -07:00
ba14ce210c Fixing mistakes & clarifying BPM files 2025-02-11 10:42:56 -07:00
889b33df4a missed revert in improper_distharm.cpp 2025-02-11 16:26:35 +02:00
0b47e90008 revert renaming of variables in improper_distharm.cpp 2025-02-11 16:24:47 +02:00
89ceb73ec5 revert renaming in improper_distharm.h 2025-02-11 16:21:21 +02:00
7be7ffbaf1 revert renamin of cariable chi to chi0 in improper_cossq.cpp 2025-02-11 16:15:52 +02:00
c263c9a534 revert changes in improper_cossq.h 2025-02-11 16:12:34 +02:00
afaff7199b revert changes in improper_cossq_omp.cpp - they are not needed 2025-02-11 16:11:52 +02:00
b94d82d7b1 rename k anc chi in fix_adapt.rst 2025-02-11 16:04:33 +02:00
ed9b22cb0e rename k and chi in improper-distance.yaml 2025-02-11 16:03:42 +02:00
a708a50468 rename k and chi in improper_distance.cpp 2025-02-11 16:03:03 +02:00
1d974a51c0 Update fix_adapt.rst 2025-02-11 16:00:39 +02:00
fb6a1ad603 rename kw to k in improper-inversion_harmonic.yaml 2025-02-11 15:58:47 +02:00
8bba7ff10f rename kw to k in improper_inversion_harmonic.cpp 2025-02-11 15:58:07 +02:00
757eb8bf58 Update fix_adapt.rst 2025-02-11 15:53:58 +02:00
c66ca60f65 rename kw to k in improper-umbrella.yaml 2025-02-11 15:53:14 +02:00
94dd03d43c rename kw to k in improper_umbrella.cpp 2025-02-11 15:52:20 +02:00
5032436312 Update fix_adapt.rst 2025-02-11 15:49:46 +02:00
c9b4689167 rename sign and multiplicity in improper-cvff.yaml 2025-02-11 15:48:50 +02:00
bac4eec31b rename sign and multplicity in improper_cvff.cpp 2025-02-11 15:47:58 +02:00
a320a52804 Update fix_adapt.rst 2025-02-11 15:44:55 +02:00
11b95655f8 rename k0 to k in improper-class2.yaml 2025-02-11 15:42:30 +02:00
7e0f067b74 rename k0 to k in improper_class2.cpp 2025-02-11 15:41:22 +02:00
1d3ad36e85 add support for visualization plane regions 2025-02-11 07:40:42 -05:00
17797e4f74 tiny cr 2025-02-11 13:56:53 +02:00
252bd9aa9d must close "owned" file pointer if a different one is is assigned 2025-02-11 05:13:07 -05:00
08553a7272 apply safe file pointer 2025-02-10 22:48:55 -05:00
c42650257f move AutoClose class to separate header and rename to SafeFilePtr 2025-02-10 22:27:09 -05:00
f8b13b21ec Merge branch 'develop' into collected-small-changes 2025-02-10 17:57:49 -05:00
c41c4086ca Merge pull request #4468 from akohlmey/add-region2vmd-command
Add a new region2vmd command for visualizing regions with VMD
2025-02-10 16:57:44 -05:00
18cd31d811 Update fix_adapt.rst 2025-02-10 20:22:32 +02:00
e88946935c rename chi to theta0 in extract improper_ring.cpp 2025-02-10 20:19:13 +02:00
dc83bd3084 rename chi to theta0 in improper-ring.yaml 2025-02-10 20:18:13 +02:00
0b55587b1d add error 10 URL and text 2025-02-10 10:56:04 -07:00
7ae9ef75d8 Update fix_adapt.rst 2025-02-10 19:20:26 +02:00
70acd78048 change chi to d0 in improper_distharm.cpp 2025-02-10 19:18:58 +02:00
f738690cb5 change chi to d0 in improper_distharm.h 2025-02-10 19:16:47 +02:00
2b46abc31c change chi to d0 in improper-distharm.yaml 2025-02-10 19:15:58 +02:00
0c80ec5e0d change chi to chi0 in improper_harmonic_kokkos.cpp 2025-02-10 19:06:14 +02:00
3f5c54e362 change chi to chi0 in improper_harmonic_omp.cpp 2025-02-10 19:00:55 +02:00
7fe804d19d change chi to chi0 in improper_cossq_omp.cpp 2025-02-10 19:00:21 +02:00
c9bd1a7877 add url to improper_coeff messages 2025-02-10 09:59:04 -07:00
0f66e66529 add url to dihedral_coeff messages 2025-02-10 09:57:04 -07:00
8025a494d9 add url to angle_coeff messages 2025-02-10 09:49:53 -07:00
5251ba1465 change chi to chi0 in fix_adapt.rst 2025-02-10 18:45:40 +02:00
e90d5133cc change chi to chi0 in improper_cossq.cpp 2025-02-10 18:44:40 +02:00
9bce6662b4 change chi to chi0 in improper_cossq.h 2025-02-10 18:42:55 +02:00
8dfb967acc change chi to chi0 in improper-cossq.yaml 2025-02-10 18:42:07 +02:00
261cc13f99 Update fix_adapt.rst 2025-02-10 18:39:13 +02:00
f6e39d14b0 change chi to chi0 in improper_harmonic.cpp 2025-02-10 18:37:47 +02:00
0a4eea6aa0 add url to bond_coeff messages 2025-02-10 09:36:22 -07:00
ec0afc3fdf change chi to chi0 in improper_harmonic.h 2025-02-10 18:35:37 +02:00
6abdedc75b change chi to chi0 in improper-harmonic.yaml 2025-02-10 18:34:15 +02:00
75fd76aaa6 update text for MOLECULE package 2025-02-10 09:26:08 -07:00
9e249c9c57 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-02-10 17:37:05 +02:00
566a14f52d Pulling 2025-02-10 17:36:49 +02:00
2c1cd2ed04 Corrected minor rst syntax errors 2025-02-10 17:36:00 +02:00
54790d6095 Added a note about mic and pbc in the documentation of pimdb. 2025-02-10 17:21:06 +02:00
63b5e46bf0 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin
Conflicts:
	src/REPLICA/fix_pimdb_langevin.cpp
2025-02-10 15:07:25 +02:00
a67f67607c Added synch_energies parameters to pimdb/langevin 2025-02-10 15:05:11 +02:00
d9d24300a4 add support for ellipsoid regions 2025-02-10 00:05:42 -05:00
4cab0bfe1a implement all open face cases for cylinder regions 2025-02-09 22:19:03 -05:00
0de9da709c add support for moving regions and open faced regions 2025-02-09 18:25:14 -05:00
05521d38d9 initialization bug 2025-02-09 15:26:07 -05:00
6bd2e0e496 update error messages to use new Error class APIs 2025-02-09 10:53:03 -05:00
31697bac8d correct copy-n-modify omission 2025-02-09 10:22:55 -05:00
e00e215f99 add support to prism regions to be exported to VMD 2025-02-09 10:16:30 -05:00
7cf3ff588e include table with impropers in fix_adapt.rst 2025-02-09 16:54:15 +02:00
d11c8b3e1e Update text for improper style in fix_adapt.rst
Update text though a table with the potentials is not included
2025-02-09 15:08:02 +02:00
fe3c8487de implement check_itype in improper_hybrid.cpp 2025-02-09 14:48:10 +02:00
c0ef702af5 define chech_itype in improper_hybrid.h 2025-02-09 14:46:18 +02:00
f7a43b94a6 fix error: ‘else’ without a previous ‘if’ 2025-02-09 14:39:48 +02:00
e4a16556db implement the actual code to adapt improper parameters in fix_adapt.cpp 2025-02-09 14:26:28 +02:00
5557e03e54 add hint about setting top molecule in VMD 2025-02-08 23:26:43 -05:00
3cd028fd01 refactor command to be more flexible and capable 2025-02-08 22:52:19 -05:00
f693577262 add versionadded tag 2025-02-08 18:30:00 -05:00
0a8e2f923d add to .gitignore 2025-02-08 18:29:27 -05:00
8a87a6068c use lighter color "silver" 2025-02-08 18:23:57 -05:00
c7db4e9e19 add docs for region2vmd command 2025-02-08 18:06:32 -05:00
95858bccc6 add region2vmd command 2025-02-08 18:06:12 -05:00
8791b29aa2 give Region2VMD class access to protected members of region style classes 2025-02-08 18:05:57 -05:00
ea973e1d6c Update region.rst 2025-02-08 20:57:45 +02:00
424c694b6b update region.rst 2025-02-08 20:56:12 +02:00
49b5e89258 Update unit test in improper-fourier.yaml 2025-02-08 19:06:08 +02:00
e954bdfc14 implement extract in improper_fourier.cpp 2025-02-08 19:04:43 +02:00
2a2a7a3113 define extract in improper_fourier.h 2025-02-08 19:01:56 +02:00
66117414dd implement extract in improper_amoeba.cpp 2025-02-08 18:56:38 +02:00
38d28fb426 define extract for improper amoeba 2025-02-08 18:55:33 +02:00
098bb4b3c8 flag development version 2025-02-08 09:08:43 -05:00
314d0a0e61 only support Python version 3.6 or later. Update and correct docs and README 2025-02-08 05:54:26 -05:00
599ff11eb0 remove compatibility for compiling LAMMPS with Python 2.x and Python 3.5 and older 2025-02-08 05:05:00 -05:00
792144f12e Merge branch 'collected-small-changes' of github.com:akohlmey/lammps into collected-small-changes 2025-02-07 21:54:58 -05:00
86f7f6da98 Add check that Python 3 is required 2025-02-07 21:52:17 -05:00
8a1744c038 Updates to the instructions for building the manual. 2025-02-07 21:51:37 -05:00
b188cdc044 add check for Python version. Require minimum of Python 3.6 (Sphinx requires 3.8) 2025-02-07 20:51:50 -05:00
6eddb3a33f various minor tweaks and reformatting for CMake scripts 2025-02-07 20:50:14 -05:00
61a2db4715 revise and expand global README file 2025-02-07 19:47:05 -05:00
1a636acf81 simplify / optimize 2025-02-07 07:34:32 -05:00
d384de354a Update unit test in improper-class2.yaml 2025-02-07 09:31:28 +02:00
26e1b5d101 implement extract in improper_class2.cpp 2025-02-07 09:29:41 +02:00
909796b858 define extract for improper class2 2025-02-07 09:28:18 +02:00
ab6668031f explain some more about transition to C++17 2025-02-06 20:55:40 -05:00
d22533350a update copyright year 2025-02-06 20:55:23 -05:00
c9f41f9d90 explain more steps of the release process related to building packages 2025-02-06 20:55:11 -05:00
a547b9a417 do not mention rebasing 2025-02-06 15:00:54 -05:00
2440564bef Update unit test in improper-cossq.yaml 2025-02-06 21:23:36 +02:00
ced5fd3240 Update unit test in improper-umbrella.yaml 2025-02-06 21:22:05 +02:00
c918c7b547 Update unit test in improper-inversion_harmonic.yaml 2025-02-06 21:20:41 +02:00
f9b7013af3 Update unit test in improper-sqdistharm.yaml 2025-02-06 21:18:53 +02:00
33f5057488 Update unit test in improper-distance.yaml 2025-02-06 21:17:27 +02:00
22898fc8fc Update unit test in improper-distharm.yaml 2025-02-06 21:16:33 +02:00
72d2b70125 Update unit test in improper-ring.yaml 2025-02-06 21:15:28 +02:00
61f4012300 Update unit test in improper-harmonic.yaml 2025-02-06 21:14:46 +02:00
24f40c7db4 Update unit test in improper-cvff.yaml 2025-02-06 21:13:38 +02:00
ea9166d175 implement extract in improper distharm 2025-02-06 17:24:52 +02:00
676add28fe define extract in improper distharm 2025-02-06 17:24:13 +02:00
34e89bed4c implement extract in improper sqdistharm 2025-02-06 17:23:40 +02:00
ee7b0840ef define extract for improper sqdistharm 2025-02-06 17:22:50 +02:00
62e7698a44 implement extract in improper inversion_harmonic 2025-02-06 17:21:46 +02:00
3cd0871083 define extract for improper inversion_harmonic 2025-02-06 17:20:42 +02:00
52457d6c1e implement extract for improper distance 2025-02-06 17:18:13 +02:00
60181e2a8a define extract for improper distance 2025-02-06 17:17:17 +02:00
61a29f5421 implement extract for improper ring 2025-02-06 17:16:41 +02:00
01d091d8d6 define extract for improper ring 2025-02-06 17:15:36 +02:00
ca6ab28536 implement extract for improper cossq 2025-02-06 17:14:54 +02:00
de6f17c0ce define extract for improper cossq 2025-02-06 17:13:56 +02:00
7df94e179c fix error in improper_cvff.cpp 2025-02-06 17:12:22 +02:00
5233b21c21 implement extract in improper umbrella 2025-02-06 17:11:38 +02:00
59915a3b6a define extract in improper umbrella 2025-02-06 17:09:07 +02:00
a21b92f4de implement extract in improper cvff 2025-02-06 17:08:24 +02:00
36c2770383 define extract for improper cvff 2025-02-06 17:06:55 +02:00
84dbfa3e0d include files in fix_adapt.cpp 2025-02-06 15:46:29 +02:00
43d9d6af3e Update fix_adapt.h 2025-02-06 15:44:12 +02:00
a2508fef13 implement extract in improper harmonic 2025-02-06 15:41:20 +02:00
dda23a20b7 define extract for improper harmonic 2025-02-06 15:39:46 +02:00
feea204f7c implement reinit & set reinitflag flag to 1 2025-02-06 15:37:59 +02:00
95797d643b addition of extract & reinit methods in improper.h 2025-02-06 15:31:04 +02:00
04cad88b55 we can include ML-RANN package now in VLA check 2025-02-06 00:10:17 -05:00
97e7baf33f get rid of non-standard variable-length arrays in ML-RANN package 2025-02-05 23:41:36 -05:00
3ed6716b65 clarify that bad dynamics may occur in the documentation 2025-02-05 10:35:54 +02:00
fa285d9733 Merge branch 'develop' into BPM 2025-02-04 16:02:57 -07:00
e178f593be Adding BPM contribution statements 2025-02-04 15:49:01 -07:00
4a3394b300 Adding references to bpplastic bpm bond style 2025-02-04 15:42:01 -07:00
892c20cc20 fixing typo 2025-02-04 15:36:48 -07:00
acb9fdfc24 fix doc spacing for bpm/spring 2025-02-04 15:34:54 -07:00
2ae07ec1cb sync C++ standard selection with main CMakeLists.txt file 2025-02-04 17:00:12 -05:00
edaab05db6 Tweaking BPM plastic example parameters 2025-02-04 13:12:35 -07:00
262ff223c6 make clear that the vector should be all constant or all equal variables 2025-02-04 13:56:22 +02:00
3b8139d428 update formatting (reflow) 2025-02-03 15:08:12 -07:00
02f98947f9 update unique coeff messages 2025-02-03 13:12:11 -07:00
32d0bf1bee update all simple coeff messages 2025-02-03 12:13:52 -07:00
504e747f3d add initial error URL and test 2025-02-03 11:56:39 -07:00
e84b172417 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-02-03 16:51:18 +02:00
842eec1e73 comment on conventions in primitive estimator in langevin 2025-02-03 16:50:41 +02:00
e6f2757385 Merge branch 'develop' into patch-4 2025-02-02 17:36:52 +01:00
150cd216ba another one whitespace 2025-02-01 09:46:06 +02:00
b2b9f2c3e9 remove whitespace in region.rst 2025-02-01 09:31:45 +02:00
418b205362 Update region.rst 2025-02-01 09:30:20 +02:00
4e582993c4 use simpler std::string concatenation instead of implicit fmt::format() processing 2025-01-31 16:07:39 -05:00
8c2bbc1608 add error URLs for molecule files 2025-01-31 15:57:53 -05:00
1d56981bb1 reassign error URL numbers to match list in pull request 2025-01-31 15:15:10 -05:00
72eb284f76 remove whitespace from region_plane.cpp 2025-01-31 17:22:15 +02:00
1057882126 Include variables in region_plane.h 2025-01-31 17:14:49 +02:00
0b1ef95562 Update methods in region_plane.cpp 2025-01-31 17:11:22 +02:00
ed627579f6 Adding bpm/plastic demo, fixing mistake in poisson example 2025-01-30 16:44:11 -07:00
33c4ce8929 Adding auxetic/incompressible bpm demo 2025-01-30 14:54:59 -07:00
dda72fee76 Drafting bpm/plastic doc page 2025-01-30 11:42:26 -07:00
080df8cf74 BPM plastic citation info 2025-01-30 11:22:06 -07:00
ec0c8cc847 Documented the primitive estimator in the rst file. 2025-01-30 16:06:21 +02:00
feafce74b3 Minor changes and documentations of the primitive estimator for bosons 2025-01-30 15:04:48 +02:00
5882ec9370 Minor cleaning of bosonic_exchange.cpp 2025-01-30 11:32:11 +02:00
7fe3da56a0 Added an assert for get_interior_bead_spring_energy if called from the first bead. 2025-01-30 10:09:10 +02:00
3e587685b6 Initial plastic BPM bond style 2025-01-29 15:25:55 -07:00
2e0bc27646 adding bpm energy proxy 2025-01-29 15:24:50 -07:00
8ecd7e8629 Fixed an error in the primitive estimator 2025-01-27 18:49:30 +02:00
d91a75a9af Corrected PIMD-B after CR 2025-01-27 15:30:24 +02:00
b2def45011 Deleted a redundant file 2025-01-27 13:43:31 +02:00
c47f7d5618 cr 2025-01-27 13:36:40 +02:00
d5b82562bd Merge branch 'develop' into group-bitmap-accessor 2025-01-25 13:49:33 -05:00
6663e998d9 Merge branch 'develop' of github.com:lammps/lammps into develop 2025-01-22 17:11:31 +01:00
6f19d1fe0e molmap docs attempt
not a simple feature to describe in words
2025-01-21 21:58:51 -05:00
844f8e4e16 clarify how molecule IDs treated for 2025-01-21 20:28:21 -05:00
ee3e113339 initialize 'created atoms' mol ID to zero
can control using molmap option
2025-01-21 20:15:50 -05:00
c353c3c6c6 better treatment for 'new mol IDs'
for molecule IDs in post-reaction template, but not in pre-reaction template, adds new molecule ID onto previous max  molecule ID
2025-01-21 18:31:08 -05:00
2765f35340 It seems the problem was not with the primitive estimator but when initializing all particles at 0 0 0.
When initialized randomly it works.
2025-01-21 17:12:03 +02:00
9fd0d09b5f pimdb works with NVE and conserves energy. Fixed a little bug and now the printed total energy is also conserved.
From some reasin the primitive estimator doesn't work with Langevin :((((((
2025-01-21 11:57:37 +02:00
002fc02b3d Got rid of the calc function in bosonic_exchange, the calculation is performed in the get function.
Added prepare_coordinates in pimd/nvt and pimd/langevin for that purpose
2025-01-15 16:41:19 +02:00
358e6e82a0 Removed some code review note 2025-01-15 11:53:32 +02:00
f02f6b50c4 Removed footprints of past merge 2025-01-15 11:44:57 +02:00
2a9a1aeeab Updated doc/src/fix_pimdb.rst 2025-01-15 11:43:32 +02:00
1b79f34b22 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-01-15 10:59:43 +02:00
7f6cfd364d commit before pull 2025-01-15 10:55:13 +02:00
274525ca25 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-01-15 10:36:55 +02:00
ec504e3324 Fixed some error with the ENUM definitions 2025-01-15 10:35:33 +02:00
a661ffdb06 Merge branch 'develop' into develop 2025-01-14 12:06:07 -06:00
1d2f42dce9 Merge branch 'develop' into develop 2025-01-13 14:24:22 -06:00
2898592bb4 Merge branch 'develop' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-01-13 17:45:11 +02:00
f3b1f56fa8 Merge pull request #1 from BarakHirshberg/bosonic-pimd-langevin
Bosonic pimd langevin
2025-01-13 17:38:25 +02:00
795a5daade removed html folder which was added by accident 2025-01-13 17:37:13 +02:00
a5eb0dc105 went over text 2025-01-13 17:22:56 +02:00
edca6eb4db this is a lost cause 2025-01-13 14:55:48 +00:00
60583c5e35 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2025-01-13 16:48:16 +02:00
a5e28252cf add referece for virial works for bosons 2025-01-13 16:47:30 +02:00
77d8942589 Merge branch 'develop' into group-bitmap-accessor 2025-01-13 01:08:47 -05:00
ac68f70e20 three more 2025-01-09 21:23:56 -05:00
5419fe0925 Merge branch 'develop' into group-bitmap-accessor 2025-01-09 21:05:42 -05:00
25c92d6399 fixed conflict 2025-01-09 19:21:55 -06:00
75dba6f39b Merge branch 'lammps:develop' into develop 2025-01-09 19:21:06 -06:00
e2f735ad29 fix whitespce 2025-01-09 19:20:21 -06:00
5bb1fe42dd resolved conflict 2025-01-09 19:08:19 -06:00
195f8a9670 a couple more updates to use the new API 2025-01-09 19:30:34 -05:00
d68287a9c7 updated documentation 2025-01-09 17:33:08 -06:00
12b6b797b8 simplify 2025-01-09 14:47:20 -05:00
b1e881d4ff Merge branch 'develop' into group-bitmap-accessor 2025-01-09 14:37:38 -05:00
f16aa8e32e PIMDB langevin now supposes to support NVE 2025-01-07 12:13:01 +02:00
f07c28a7a1 Update bosonic_exchange.cpp 2025-01-06 17:57:27 +02:00
4fa36164cf Added bibliographic details to fix_pimdb_nvt.cpp 2025-01-06 17:51:57 +02:00
fa014649e5 Filled bibliographic details in fix_pimdb_langevin.cpp 2025-01-06 17:50:19 +02:00
c9fb27686d Fixed an error in the documentation: pimd method only supports physical fmmode, not normal 2025-01-06 17:26:47 +02:00
c03d15f759 tiny cr 2025-01-06 16:17:57 +02:00
1e491dc593 Merge branch 'develop' of https://github.com/lammps/lammps into bosonic-pimd-langevin 2025-01-06 16:04:43 +02:00
42a884a14c touch docs 2025-01-06 15:44:23 +02:00
d31c040cb9 Merge branch 'develop' into bond/react-molmap_option 2025-01-04 18:05:59 -05:00
b86832e72f Added checks for non-supported parameters for pimdb/langevin, and updated the documentation accordingly. 2024-12-30 12:41:42 +02:00
53c91e67a1 Expanded the documentation of iPy/Tuckerman's convention; made spring_force const; nvt sets mic to true. 2024-12-30 11:01:37 +02:00
e94f3a53bd Update fix_pimdb_nvt.cpp 2024-12-24 16:53:08 +02:00
364843d277 Update fix_pimdb.rst 2024-12-24 16:50:45 +02:00
e253dcf2a5 Update fix_pimdb.rst 2024-12-24 11:49:29 +02:00
28dc82f3ed Started documenting pimdb 2024-12-24 11:26:03 +02:00
df44ee9504 Accepted some of Yotam's code review, there are still open discussions (search OB) 2024-12-23 15:50:27 +02:00
6905bc736b cr 2024-12-23 11:34:32 +02:00
1e968d9cb0 Merge branch 'develop' of github.com:lammps/lammps into develop 2024-12-19 13:14:38 +01:00
db2f5dc407 clean-up and test example 2024-11-18 04:42:17 -06:00
5a826c67f6 corrected cohesive flag 2024-10-25 15:50:23 -05:00
9f6a7b1249 Added rotate_rescale_vec 2024-10-25 15:36:30 -05:00
e9022af338 another reaction map validity check 2024-10-13 23:10:31 -04:00
579ce56cd7 consistent 'nofix' options for write_data
'fix bond/react' writes some extra sections that parsers don't always know how to handle
2024-10-13 22:18:49 -04:00
5bec534faf Merge pull request #3 from Bibobu/dependabot/github_actions/actions/setup-python-5
Bump actions/setup-python from 4 to 5
2024-10-13 17:48:10 +02:00
598035d577 Merge pull request #4 from Bibobu/dependabot/github_actions/github/codeql-action-3
Bump github/codeql-action from 2 to 3
2024-10-13 17:47:49 +02:00
35b0d4a921 Merge pull request #5 from Bibobu/dependabot/github_actions/actions/cache-4
Bump actions/cache from 3 to 4
2024-10-13 17:47:22 +02:00
c5c22bd56a Moved vir_estimator from bosonic_exchange to fix_pimd_nvt 2024-10-10 15:54:42 +03:00
9d85a04573 Corrected most of Yotam's comments, left some for discussion 2024-10-09 17:40:23 +03:00
1fc7cca77c cr 2024-10-09 15:15:36 +03:00
c645a6b841 more 2024-10-09 11:59:23 +03:00
85a0b668c3 remove files autogenerated upon build 2024-10-09 11:57:45 +03:00
f357e89d19 fixed whitespaces 2024-10-08 12:58:58 -05:00
54e7a8a4c7 The primitive estimator works with the new implementation of the cyclic energies! 2024-10-08 14:08:03 +03:00
e9c2a12f99 Changed the evaluation of the cyclic energies such that they don't include internal beads and communication between processors.
It produces exactly the same trajectories for the first few thousand steps, and the spring energy is consistent with the previous code.
The primitive estimator needs to be adjusted...
2024-10-08 12:06:06 +03:00
4eef02af5a updated rolling and walls 2024-10-07 10:58:30 -05:00
74d3b5de09 added normal mode to pimdb/nvt 2024-10-07 14:15:51 +03:00
6a75e64879 The primitive estimator for pimdb/nvt looks fine! The spring energy returns the value of BosonicExchange::get_potential() for the first bead and 0 for all other beads. 2024-10-06 16:21:30 +03:00
be93e0e37b The virial estimator of the pimdb/nvt gives the same value as the potential energy for harmonic potential. It seems to give the correct value for bosons!
The output vector of pimdb/nvt also returns the spring energy and the primitive estimator that are still incorrect.
2024-10-06 12:34:24 +03:00
c36e1a9c8e save current status to git 2024-09-29 21:41:54 -04:00
563525bd6b Created fix_pimdb_nvt; added virial estimator to bosonic_exchange.
Checked 3 bosons in harmonic trap: energy seems to be OK, but virial estimator != potential energy
2024-09-29 16:45:56 +03:00
adb3343a17 Start general document about file formats 2024-09-25 23:15:20 -04:00
02698e9d36 Merge branch 'bond/react-molmap_option' of https://github.com/jrgissing/lammps into bond/react-molmap_option 2024-09-20 23:51:01 -04:00
1fb695f354 copy/paste error in bond/react example 2024-09-20 23:50:49 -04:00
a48c6c13a2 Merge branch 'lammps:develop' into bond/react-molmap_option 2024-09-20 21:48:45 -06:00
0a95bcd2cc Merge branch 'develop' of https://github.com/dhairyaiitb/lammps into develop 2024-09-20 16:42:56 -05:00
c65ff237ee Updated verlet halfstep 2024-09-20 16:39:48 -05:00
42e6880820 Merge branch 'lammps:develop' into develop 2024-09-20 13:57:25 -05:00
14dc2fb1d8 Updated verlet halfstep 2024-09-20 13:56:35 -05:00
1318e3590e Merge branch 'develop' into group-bitmap-accessor 2024-09-06 17:10:27 -04:00
37f7f62b77 add more control to mol ID updates 2024-08-31 16:48:29 -04:00
9a295d73b6 Merge branch 'develop' into group-bitmap-accessor 2024-08-31 00:07:46 -04:00
d8d3ddc140 Merge branch 'develop' into group-bitmap-accessor 2024-07-30 20:30:37 -04:00
25a4117e67 Merge branch 'develop' into group-bitmap-accessor 2024-07-24 00:08:55 -04:00
7a3dd2231b Merge branch 'develop' into group-bitmap-accessor 2024-06-21 14:31:55 -04:00
991f09905e Merge branch 'develop' into group-bitmap-accessor 2024-06-06 02:18:11 -04:00
8d1c5734c4 Merge branch 'develop' into group-bitmap-accessor 2024-06-05 10:56:54 -04:00
d415db4106 Merge branch 'develop' into group-bitmap-accessor 2024-06-04 17:15:47 -04:00
a0939c4fcc use new bitmap accessor function and simplify code 2024-06-01 17:57:31 -04:00
5f2c81804d add unit test for bitmap accessor 2024-06-01 16:45:53 -04:00
279b218af1 fix logic bug 2024-06-01 16:45:39 -04:00
7acc46475d Merge branch 'develop' into group-bitmap-accessor 2024-06-01 12:17:25 -04:00
d5fdefa40a Update fix_pimdb_langevin.cpp 2024-05-04 17:51:38 +03:00
61d6220aa6 override the primitive estimator 2024-03-25 19:38:37 +02:00
c49168bba3 correct spring energy properties. more epxlicit handling of vector outputs 2024-03-25 19:32:10 +02:00
8e099b30da Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2024-03-25 17:56:52 +02:00
623bf2dddb Merge branch 'develop' of https://github.com/lammps/lammps into bosonic-pimd-langevin 2024-03-25 17:54:56 +02:00
e2b8d999c0 Account for the fact that beta is actually beta_np in the bosonic primitive kinetic energy estimator 2024-03-14 10:23:31 +02:00
ba8d1587d4 Merge branch 'bosonic-pimd-langevin' of https://github.com/yotamfe/lammps into bosonic-pimd-langevin 2024-03-11 15:39:28 +02:00
33fb1c1e45 override total spring energy, remove ad-hoc computation of kinetic energy estimators (should be done in fix_pimd_langevin) 2024-03-11 15:37:58 +02:00
5c3c0588f1 Remove minuses in the spring energies because spring_constant is positive 2024-03-11 14:28:06 +02:00
1cc83bb1ac Pass beta_np instead of beta to the bosonic code 2024-03-11 14:26:17 +02:00
3ffa5908ca add get_bitmask_by_id() accessor to Group class 2024-02-27 10:16:34 -05:00
b23f70daf7 Bump actions/cache from 3 to 4
Bumps [actions/cache](https://github.com/actions/cache) from 3 to 4.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-22 17:37:35 +00:00
c234d6e997 Bump github/codeql-action from 2 to 3
Bumps [github/codeql-action](https://github.com/github/codeql-action) from 2 to 3.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-12-18 17:51:12 +00:00
d9ed0c2288 Added kinetic energy estimators. 2023-12-15 12:21:28 +02:00
57ce8ee6ab Bump actions/setup-python from 4 to 5
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 4 to 5.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](https://github.com/actions/setup-python/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-12-11 17:50:00 +00:00
d56868c675 Remove redundant broadcasting in evaluate_cycle_energies. 2023-12-01 16:52:56 +02:00
1fe2891e74 Correct indices for temp_nbosons_array. 2023-12-01 16:46:43 +02:00
84b1ecff6f change sign of forces (difference in spring constant's sign_, remove separate virial calculation 2023-11-21 16:40:04 +02:00
a80406347c pimdb works only in method pimd 2023-11-20 17:39:38 +02:00
f4a133c47a translate between orders from bosonic exchange force to atom force 2023-11-20 17:36:30 +02:00
148c23e24d fix fix 2023-11-20 17:13:28 +02:00
12ef219da6 pass correct positions to exchange 2023-11-20 17:11:25 +02:00
4907a530c2 fix beta passing to bosonic exchange, mic optional 2023-11-20 14:27:52 +02:00
eb8070b7c3 start work on integrating bosonic exchange to fix_pimd/langevin 2023-11-19 23:47:30 +02:00
1499 changed files with 70545 additions and 30419 deletions

3
.github/CODEOWNERS vendored
View File

@ -71,7 +71,10 @@ src/EXTRA-COMMAND/group_ndx.* @akohlmey
src/EXTRA-COMMAND/ndx_group.* @akohlmey
src/EXTRA-COMPUTE/compute_stress_mop*.* @RomainVermorel
src/EXTRA-COMPUTE/compute_born_matrix.* @Bibobu @athomps
src/EXTRA-DUMP/dump_extxyz.* @fxcoudert
src/EXTRA-FIX/fix_deform_pressure.* @jtclemm
src/EXTRA-PAIR/pair_dispersion_d3.* @soniasolomoni @arthurfl
src/EXTRA-PAIR/d3_parameters.h @soniasolomoni @arthurfl
src/MISC/*_tracker.* @jtclemm
src/MC/fix_gcmc.* @athomps
src/MC/fix_sgcmc.* @athomps

View File

@ -28,14 +28,14 @@ Create a 'next\_release' branch off 'develop' and make the following changes:
..versionadded:: or ..versionchanged:: are missing and need to be
added
Submit this pull request, rebase if needed. This is the last pull
request merged for the release and should not contain any other
changes. (Exceptions: this document, last minute trivial(!) changes).
Submit this pull request. This is the last pull request merged for the
release and should not contain any other changes. (Exceptions: this
document, last minute trivial(!) changes).
This PR shall not be merged before **all** pending tests have completed
and cleared. We currently use a mix of automated tests running on
either Temple's Jenkins cluster or GitHub workflows. Those include time
consuming tests not run on pull requests. If needed, a bugfix pull
consuming tests not run on pull requests. If needed, a bug-fix pull
request should be created and merged to clear all tests.
### Create release on GitHub
@ -56,7 +56,7 @@ git pull
git checkout release
git pull
git merge --ff-only develop
git tag -s -m "LAMMPS feature release 19 November 2024" patch_19Nov2024
git tag -s -m "LAMMPS feature release 4 February 2025" patch_4Feb2025
git push git@github.com:lammps/lammps.git --tags develop release
```
@ -77,7 +77,7 @@ release page with a summary of all the changes included and references
to the pull requests they were merged from or check the existing draft
for any necessary changes from pull requests that were merged but are
not listed. Then select the applied tag for the release in the "Choose
a tag" dropdown list. Go to the bottom of the list and select the "Set
a tag" drop-down list. Go to the bottom of the list and select the "Set
as pre-release" checkbox. The "Set as the latest release" button is
reserved for stable releases and updates to them.
@ -87,12 +87,18 @@ you can return to edit the release page and publish it.
### Prepare pre-compiled packages, update packages to GitHub
Build a fully static LAMMPS installation using a musl-libc
cross-compiler, install into a lammps-static folder, and create a
tarball called lammps-linux-x86_64-19Nov2024.tar.gz (or using a
corresponding date with a future release) from the lammps-static folder.
A suitable build environment is provided with the
https://download.lammps.org/static/fedora37_musl.sif container image.
https://download.lammps.org/static/fedora41_musl_mingw.sif container
image. The corresponding container build definition file is maintained
in the tools/singularity folder of the LAMMPS source distribution.
#### Fully portable static Linux x86_64 non-MPI binaries
The following commands use the Fedora container to build a fully static
LAMMPS installation using a musl-libc cross-compiler, install it into a
`lammps-static` folder, and create a tarball called
`lammps-linux-x86_64-4Feb2025.tar.gz` (or using a corresponding date
with a future release) from the `lammps-static` folder.
``` sh
rm -rf release-packages
@ -105,49 +111,173 @@ cmake -S lammps-release/cmake -B build-release -G Ninja -D CMAKE_INSTALL_PREFIX=
cmake --build build-release --target all
cmake --build build-release --target install
/usr/musl/bin/x86_64-linux-musl-strip lammps-static/bin/*
tar -czvvf lammps-linux-x86_64-19Nov2024.tar.gz lammps-static
tar -czvvf ../lammps-linux-x86_64-4Feb2025.tar.gz lammps-static
exit # fedora 41 container
cd ..
```
The resulting tar archive can be uploaded to the GitHub release page with:
```
gh release upload patch_19Nov2024 lammps-linux-x86_64-19Nov2024.tar.gz
``` sh
gh release upload patch_4Feb2025 lammps-linux-x86_64-4Feb2025.tar.gz
```
#### Linux x86_64 Flatpak bundle with GUI included
Make sure you have the `flatpak` and `flatpak-builder` packages
installed locally (they cannot be used from the container) and build a
installed locally (they require binaries that run with elevated
privileges and thus cannot be used from the container) and build a
LAMMPS and LAMMPS-GUI flatpak bundle in the `release-packages` folder
with:
``` sh
cd release-packages
flatpak --user remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
flatpak-builder --force-clean --verbose --repo=$PWD/flatpak-repo --install-deps-from=flathub --state-dir=$PWD --user --ccache --default-branch=release flatpak-build lammps-release/tools/lammps-gui/org.lammps.lammps-gui.yml
flatpak build-bundle --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo --verbose $PWD/flatpak-repo LAMMPS-Linux-x86_64-GUI-19Nov2024.flatpak org.lammps.lammps-gui release
flatpak build-bundle --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo --verbose $PWD/flatpak-repo ../LAMMPS-Linux-x86_64-GUI-4Feb2025.flatpak org.lammps.lammps-gui release
cd ..
```
The resulting flatpak bundle file can be uploaded to the GitHub release page with:
```
gh release upload patch_19Nov2024 LAMMPS-Linux-x86_64-GUI-19Nov2024.flatpak
``` sh
gh release upload patch_4Feb2025 LAMMPS-Linux-x86_64-GUI-4Feb2025.flatpak
```
Also build serial executable packages that also include LAMMPS-GUI for
Linux, macOS, and Windows, and upload them to the GitHub release.
#### LAMMPS Source tarball
Clean up:
The container for the static binary can also be used to prepare the source
tarball including the HTML and PDF manual (this is currently done automatically
when the releases is created and the tarball uploaded to https://download.lammps.org/tars/).
The steps are as follows:
``` sh
cd release-packages
apptainer shell fedora41_musl_mingw.sif
cd lammps-release
rm -f ../release.tar*
git archive --output=../release.tar --prefix=lammps-4Feb2025/ HEAD
cd doc
make clean-all
make html pdf
tar -rf ../../release.tar --transform 's,^,lammps-4Feb2025/doc/,' html Manual.pdf
gzip -9v ../../release.tar
mv ../../release.tar.gz ../../lammps-src-4Feb2025.tar.gz
exit # fedora41 container
cd ..
```
The resulting source tarball can be uploaded to the GitHub release page with:
``` sh
gh release upload patch_4Feb2025 lammps-src-4Feb2025.tar.gz
```
#### Build Windows Installer Packages with MinGW Linux-to-Windows Cross-compiler
The various Windows installer packages can also be built with
apptainer container image.
``` sh
cd release-packages
apptainer shell fedora41_musl_mingw.sif
git clone --depth 10 https://github.com/lammps/lammps-packages.git lammps-packages
cd lammps-packages/mingw-cross
ln -sf ../../lammps-release lammps
./buildall.sh release >& mk.log & less +F mk.log
```
The installer with the GUI included can be uploaded to the GitHub release page with:
``` sh
ln -sf LAMMPS-64bit-GUI-4Feb2025.exe LAMMPS-Win10-64bit-GUI-4Feb2025.exe
gh release upload patch_4Feb2025 LAMMPS-Win10-64bit-GUI-4Feb2025.exe
```
The symbolic link is used to have a consistent naming scheme for the packages
attached to the GitHub release page.
#### Clean up:
``` sh
cd ..
rm -r release-packages
```
TODO:
- add detailed commands for building GUI packages on Ubuntu 20.04LTS (move to 22.04LTS?),
macOS, and Windows cross-compiler and upload to GitHub
- build all Windows cross-compiled installer packages using lammps-packages repo
#### Build Multi-arch App-bundle for macOS
### Update download website
Building app-bundles for macOS is not as easily automated and portable
as some of the other steps. It requires a machine actually running
macOS. In that machine the Xcode compiler package needs to be
installed. This also includes tools for building and manipulating disk
images. This compiler supports building executables for both, the
x86_64 and the arm64 architectures. This requires building with CMake
and using the CMake settings:
``` sh
-D CMAKE_OSX_ARCHITECTURES=arm64;x86_64
-D CMAKE_OSX_DEPLOYMENT_TARGET=11.0
```
This will add the compiler flags `-arch arm64 -arch x86_64
-mmacosx-version-min=11.0` and thus produce object for both
architectures and support for macOS versions back to version 11 (aka Big
Sur). With these settings the following libraries should be compiled
and installed (e.g. to `$HOME/.local`) as static libraries only:
- libomp taken from the LLVM/Clang source distribution (to support OpenMP)
- jpeg
- zlib
- png
- Qt (for LAMMPS-GUI)
When configuring LAMMPS the `cmake/presets/clang.cmake` should be used
and as many packages as possible enabled. For LAMMPS-GUI, MPI should be
disabled with `-D BUILD_MPI=OFF` and LAMMPS-GUI enabled with
`-D BUILD_LAMMPS_GUI=ON`. If the CMake configuration is successful,
settings for building a macOS app-bundle are enabled and with `cmake
--build build --target dmg` extra steps will be executed that will build
a macOS application installer image under the name
`LAMMPS_GUI-macOS-multiarch-4Feb2025.dmg`
The application image can be uploaded to the GitHub release page with:
``` sh
ln -sf LAMMPS_GUI-macOS-multiarch-4Feb2025.dmg LAMMPS-macOS-multiarch-GUI-4Feb2025.dmg
gh release upload patch_4Feb2025 LAMMPS-macOS-multiarch-GUI-4Feb2025.dmg
```
The symbolic link is used to have a consistent naming scheme for the packages
attached to the GitHub release page.
We are currently building the application images on macOS 12 (aka Monterey).
#### Build Linux x86_64 binary tarball on Ubuntu 20.04LTS
While the flatpak Linux version uses portable runtime libraries provided
by the flatpak environment, we also build regular Linux executables that
use a wrapper script and matching shared libraries in a tarball. To be
compatible with many Linux distributions, one has to build this on a
very old Linux distribution, since most Linux system libraries are
usually backward compatible but not forward compatible. This is
currently done on an Ubuntu 20.04LTS system. Once LAMMPS moves to
require CMake 3.20 and C++17, we will have to move to Ubuntu 22.04LTS.
This installation (either on a real or a virtual machine) should have
the packages installed that are indicated in
`tools/singularity/ubuntu20.04.def` plus Qt version 5.x with development
headers, so that LAMMPS-GUI can be compiled.
Also the building of the binary tarball and setup of the bundled
libraries and wrapper scripts is automated and can executed with `cmake
--build build --target tgz`. This should produce a file
`LAMMPS_GUI-Linux-amd64-4Feb2025.tar.gz` which can be uploaded to the
GitHub release page with:
``` sh
ln -sf LAMMPS_GUI-Linux-amd64-4Feb2025.tar.gz LAMMPS-Linux-x86_64-GUI-4Feb2025.tar.gz
gh release upload patch_4Feb2025 LAMMPS-Linux-x86_64-GUI-4Feb2025.tar.gz
```
### Update download page on LAMMPS website
Check out the LAMMPS website repo
https://github.com/lammps/lammps-website.git and edit the file
@ -156,7 +286,7 @@ html` and review `html/download.html` Then add and commit to git and
push the changes to GitHub. The Temple Jenkis cluster will
automatically update https://www.lammps.org/download.html accordingly.
Notify Steve of the release so he can update `src/bug.txt` on the
Also notify Steve of the release so he can update `src/bug.txt` on the
website from the available release notes.
## LAMMPS Stable Release
@ -194,6 +324,47 @@ At this point it should be possible to do a fast-forward merge of
### Push branches and tags
## LAMMPS Stable Update Release
After making a stable release, bugfixes from the 'develop' branch
are selectively backported to the 'maintenance' branch. This is
done with "git cherry-pick \<commit hash\>' wherever possible.
The LAMMPS\_UPDATE define in "src/version.h" is set to "Maintenance".
### Prerequesites
When a sufficient number of bugfixes has accumulated or an urgent
or important bugfix needs to be distributed a new stable update
release is made. To make this publicly visible a pull request
is submitted that will merge 'maintenance' into 'stable'. Before
merging, set LAMMPS\_UPDATE in "src/version.h" to "Update #" with
"#" indicating the update count (1, 2, and so on).
Also draft suitable release notes under https://github.com/lammps/lammps/releases
### Fast-forward merge of 'maintenance' into 'stable', apply tag, and publish
Do a fast-forward merge of 'maintenance' to 'stable' and then
apply the stable\_DMmmYYYY\_update# tag and push branch and tag
to GitHub. The corresponding pull request will be automatically
closed. Example:
```
git checkout maintenance
git pull
git checkout stable
git pull
git merge --ff-only maintenance
git tag -s -m 'Update 2 for Stable LAMMPS version 29 August 2024' stable_29Aug2024_update2
git push git@github.com:lammps/lammps.git --tags maintenance stable
```
Associate draft release notes with new tag and publish as "latest release".
On https://ci.lammps.org/ go to "dev", "stable" and manually execute
the "update\_release" task. This will update https://docs.lammps.org/stable
and prepare a stable tarball.
### Build and upload binary packages and source tarball to GitHub
The build procedure is the same as for the feature releases, only
that packages are built from the 'stable' branch.

View File

@ -77,7 +77,7 @@ jobs:
-D PKG_MDI=on \
-D PKG_MANIFOLD=on \
-D PKG_ML-PACE=on \
-D PKG_ML-RANN=off \
-D PKG_ML-RANN=on \
-D PKG_MOLFILE=on \
-D PKG_RHEO=on \
-D PKG_PTM=on \

16
README
View File

@ -23,17 +23,21 @@ more information about the code and its uses.
The LAMMPS distribution includes the following files and directories:
README this file
LICENSE the GNU General Public License (GPL)
bench benchmark problems
LICENSE the GNU General Public License (GPLv2)
CITATION.cff Citation information for LAMMPS in CFF format
bench benchmark inputs
cmake CMake build files
doc documentation
examples simple test problems
fortran Fortran wrapper for LAMMPS
examples example inputs for many LAMMPS commands
fortran Fortran 2003 module for LAMMPS
lib additional provided or external libraries
potentials interatomic potential files
python Python wrappers for LAMMPS
python Python module for LAMMPS
src source files
third_party Copies of thirdparty software bundled with LAMMPS
tools pre- and post-processing tools
unittest test programs for use with CTest
.github Git and GitHub related files and tools
Point your browser at any of these files to get started:
@ -42,6 +46,8 @@ https://docs.lammps.org/Intro.html hi-level introduction
https://docs.lammps.org/Build.html how to build LAMMPS
https://docs.lammps.org/Run_head.html how to run LAMMPS
https://docs.lammps.org/Commands_all.html Table of available commands
https://docs.lammps.org/Howto.html Short tutorials and HowTo discussions
https://docs.lammps.org/Errors.html How to interpret and debug errors
https://docs.lammps.org/Library.html LAMMPS library interfaces
https://docs.lammps.org/Modify.html how to modify and extend LAMMPS
https://docs.lammps.org/Developer.html LAMMPS developer info

View File

@ -44,6 +44,7 @@ set(LAMMPS_DOC_DIR ${LAMMPS_DIR}/doc)
set(LAMMPS_TOOLS_DIR ${LAMMPS_DIR}/tools)
set(LAMMPS_PYTHON_DIR ${LAMMPS_DIR}/python)
set(LAMMPS_POTENTIALS_DIR ${LAMMPS_DIR}/potentials)
set(LAMMPS_THIRDPARTY_DIR ${LAMMPS_DIR}/third_party)
set(LAMMPS_DOWNLOADS_URL "https://download.lammps.org" CACHE STRING "Base URL for LAMMPS downloads")
set(LAMMPS_POTENTIALS_URL "${LAMMPS_DOWNLOADS_URL}/potentials")
@ -105,46 +106,33 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "Intel")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /Qrestrict")
endif()
if(CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 17.3 OR CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 17.4)
set(CMAKE_TUNE_DEFAULT "/QxCOMMON-AVX512")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /QxCOMMON-AVX512")
else()
set(CMAKE_TUNE_DEFAULT "/QxHost")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /QxHost")
endif()
else()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -restrict")
if(CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 17.3 OR CMAKE_CXX_COMPILER_VERSION VERSION_EQUAL 17.4)
set(CMAKE_TUNE_DEFAULT "-xCOMMON-AVX512")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -xCOMMON-AVX512")
else()
set(CMAKE_TUNE_DEFAULT "-xHost -fp-model fast=2 -no-prec-div -qoverride-limits -diag-disable=10441 -diag-disable=11074 -diag-disable=11076 -diag-disable=2196")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -xHost -fp-model fast=2 -no-prec-div -qoverride-limits -diag-disable=10441 -diag-disable=11074 -diag-disable=11076 -diag-disable=2196")
endif()
endif()
endif()
# silence excessive warnings for new Intel Compilers
if(CMAKE_CXX_COMPILER_ID STREQUAL "IntelLLVM")
set(CMAKE_TUNE_DEFAULT "-fp-model precise -Wno-tautological-constant-compare -Wno-unused-command-line-argument")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fp-model precise -Wno-tautological-constant-compare -Wno-unused-command-line-argument")
endif()
# silence excessive warnings for PGI/NVHPC compilers
if((CMAKE_CXX_COMPILER_ID STREQUAL "NVHPC") OR (CMAKE_CXX_COMPILER_ID STREQUAL "PGI"))
set(CMAKE_TUNE_DEFAULT "-Minform=severe")
endif()
# this hack is required to compile fmt lib with CrayClang version 15.0.2
# CrayClang is only directly recognized by version 3.28 and later
if(CMAKE_VERSION VERSION_LESS 3.28)
get_filename_component(_exe "${CMAKE_CXX_COMPILER}" NAME)
if((CMAKE_CXX_COMPILER_ID STREQUAL "Clang") AND (_exe STREQUAL "crayCC"))
set(CMAKE_TUNE_DEFAULT "-DFMT_STATIC_THOUSANDS_SEPARATOR")
endif()
else()
if(CMAKE_CXX_COMPILER_ID STREQUAL "CrayClang")
set(CMAKE_TUNE_DEFAULT "-DFMT_STATIC_THOUSANDS_SEPARATOR")
endif()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Minform=severe")
endif()
# silence nvcc warnings
if((PKG_KOKKOS) AND (Kokkos_ENABLE_CUDA) AND NOT (CMAKE_CXX_COMPILER_ID STREQUAL "Clang"))
set(CMAKE_TUNE_DEFAULT "${CMAKE_TUNE_DEFAULT}" "-Xcudafe --diag_suppress=unrecognized_pragma,--diag_suppress=128")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Xcudafe --diag_suppress=unrecognized_pragma,--diag_suppress=128")
endif()
# we *require* C++11 without extensions but prefer C++17.
@ -209,7 +197,7 @@ endif()
########################################################################
# User input options #
########################################################################
# backward compatibility with CMake before 3.12 and older LAMMPS documentation
# backward compatibility with older LAMMPS documentation
if (PYTHON_EXECUTABLE)
set(Python_EXECUTABLE "${PYTHON_EXECUTABLE}")
endif()
@ -225,6 +213,12 @@ if(DEFINED ENV{VIRTUAL_ENV} AND NOT Python_EXECUTABLE)
" Setting Python interpreter to: ${Python_EXECUTABLE}")
endif()
find_package(Python COMPONENTS Interpreter QUIET)
# NOTE: RHEL 8.0 and Ubuntu 18.04LTS ship with Python 3.6, Python 3.8 was EOL in 2024
if(Python_VERSION VERSION_LESS 3.6)
message(FATAL_ERROR "LAMMPS requires Python 3.6 or later")
endif()
set(LAMMPS_MACHINE "" CACHE STRING "Suffix to append to lmp binary (WON'T enable any features automatically")
mark_as_advanced(LAMMPS_MACHINE)
if(LAMMPS_MACHINE)
@ -377,6 +371,7 @@ endforeach()
# packages with special compiler needs or external libs
######################################################
target_include_directories(lammps PUBLIC $<BUILD_INTERFACE:${LAMMPS_SOURCE_DIR}>)
target_include_directories(lammps PUBLIC $<BUILD_INTERFACE:${LAMMPS_THIRDPARTY_DIR}>)
if(PKG_ADIOS)
# The search for ADIOS2 must come before MPI because
@ -425,8 +420,8 @@ else()
target_link_libraries(lammps PUBLIC mpi_stubs)
endif()
set(LAMMPS_SIZES "smallbig" CACHE STRING "LAMMPS integer sizes (smallsmall: all 32-bit, smallbig: 64-bit #atoms #timesteps, bigbig: also 64-bit imageint, 64-bit atom ids)")
set(LAMMPS_SIZES_VALUES smallbig bigbig smallsmall)
set(LAMMPS_SIZES "smallbig" CACHE STRING "LAMMPS integer sizes (smallbig: 64-bit #atoms #timesteps, bigbig: also 64-bit imageint, 64-bit atom ids)")
set(LAMMPS_SIZES_VALUES smallbig bigbig)
set_property(CACHE LAMMPS_SIZES PROPERTY STRINGS ${LAMMPS_SIZES_VALUES})
validate_option(LAMMPS_SIZES LAMMPS_SIZES_VALUES)
string(TOUPPER ${LAMMPS_SIZES} LAMMPS_SIZES)
@ -444,6 +439,19 @@ if(NOT ${LAMMPS_MEMALIGN} STREQUAL "0")
target_compile_definitions(lammps PRIVATE -DLAMMPS_MEMALIGN=${LAMMPS_MEMALIGN})
endif()
# this hack is required to compile fmt lib with CrayClang version 15.0.2
# CrayClang is only directly recognized by CMake version 3.28 and later
if(CMAKE_VERSION VERSION_LESS 3.28)
get_filename_component(_exe "${CMAKE_CXX_COMPILER}" NAME)
if((CMAKE_CXX_COMPILER_ID STREQUAL "Clang") AND (_exe STREQUAL "crayCC"))
target_compile_definitions(lammps PRIVATE -DFMT_STATIC_THOUSANDS_SEPARATOR)
endif()
else()
if(CMAKE_CXX_COMPILER_ID STREQUAL "CrayClang")
target_compile_definitions(lammps PRIVATE -DFMT_STATIC_THOUSANDS_SEPARATOR)
endif()
endif()
# "hard" dependencies between packages resulting
# in an error instead of skipping over files
pkg_depends(ML-IAP ML-SNAP)
@ -501,13 +509,13 @@ if(BUILD_OMP)
if(CMAKE_VERSION VERSION_LESS 3.28)
get_filename_component(_exe "${CMAKE_CXX_COMPILER}" NAME)
if((CMAKE_CXX_COMPILER_ID STREQUAL "Clang") AND (_exe STREQUAL "crayCC"))
set(CMAKE_SHARED_LINKER_FLAGS_${BTYPE} "${CMAKE_SHARED_LINKER_FLAGS_${BTYPE}} -fopenmp")
set(CMAKE_STATIC_LINKER_FLAGS_${BTYPE} "${CMAKE_STATIC_LINKER_FLAGS_${BTYPE}} -fopenmp")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fopenmp")
set(CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} -fopenmp")
endif()
else()
if(CMAKE_CXX_COMPILER_ID STREQUAL "CrayClang")
set(CMAKE_SHARED_LINKER_FLAGS_${BTYPE} "${CMAKE_SHARED_LINKER_FLAGS_${BTYPE}} -fopenmp")
set(CMAKE_STATIC_LINKER_FLAGS_${BTYPE} "${CMAKE_STATIC_LINKER_FLAGS_${BTYPE}} -fopenmp")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fopenmp")
set(CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} -fopenmp")
endif()
endif()
endif()
@ -622,10 +630,6 @@ if(WITH_SWIG)
add_subdirectory(${LAMMPS_SWIG_DIR} swig)
endif()
set(CMAKE_TUNE_FLAGS "${CMAKE_TUNE_DEFAULT}" CACHE STRING "Compiler and machine specific optimization flags (compilation only)")
separate_arguments(CMAKE_TUNE_FLAGS)
target_compile_options(lammps PRIVATE ${CMAKE_TUNE_FLAGS})
target_compile_options(lmp PRIVATE ${CMAKE_TUNE_FLAGS})
########################################################################
# Basic system tests (standard libraries, headers, functions, types) #
########################################################################
@ -930,7 +934,7 @@ endif()
include(Testing)
include(CodeCoverage)
include(CodingStandard)
find_package(ClangFormat 11.0)
find_package(ClangFormat 11.0 QUIET)
if(ClangFormat_FOUND)
add_custom_target(format-src

View File

@ -7,76 +7,76 @@
# For Python coverage the coverage package needs to be installed
###############################################################################
if(ENABLE_COVERAGE)
find_program(GCOVR_BINARY gcovr)
find_package_handle_standard_args(GCOVR DEFAULT_MSG GCOVR_BINARY)
find_program(GCOVR_BINARY gcovr)
find_package_handle_standard_args(GCOVR DEFAULT_MSG GCOVR_BINARY)
find_program(COVERAGE_BINARY coverage)
find_package_handle_standard_args(COVERAGE DEFAULT_MSG COVERAGE_BINARY)
find_program(COVERAGE_BINARY coverage)
find_package_handle_standard_args(COVERAGE DEFAULT_MSG COVERAGE_BINARY)
if(GCOVR_FOUND)
get_filename_component(ABSOLUTE_LAMMPS_SOURCE_DIR ${LAMMPS_SOURCE_DIR} ABSOLUTE)
if(GCOVR_FOUND)
get_filename_component(ABSOLUTE_LAMMPS_SOURCE_DIR ${LAMMPS_SOURCE_DIR} ABSOLUTE)
add_custom_target(
gen_coverage_xml
COMMAND ${GCOVR_BINARY} -s -x -r ${ABSOLUTE_LAMMPS_SOURCE_DIR} --object-directory=${CMAKE_BINARY_DIR} -o coverage.xml
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Generating XML coverage report..."
)
add_custom_target(
gen_coverage_xml
COMMAND ${GCOVR_BINARY} -s -x -r ${ABSOLUTE_LAMMPS_SOURCE_DIR} --object-directory=${CMAKE_BINARY_DIR} -o coverage.xml
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Generating XML coverage report..."
)
set(COVERAGE_HTML_DIR ${CMAKE_BINARY_DIR}/coverage_html)
set(COVERAGE_HTML_DIR ${CMAKE_BINARY_DIR}/coverage_html)
add_custom_target(coverage_html_folder
COMMAND ${CMAKE_COMMAND} -E make_directory ${COVERAGE_HTML_DIR})
add_custom_target(coverage_html_folder
COMMAND ${CMAKE_COMMAND} -E make_directory ${COVERAGE_HTML_DIR})
add_custom_target(
gen_coverage_html
COMMAND ${GCOVR_BINARY} -s --html --html-details -r ${ABSOLUTE_LAMMPS_SOURCE_DIR} --object-directory=${CMAKE_BINARY_DIR} -o ${COVERAGE_HTML_DIR}/index.html
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Generating HTML coverage report..."
)
add_dependencies(gen_coverage_html coverage_html_folder)
add_custom_target(
gen_coverage_html
COMMAND ${GCOVR_BINARY} -s --html --html-details -r ${ABSOLUTE_LAMMPS_SOURCE_DIR} --object-directory=${CMAKE_BINARY_DIR} -o ${COVERAGE_HTML_DIR}/index.html
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Generating HTML coverage report..."
)
add_dependencies(gen_coverage_html coverage_html_folder)
add_custom_target(clean_coverage_html
${CMAKE_COMMAND} -E remove_directory ${COVERAGE_HTML_DIR}
COMMENT "Deleting HTML coverage report..."
)
add_custom_target(clean_coverage_html
${CMAKE_COMMAND} -E remove_directory ${COVERAGE_HTML_DIR}
COMMENT "Deleting HTML coverage report..."
)
add_custom_target(reset_coverage
${CMAKE_COMMAND} -E remove -f */*.gcda */*/*.gcda */*/*/*.gcda
*/*/*/*/*.gcda */*/*/*/*/*.gcda */*/*/*/*/*/*.gcda
*/*/*/*/*/*/*/*.gcda */*/*/*/*/*/*/*/*.gcda
*/*/*/*/*/*/*/*/*/*.gcda */*/*/*/*/*/*/*/*/*/*.gcda
WORKIND_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Deleting coverage data files..."
)
add_dependencies(reset_coverage clean_coverage_html)
endif()
add_custom_target(reset_coverage
${CMAKE_COMMAND} -E remove -f */*.gcda */*/*.gcda */*/*/*.gcda
*/*/*/*/*.gcda */*/*/*/*/*.gcda */*/*/*/*/*/*.gcda
*/*/*/*/*/*/*/*.gcda */*/*/*/*/*/*/*/*.gcda
*/*/*/*/*/*/*/*/*/*.gcda */*/*/*/*/*/*/*/*/*/*.gcda
WORKIND_DIRECTORY ${CMAKE_BINARY_DIR}
COMMENT "Deleting coverage data files..."
)
add_dependencies(reset_coverage clean_coverage_html)
endif()
if(COVERAGE_FOUND)
set(PYTHON_COVERAGE_HTML_DIR ${CMAKE_BINARY_DIR}/python_coverage_html)
configure_file(.coveragerc.in ${CMAKE_BINARY_DIR}/.coveragerc @ONLY)
if(COVERAGE_FOUND)
set(PYTHON_COVERAGE_HTML_DIR ${CMAKE_BINARY_DIR}/python_coverage_html)
configure_file(.coveragerc.in ${CMAKE_BINARY_DIR}/.coveragerc @ONLY)
add_custom_command(
OUTPUT ${CMAKE_BINARY_DIR}/unittest/python/.coverage
COMMAND ${COVERAGE_BINARY} combine
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/unittest/python
COMMENT "Combine Python coverage files..."
)
add_custom_command(
OUTPUT ${CMAKE_BINARY_DIR}/unittest/python/.coverage
COMMAND ${COVERAGE_BINARY} combine
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/unittest/python
COMMENT "Combine Python coverage files..."
)
add_custom_target(
gen_python_coverage_html
COMMAND ${COVERAGE_BINARY} html --rcfile=${CMAKE_BINARY_DIR}/.coveragerc -d ${PYTHON_COVERAGE_HTML_DIR}
DEPENDS ${CMAKE_BINARY_DIR}/unittest/python/.coverage ${CMAKE_BINARY_DIR}/.coveragerc
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/unittest/python
COMMENT "Generating HTML Python coverage report..."
)
add_custom_target(
gen_python_coverage_html
COMMAND ${COVERAGE_BINARY} html --rcfile=${CMAKE_BINARY_DIR}/.coveragerc -d ${PYTHON_COVERAGE_HTML_DIR}
DEPENDS ${CMAKE_BINARY_DIR}/unittest/python/.coverage ${CMAKE_BINARY_DIR}/.coveragerc
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/unittest/python
COMMENT "Generating HTML Python coverage report..."
)
add_custom_target(
gen_python_coverage_xml
COMMAND ${COVERAGE_BINARY} xml --rcfile=${CMAKE_BINARY_DIR}/.coveragerc -o ${CMAKE_BINARY_DIR}/python_coverage.xml
DEPENDS ${CMAKE_BINARY_DIR}/unittest/python/.coverage ${CMAKE_BINARY_DIR}/.coveragerc
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/unittest/python
COMMENT "Generating XML Python coverage report..."
)
endif()
add_custom_target(
gen_python_coverage_xml
COMMAND ${COVERAGE_BINARY} xml --rcfile=${CMAKE_BINARY_DIR}/.coveragerc -o ${CMAKE_BINARY_DIR}/python_coverage.xml
DEPENDS ${CMAKE_BINARY_DIR}/unittest/python/.coverage ${CMAKE_BINARY_DIR}/.coveragerc
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/unittest/python
COMMENT "Generating XML Python coverage report..."
)
endif()
endif()

View File

@ -1,40 +1,39 @@
# use default (or custom) Python executable, if version is sufficient
if(Python_VERSION VERSION_GREATER_EQUAL 3.6)
# use default (or custom) Python executable.
# Python version check is in main CMakeLists.txt file
if(Python_EXECUTABLE)
set(Python3_EXECUTABLE ${Python_EXECUTABLE})
endif()
find_package(Python3 COMPONENTS Interpreter)
if(Python3_EXECUTABLE)
if(Python3_VERSION VERSION_GREATER_EQUAL 3.6)
add_custom_target(
check-whitespace
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/whitespace.py .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Check for whitespace errors")
add_custom_target(
check-homepage
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/homepage.py .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Check for homepage URL errors")
add_custom_target(
check-permissions
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/permissions.py .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Check for permission errors")
add_custom_target(
fix-whitespace
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/whitespace.py -f .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Fix whitespace errors")
add_custom_target(
fix-homepage
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/homepage.py -f .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Fix homepage URL errors")
add_custom_target(
fix-permissions
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/permissions.py -f .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Fix permission errors")
endif()
add_custom_target(
check-whitespace
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/whitespace.py .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Check for whitespace errors")
add_custom_target(
check-homepage
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/homepage.py .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Check for homepage URL errors")
add_custom_target(
check-permissions
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/permissions.py .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Check for permission errors")
add_custom_target(
fix-whitespace
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/whitespace.py -f .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Fix whitespace errors")
add_custom_target(
fix-homepage
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/homepage.py -f .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Fix homepage URL errors")
add_custom_target(
fix-permissions
${Python3_EXECUTABLE} ${LAMMPS_TOOLS_DIR}/coding_standard/permissions.py -f .
WORKING_DIRECTORY ${LAMMPS_DIR}
COMMENT "Fix permission errors")
endif()

View File

@ -13,7 +13,7 @@ if(BUILD_DOC)
endif()
find_package(Python3 REQUIRED COMPONENTS Interpreter)
if(Python3_VERSION VERSION_LESS 3.8)
message(FATAL_ERROR "Python 3.8 and up is required to build the HTML documentation")
message(FATAL_ERROR "Python 3.8 and up is required to build the LAMMPS HTML documentation")
endif()
set(VIRTUALENV ${Python3_EXECUTABLE} -m venv)
@ -65,8 +65,8 @@ if(BUILD_DOC)
find_package(Sphinx)
endif()
set(MATHJAX_URL "https://github.com/mathjax/MathJax/archive/3.1.3.tar.gz" CACHE STRING "URL for MathJax tarball")
set(MATHJAX_MD5 "b81661c6e6ba06278e6ae37b30b0c492" CACHE STRING "MD5 checksum of MathJax tarball")
set(MATHJAX_URL "https://github.com/mathjax/MathJax/archive/3.2.2.tar.gz" CACHE STRING "URL for MathJax tarball")
set(MATHJAX_MD5 "08dd6ef33ca08870220d9aade2a62845" CACHE STRING "MD5 checksum of MathJax tarball")
mark_as_advanced(MATHJAX_URL)
GetFallbackURL(MATHJAX_URL MATHJAX_FALLBACK)

View File

@ -34,8 +34,26 @@ if(MSVC)
add_compile_definitions(_CRT_SECURE_NO_WARNINGS)
endif()
# C++11 is required
set(CMAKE_CXX_STANDARD 11)
if(NOT CMAKE_CXX_STANDARD)
if(cxx_std_17 IN_LIST CMAKE_CXX_COMPILE_FEATURES)
set(CMAKE_CXX_STANDARD 17)
else()
set(CMAKE_CXX_STANDARD 11)
endif()
endif()
if(CMAKE_CXX_STANDARD LESS 11)
message(FATAL_ERROR "C++ standard must be set to at least 11")
endif()
if(CMAKE_CXX_STANDARD LESS 17)
message(WARNING "Selecting C++17 standard is preferred over C++${CMAKE_CXX_STANDARD}")
endif()
if(PKG_KOKKOS AND (CMAKE_CXX_STANDARD LESS 17))
set(CMAKE_CXX_STANDARD 17)
endif()
# turn off C++17 check in lmptype.h
if(LAMMPS_CXX11)
add_compile_definitions(LAMMPS_CXX11)
endif()
set(CMAKE_CXX_STANDARD_REQUIRED ON)
# Need -restrict with Intel compilers
@ -242,8 +260,8 @@ endif()
################
# integer size selection
set(LAMMPS_SIZES "smallbig" CACHE STRING "LAMMPS integer sizes (smallsmall: all 32-bit, smallbig: 64-bit #atoms #timesteps, bigbig: also 64-bit imageint, 64-bit atom ids)")
set(LAMMPS_SIZES_VALUES smallbig bigbig smallsmall)
set(LAMMPS_SIZES "smallbig" CACHE STRING "LAMMPS integer sizes (smallbig: 64-bit #atoms #timesteps, bigbig: also 64-bit imageint, 64-bit atom ids)")
set(LAMMPS_SIZES_VALUES smallbig bigbig)
set_property(CACHE LAMMPS_SIZES PROPERTY STRINGS ${LAMMPS_SIZES_VALUES})
validate_option(LAMMPS_SIZES LAMMPS_SIZES_VALUES)
string(TOUPPER ${LAMMPS_SIZES} LAMMPS_SIZES)

View File

@ -30,7 +30,7 @@ function(check_omp_h_include)
if(OpenMP_CXX_FOUND)
set(CMAKE_REQUIRED_FLAGS ${OpenMP_CXX_FLAGS})
set(CMAKE_REQUIRED_INCLUDES ${OpenMP_CXX_INCLUDE_DIRS})
set(CMAKE_REQUIRED_LINK_OPTIONS ${OpenMP_CXX_FLAGS})
separate_arguments(CMAKE_REQUIRED_LINK_OPTIONS NATIVE_COMMAND ${OpenMP_CXX_FLAGS}) # needs to be a list
set(CMAKE_REQUIRED_LIBRARIES ${OpenMP_CXX_LIBRARIES})
# there are all kinds of problems with finding omp.h
# for Clang and derived compilers so we pretend it is there.

View File

@ -14,10 +14,6 @@ endif()
add_library(colvars STATIC ${COLVARS_SOURCES})
target_compile_definitions(colvars PRIVATE -DCOLVARS_LAMMPS)
separate_arguments(CMAKE_TUNE_FLAGS)
foreach(_FLAG ${CMAKE_TUNE_FLAGS})
target_compile_options(colvars PRIVATE ${_FLAG})
endforeach()
set_target_properties(colvars PROPERTIES OUTPUT_NAME lammps_colvars${LAMMPS_MACHINE})
target_include_directories(colvars PUBLIC ${LAMMPS_LIB_SOURCE_DIR}/colvars)
# The line below is needed to locate math_eigen_impl.h

View File

@ -1,10 +1,18 @@
# the geturl command needs libcurl
find_package(CURL QUIET COMPONENTS HTTP HTTPS)
find_package(CURL QUIET)
option(WITH_CURL "Enable libcurl support" ${CURL_FOUND})
if(WITH_CURL)
find_package(CURL REQUIRED COMPONENTS HTTP HTTPS)
target_compile_definitions(lammps PRIVATE -DLAMMPS_CURL)
target_link_libraries(lammps PRIVATE CURL::libcurl)
# need to use pkgconfig for fully static bins to find custom static libs
if (CMAKE_SYSTEM_NAME STREQUAL "LinuxMUSL")
include(FindPkgConfig)
pkg_check_modules(CURL IMPORTED_TARGET libcurl libssl libcrypto)
target_link_libraries(lammps PUBLIC PkgConfig::CURL)
else()
find_package(CURL REQUIRED)
target_link_libraries(lammps PRIVATE CURL::libcurl)
endif()
endif()

View File

@ -57,8 +57,8 @@ if(DOWNLOAD_KOKKOS)
list(APPEND KOKKOS_LIB_BUILD_ARGS "-DCMAKE_CXX_EXTENSIONS=${CMAKE_CXX_EXTENSIONS}")
list(APPEND KOKKOS_LIB_BUILD_ARGS "-DCMAKE_TOOLCHAIN_FILE=${CMAKE_TOOLCHAIN_FILE}")
include(ExternalProject)
set(KOKKOS_URL "https://github.com/kokkos/kokkos/archive/4.5.01.tar.gz" CACHE STRING "URL for KOKKOS tarball")
set(KOKKOS_MD5 "4d832aa0284169d9e3fbae3165286bc6" CACHE STRING "MD5 checksum of KOKKOS tarball")
set(KOKKOS_URL "https://github.com/kokkos/kokkos/archive/4.6.00.tar.gz" CACHE STRING "URL for KOKKOS tarball")
set(KOKKOS_MD5 "61b2b69ae50d83eedcc7d47a3fa3d6cb" CACHE STRING "MD5 checksum of KOKKOS tarball")
mark_as_advanced(KOKKOS_URL)
mark_as_advanced(KOKKOS_MD5)
GetFallbackURL(KOKKOS_URL KOKKOS_FALLBACK)
@ -83,7 +83,7 @@ if(DOWNLOAD_KOKKOS)
add_dependencies(LAMMPS::KOKKOSCORE kokkos_build)
add_dependencies(LAMMPS::KOKKOSCONTAINERS kokkos_build)
elseif(EXTERNAL_KOKKOS)
find_package(Kokkos 4.5.01 REQUIRED CONFIG)
find_package(Kokkos 4.6.00 REQUIRED CONFIG)
target_link_libraries(lammps PRIVATE Kokkos::kokkos)
else()
set(LAMMPS_LIB_KOKKOS_SRC_DIR ${LAMMPS_LIB_SOURCE_DIR}/kokkos)

View File

@ -24,9 +24,7 @@ if(MLIAP_ENABLE_PYTHON)
if(NOT PKG_PYTHON)
message(FATAL_ERROR "Must enable PYTHON package for including Python support in ML-IAP")
endif()
if(Python_VERSION VERSION_LESS 3.6)
message(FATAL_ERROR "Python support in ML-IAP requires Python 3.6 or later")
endif()
# Python version check is in main CMakeLists.txt file
set(MLIAP_BINARY_DIR ${CMAKE_BINARY_DIR}/cython)
file(GLOB MLIAP_CYTHON_SRC CONFIGURE_DEPENDS ${LAMMPS_SOURCE_DIR}/ML-IAP/*.pyx)

View File

@ -37,7 +37,7 @@ if(DOWNLOAD_QUIP)
endforeach()
# Fix cmake crashing when MATH_LINKOPTS not set, required for e.g. recent Cray Programming Environment
set(temp "${temp} -L/_DUMMY_PATH_\n")
set(temp "${temp}PYTHON=python\nPIP=pip\nEXTRA_LINKOPTS=\n")
set(temp "${temp}PYTHON=${Python_EXECUTABLE}\nPIP=pip\nEXTRA_LINKOPTS=\n")
set(temp "${temp}HAVE_CP2K=0\nHAVE_VASP=0\nHAVE_TB=0\nHAVE_PRECON=1\nHAVE_LOTF=0\nHAVE_ONIOM=0\n")
set(temp "${temp}HAVE_LOCAL_E_MIX=0\nHAVE_QC=0\nHAVE_GAP=1\nHAVE_DESCRIPTORS_NONCOMMERCIAL=1\n")
set(temp "${temp}HAVE_TURBOGAP=0\nHAVE_QR=1\nHAVE_THIRDPARTY=0\nHAVE_FX=0\nHAVE_SCME=0\nHAVE_MTP=0\n")

View File

@ -40,6 +40,13 @@ mark_as_advanced(PLUMED_URL)
mark_as_advanced(PLUMED_MD5)
GetFallbackURL(PLUMED_URL PLUMED_FALLBACK)
# adjust C++ standard support for self-compiled Plumed2
if(CMAKE_CXX_STANDARD GREATER 11)
set(PLUMED_CXX_STANDARD 14)
else()
set(PLUMED_CXX_STANDARD 11)
endif()
if((CMAKE_SYSTEM_NAME STREQUAL "Windows") AND (CMAKE_CROSSCOMPILING))
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")
set(CROSS_CONFIGURE mingw64-configure)
@ -55,7 +62,7 @@ if((CMAKE_SYSTEM_NAME STREQUAL "Windows") AND (CMAKE_CROSSCOMPILING))
URL_MD5 ${PLUMED_MD5}
BUILD_IN_SOURCE 1
CONFIGURE_COMMAND ${CROSS_CONFIGURE} --disable-shared --disable-bsymbolic
--disable-python --enable-cxx=11
--disable-python --enable-cxx=${PLUMED_CXX_STANDARD}
--enable-modules=-adjmat:+crystallization:-dimred:+drr:+eds:-fisst:+funnel:+logmfd:+manyrestraints:+maze:+opes:+multicolvar:-pamm:-piv:+s2cm:-sasa:-ves
${PLUMED_CONFIG_OMP}
${PLUMED_CONFIG_MPI}
@ -142,7 +149,7 @@ else()
CONFIGURE_COMMAND <SOURCE_DIR>/configure --prefix=<INSTALL_DIR>
${CONFIGURE_REQUEST_PIC}
--enable-modules=all
--enable-cxx=11
--enable-cxx=${PLUMED_CXX_STANDARD}
--disable-python
${PLUMED_CONFIG_MPI}
${PLUMED_CONFIG_OMP}

View File

@ -1,6 +1,6 @@
if(NOT Python_INTERPRETER)
# backward compatibility with CMake before 3.12 and older LAMMPS documentation
# backward compatibility with older LAMMPS documentation
if(PYTHON_EXECUTABLE)
set(Python_EXECUTABLE ${PYTHON_EXECUTABLE})
endif()

View File

@ -1,6 +1,5 @@
# preset that enables KOKKOS and selects CUDA compilation with OpenMP
# enabled as well. This preselects CC 5.0 as default GPU arch, since
# that is compatible with all higher CC, but not the default CC 3.5
# enabled as well. The GPU architecture *must* match your hardware
set(PKG_KOKKOS ON CACHE BOOL "" FORCE)
set(Kokkos_ENABLE_SERIAL ON CACHE BOOL "" FORCE)
set(Kokkos_ENABLE_CUDA ON CACHE BOOL "" FORCE)

View File

@ -9,8 +9,7 @@ set(Kokkos_ARCH_VEGA90A on CACHE BOOL "" FORCE)
set(Kokkos_ENABLE_HIP_MULTIPLE_KERNEL_INSTANTIATIONS ON CACHE BOOL "" FORCE)
set(BUILD_OMP ON CACHE BOOL "" FORCE)
set(CMAKE_CXX_COMPILER hipcc CACHE STRING "" FORCE)
set(CMAKE_TUNE_FLAGS "-munsafe-fp-atomics" CACHE STRING "" FORCE)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -munsafe-fp-atomics" CACHE STRING "" FORCE)
# If KSPACE is also enabled, use CUFFT for FFTs
set(FFT_KOKKOS "HIPFFT" CACHE STRING "" FORCE)

View File

@ -21,9 +21,10 @@ set(CMAKE_C_COMPILER icx CACHE STRING "" FORCE)
set(CMAKE_Fortran_COMPILER "" CACHE STRING "" FORCE)
set(MPI_CXX_COMPILER "mpicxx" CACHE STRING "" FORCE)
set(CMAKE_CXX_STANDARD 17 CACHE STRING "" FORCE)
# Silence everything
set(CMAKE_CXX_FLAGS "-w" CACHE STRING "" FORCE)
# set(_intel_sycl_flags " -w -fsycl -flink-huge-device-code -fsycl-targets=spir64_gen "
set(_intel_sycl_flags " -w -fsycl -fsycl-device-code-split=per_kernel -fsycl-targets=spir64_gen ")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${_intel_sycl_flags}" CACHE STRING "" FORCE)
#set(CMAKE_EXE_LINKER_FLAGS "-fsycl -flink-huge-device-code -fsycl-targets=spir64_gen " CACHE STRING "" FORCE)
#set(CMAKE_TUNE_FLAGS "-O3 -fsycl -fsycl-device-code-split=per_kernel -fsycl-targets=spir64_gen" CACHE STRING "" FORCE)
set(CMAKE_EXE_LINKER_FLAGS "-fsycl -flink-huge-device-code " CACHE STRING "" FORCE)
set(CMAKE_TUNE_FLAGS "-O3 -fsycl -fsycl-device-code-split=per_kernel " CACHE STRING "" FORCE)
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fsycl -flink-huge-device-code " CACHE STRING "" FORCE)

View File

@ -14,5 +14,7 @@ set(Kokkos_ENABLE_DEPRECATION_WARNINGS OFF CACHE BOOL "" FORCE)
set(CMAKE_CXX_COMPILER clang++ CACHE STRING "" FORCE)
set(MPI_CXX_COMPILER "mpicxx" CACHE STRING "" FORCE)
set(CMAKE_CXX_STANDARD 17 CACHE STRING "" FORCE)
set(CMAKE_SHARED_LINKER_FLAGS "-Xsycl-target-frontend -O3" CACHE STRING "" FORCE)
set(CMAKE_TUNE_FLAGS "-fgpu-inline-threshold=100000 -Xsycl-target-frontend -O3 -Xsycl-target-frontend -ffp-contract=on -Wno-unknown-cuda-version" CACHE STRING "" FORCE)
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Xsycl-target-frontend -O3 " CACHE STRING "" FORCE)
set(_intel_sycl_flags "-fgpu-inline-threshold=100000 -Xsycl-target-frontend -O3 -Xsycl-target-frontend -ffp-contract=on -Wno-unknown-cuda-version")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${_intel_sycl_flags}" CACHE STRING "" FORCE)

View File

@ -91,7 +91,7 @@ endif()
set(DOWNLOAD_VORO ON CACHE BOOL "" FORCE)
set(DOWNLOAD_EIGEN3 ON CACHE BOOL "" FORCE)
set(LAMMPS_MEMALIGN "0" CACHE STRING "" FORCE)
set(CMAKE_TUNE_FLAGS "-Wno-missing-include-dirs" CACHE STRING "" FORCE)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-missing-include-dirs" CACHE STRING "" FORCE)
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--enable-stdcall-fixup,--as-needed,-lssp" CACHE STRING "" FORCE)
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--enable-stdcall-fixup,--as-needed,-lssp" CACHE STRING "" FORCE)
set(BUILD_TOOLS ON CACHE BOOL "" FORCE)

View File

@ -5,4 +5,4 @@ set(CMAKE_C_COMPILER "icx" CACHE STRING "" FORCE)
set(CMAKE_Fortran_COMPILER "ifx" CACHE STRING "" FORCE)
set(INTEL_LRT_MODE "C++11" CACHE STRING "" FORCE)
unset(HAVE_OMP_H_INCLUDE CACHE)
set(CMAKE_TUNE_FLAGS -Wno-unused-command-line-argument)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-unused-command-line-argument" CACHE STRING "" FORCE)

View File

@ -17,9 +17,11 @@ MATHJAXTAG = 3.2.2
PYTHON = $(word 3,$(shell type python3))
DOXYGEN = $(word 3,$(shell type doxygen))
PANDOC = $(word 3,$(shell type pandoc))
HAS_PYTHON3 = NO
HAS_DOXYGEN = NO
HAS_PDFLATEX = NO
HAS_PANDOC = NO
ifeq ($(shell type python3 >/dev/null 2>&1; echo $$?), 0)
HAS_PYTHON3 = YES
@ -31,10 +33,14 @@ endif
ifeq ($(shell type pdflatex >/dev/null 2>&1; echo $$?), 0)
ifeq ($(shell type latexmk >/dev/null 2>&1; echo $$?), 0)
HAS_PDFLATEX = YES
HAS_PDFLATEX = YES
endif
endif
ifeq ($(shell type pandoc >/dev/null 2>&1; echo $$?), 0)
HAS_PANDOC = YES
endif
# override settings for PIP commands
# PIP_OPTIONS = --cert /etc/pki/ca-trust/extracted/openssl/ca-bundle.trust.crt --proxy http://proxy.mydomain.org
@ -45,8 +51,9 @@ SPHINXEXTRA = -j $(shell $(PYTHON) -c 'import multiprocessing;print(multiprocess
# we only want to use explicitly listed files.
DOXYFILES = $(shell sed -n -e 's/\#.*$$//' -e '/^ *INPUT \+=/,/^[A-Z_]\+ \+=/p' doxygen/Doxyfile.in | sed -e 's/@LAMMPS_SOURCE_DIR@/..\/src/g' -e 's/\\//g' -e 's/ \+/ /' -e 's/[A-Z_]\+ \+= *\(YES\|NO\|\)//')
.PHONY: help clean-all clean clean-spelling epub mobi html pdf spelling anchor_check style_check char_check role_check xmlgen fasthtml
.PHONY: help clean-all clean clean-spelling epub mobi html pdf spelling anchor_check style_check char_check role_check xmlgen fasthtml fasthtml-init
FASTHTMLFILES = $(patsubst $(RSTDIR)/%.rst,fasthtml/%.html,$(wildcard $(RSTDIR)/*rst))
# ------------------------------------------
help:
@ -105,6 +112,8 @@ html: xmlgen globbed-tocs $(VENV) $(SPHINXCONFIG)/conf.py $(ANCHORCHECK) $(MATHJ
env LC_ALL=C grep -n ':\(ref\|doc\):[^`]' $(RSTDIR)/*.rst ;\
env LC_ALL=C grep -n '\(ref\|doc\)`[^`]' $(RSTDIR)/*.rst ;\
$(PYTHON) $(BUILDDIR)/utils/check-styles.py -s ../src -d src ;\
env LC_ALL=C grep -n -E '^ *\.\. [a-z0-9]+:(\s+.*|)$$' \
$(RSTDIR)/*.rst ../src/*.{cpp,h} ../src/*/*.{cpp,h} ;\
echo "############################################" ;\
deactivate ;\
)
@ -116,25 +125,23 @@ html: xmlgen globbed-tocs $(VENV) $(SPHINXCONFIG)/conf.py $(ANCHORCHECK) $(MATHJ
@rm -rf html/PDF/.[sg]*
@echo "Build finished. The HTML pages are in doc/html."
fasthtml: xmlgen globbed-tocs $(VENV) $(SPHINXCONFIG)/conf.py $(ANCHORCHECK) $(MATHJAX)
@if [ "$(HAS_BASH)" == "NO" ] ; then echo "bash was not found at $(OSHELL)! Please use: $(MAKE) SHELL=/path/to/bash" 1>&2; exit 1; fi
@$(MAKE) $(MFLAGS) -C graphviz all
@mkdir -p fasthtml
@(\
. $(VENV)/bin/activate ; env PYTHONWARNINGS= PYTHONDONTWRITEBYTECODE=1 \
sphinx-build $(SPHINXEXTRA) -b html -c $(SPHINXCONFIG) -d $(BUILDDIR)/fasthtml/doctrees $(RSTDIR) fasthtml ;\
touch $(RSTDIR)/Fortran.rst ; env PYTHONWARNINGS= PYTHONDONTWRITEBYTECODE=1 \
sphinx-build $(SPHINXEXTRA) -b html -c $(SPHINXCONFIG) -d $(BUILDDIR)/fasthtml/doctrees $(RSTDIR) fasthtml ;\
deactivate ;\
)
@rm -rf fasthtml/_sources
@rm -rf fasthtml/PDF
@rm -rf fasthtml/USER
@rm -rf fasthtml/JPG
@cp -r src/PDF fasthtml/PDF
@rm -rf fasthtml/PDF/.[sg]*
fasthtml: fasthtml-init $(FASTHTMLFILES)
@echo "Fast HTML build finished. The HTML pages are in doc/fasthtml."
fasthtml-init:
@mkdir -p fasthtml/JPG
@cp src/JPG/*.* fasthtml/JPG
@cp $(RSTDIR)/accel_styles.rst $(RSTDIR)/lepton_expression.rst fasthtml/
@cp $(BUILDDIR)/utils/pandoc.css fasthtml/
fasthtml/%.html: $(RSTDIR)/%.rst
@if [ "$(HAS_PANDOC)" == "NO" ] ; then echo "Make 'fasthtml' requires the 'pandoc' software" 1>&2; exit 1; fi
@mkdir -p fasthtml
@echo converting $< to $@
@sed -e 's/\\AA/\\mathring{\\mathrm{A}}/g' $< > fasthtml/$*.temp.rst
@pandoc -s --mathml --css="pandoc.css" --template=$(BUILDDIR)/utils/pandoc.html --metadata title="$@" -o $@ fasthtml/$*.temp.rst
@rm -f fasthtml/$*.temp.rst
spelling: xmlgen globbed-tocs $(SPHINXCONFIG)/conf.py $(VENV) $(SPHINXCONFIG)/false_positives.txt
@if [ "$(HAS_BASH)" == "NO" ] ; then echo "bash was not found at $(OSHELL)! Please use: $(MAKE) SHELL=/path/to/bash" 1>&2; exit 1; fi
@(\
@ -188,6 +195,8 @@ pdf: xmlgen globbed-tocs $(VENV) $(SPHINXCONFIG)/conf.py $(ANCHORCHECK)
env LC_ALL=C grep -n ':\(ref\|doc\):[^`]' $(RSTDIR)/*.rst ;\
env LC_ALL=C grep -n '\(ref\|doc\)`[^`]' $(RSTDIR)/*.rst ;\
$(PYTHON) utils/check-styles.py -s ../src -d src ;\
env LC_ALL=C grep -n -E '^ *\.\. [a-z0-9]+:(\s+.*|)$$' \
$(RSTDIR)/*.rst ../src/*.{cpp,h} ../src/*/*.{cpp,h} ;\
echo "############################################" ;\
deactivate ;\
)
@ -237,6 +246,8 @@ role_check :
@( env LC_ALL=C grep -n ' `[^`]\+<[a-z][^`]\+`[^_]' $(RSTDIR)/*.rst && exit 1 || : )
@( env LC_ALL=C grep -n ':\(ref\|doc\):[^`]' $(RSTDIR)/*.rst && exit 1 || : )
@( env LC_ALL=C grep -n '\(ref\|doc\)`[^`]' $(RSTDIR)/*.rst && exit 1 || : )
@( env LC_ALL=C grep -n -E '^ *\.\. [a-z0-9]+:(\s+.*|)$$' \
$(RSTDIR)/*.rst ../src/*.{cpp,h} ../src/*/*.{cpp,h} && exit 1 || : )
link_check : $(VENV) html
@(\

View File

@ -22,12 +22,12 @@ doxygen-warn.log logfile with warnings from running doxygen
and:
github-development-workflow.md notes on the LAMMPS development workflow
include-file-conventions.md notes on LAMMPS' include file conventions
documentation_conventions.md notes on writing documentation for LAMMPS
If you downloaded a LAMMPS tarball from www.lammps.org, then the html
folder and the PDF manual should be included. If you downloaded LAMMPS
from GitHub then you either need to build them.
using GitHub then you either need to build them yourself or read the
online version at https://docs.lammps.org/
You can build the HTML and PDF files yourself, by typing "make html"
or by "make pdf", respectively. This requires various tools and files.
@ -39,10 +39,10 @@ environment and local folders.
Installing prerequisites for the documentation build
To run the HTML documention build toolchain, python 3.x, doxygen, git,
and the venv python module have to be installed if not already available.
Also internet access is initially required to download external files
and tools.
To run the HTML documention build toolchain, python 3.8 or later,
doxygen 1.8.10 or later, git, and the venv python module have to be
installed if not already available. Also internet access is initially
required to download external files and tools.
Building the PDF format manual requires in addition a compatible LaTeX
installation with support for PDFLaTeX and several add-on LaTeX packages
@ -52,16 +52,24 @@ installed. This includes:
- babel
- capt-of
- cmap
- dvipng
- ellipse
- fncychap
- fontawesom
- framed
- geometry
- gyre
- hyperref
- hypcap
- needspace
- pict2e
- times
- tabulary
- titlesec
- upquote
- wrapfig
- xindy
Also the latexmk script is required to run PDFLaTeX and related tools.
the required number of times to have self-consistent output and include
updated bibliography and indices.

View File

@ -1,7 +1,7 @@
.TH LAMMPS "1" "4 February 2025" "2025-02-04"
.TH LAMMPS "1" "2 April 2025" "2025-04-02"
.SH NAME
.B LAMMPS
\- Molecular Dynamics Simulator. Version 4 February 2025
\- Molecular Dynamics Simulator. Version 2 April 2025
.SH SYNOPSIS
.B lmp

View File

@ -14,6 +14,29 @@ As an alternative, you can download a package with pre-built executables
or automated build trees, as described in the :doc:`Install <Install>`
section of the manual.
Prerequisites
-------------
Which software you need to compile and use LAMMPS strongly depends on
which :doc:`features and settings <Build_settings>` and which
:doc:`optional packages <Packages_list>` you are trying to include.
Common to all is that you need a C++ and C compiler, where the C++
compiler has to support at least the C++11 standard (note that some
compilers require command-line flag to activate C++11 support).
Furthermore, if you are building with CMake, you need at least CMake
version 3.20 and a compatible build tool (make or ninja-build); if you
are building the the legacy GNU make based build system you need GNU
make (other make variants are not going to work since the build system
uses features unique to GNU make) and a Unix-like build environment with
a Bourne shell, and shell tools like "sed", "grep", "touch", "test",
"tr", "cp", "mv", "rm", "ln", "diff" and so on. Parts of LAMMPS
interface with or use Python version 3.6 or later.
The LAMMPS developers aim to keep LAMMPS very portable and usable -
at least in parts - on most operating systems commonly used for
running MD simulations. Please see the :doc:`section on portablility
<Intro_portability>` for more details.
.. toctree::
:maxdepth: 1

View File

@ -212,11 +212,7 @@ LAMMPS.
You can tell CMake to look for a specific compiler with setting
CMake variables (listed below) during configuration. For a few
common choices, there are also presets in the ``cmake/presets``
folder. For convenience, there is a ``CMAKE_TUNE_FLAGS`` variable
that can be set to apply global compiler options (applied to
compilation only), to be used for adding compiler or host specific
optimization flags in addition to the "flags" variables listed
below. You may also specify the corresponding ``CMAKE_*_FLAGS``
folder. You may also specify the corresponding ``CMAKE_*_FLAGS``
variables individually, if you want to experiment with alternate
optimization flags. You should specify all 3 compilers, so that
the (few) LAMMPS source files written in C or Fortran are built
@ -266,10 +262,6 @@ LAMMPS.
``-C ../cmake/presets/pgi.cmake`` will switch the compiler to the PGI compilers,
and ``-C ../cmake/presets/nvhpc.cmake`` will switch to the NVHPC compilers.
Furthermore, you can set ``CMAKE_TUNE_FLAGS`` to specifically add
compiler flags to tune for optimal performance on given hosts.
This variable is empty by default.
.. note::
When the cmake command completes, it prints a summary to the

View File

@ -52,9 +52,9 @@ software or for people that want to modify or extend LAMMPS.
compilers can be configured and built concurrently from the same
source tree.
- Simplified packaging of LAMMPS for Linux distributions, environment
modules, or automated build tools like `Homebrew <https://brew.sh/>`_.
- Integration of automated unit and regression testing (the LAMMPS side
of this is still under active development).
modules, or automated build tools like `Spack <https://spack.io>`_
or `Homebrew <https://brew.sh/>`_.
- Integration of automated unit and regression testing.
.. _cmake_build:
@ -119,6 +119,13 @@ configured) and additional files like LAMMPS API headers, manpages,
potential and force field files. The location of the installation tree
defaults to ``${HOME}/.local``.
.. note::
If you have set `-D CMAKE_INSTALL_PREFIX` to install LAMMPS into a
system location on a Linux machine , you may also have to run (as
root) the `ldconfig` program to update the cache file for fast lookup
of system shared libraries.
.. _cmake_options:
Configuration and build options

View File

@ -255,11 +255,10 @@ Traditional make
Before building LAMMPS, you must build the GPU library in ``lib/gpu``\ .
You can do this manually if you prefer; follow the instructions in
``lib/gpu/README``. Note that the GPU library uses MPI calls, so you must
use the same MPI library (or the STUBS library) settings as the main
LAMMPS code. This also applies to the ``-DLAMMPS_BIGBIG``\ ,
``-DLAMMPS_SMALLBIG``\ , or ``-DLAMMPS_SMALLSMALL`` settings in whichever
Makefile you use.
``lib/gpu/README``. Note that the GPU library uses MPI calls, so you
must use the same MPI library (or the STUBS library) settings as the
main LAMMPS code. This also applies to the ``-DLAMMPS_BIGBIG`` or
``-DLAMMPS_SMALLBIG`` settings in whichever Makefile you use.
You can also build the library in one step from the ``lammps/src`` dir,
using a command like these, which simply invokes the ``lib/gpu/Install.py``
@ -612,6 +611,9 @@ They must be specified in uppercase.
* - ZEN3
- HOST
- AMD Zen3 architecture
* - ZEN4
- HOST
- AMD Zen4 architecture
* - RISCV_SG2042
- HOST
- SG2042 (RISC-V) CPUs
@ -715,7 +717,7 @@ They must be specified in uppercase.
- GPU
- Intel GPU Ponte Vecchio
This list was last updated for version 4.5.1 of the Kokkos library.
This list was last updated for version 4.6.0 of the Kokkos library.
.. tabs::
@ -1139,11 +1141,10 @@ POEMS package
PYTHON package
---------------------------
Building with the PYTHON package requires you have a the Python development
headers and library available on your system, which needs to be a Python 2.7
version or a Python 3.x version. Since support for Python 2.x has ended,
using Python 3.x is strongly recommended. See ``lib/python/README`` for
additional details.
Building with the PYTHON package requires you have a the Python
development headers and library available on your system, which
needs to be Python version 3.6 or later. See ``lib/python/README``
for additional details.
.. tabs::
@ -1159,7 +1160,7 @@ additional details.
set the Python_EXECUTABLE variable to specify which Python
interpreter should be used. Note note that you will also need to
have the development headers installed for this version,
e.g. python2-devel.
e.g. python3-devel.
.. tab:: Traditional make

View File

@ -30,9 +30,9 @@ additional tools to be available and functioning.
* A Bourne shell compatible "Unix" shell program (frequently this is ``bash``)
* A few shell utilities: ``ls``, ``mv``, ``ln``, ``rm``, ``grep``, ``sed``, ``tr``, ``cat``, ``touch``, ``diff``, ``dirname``
* Python (optional, required for ``make lib-<pkg>`` in the ``src``
folder). Python scripts are currently tested with python 2.7 and
3.6 to 3.11. The procedure for :doc:`building the documentation
<Build_manual>` *requires* Python 3.5 or later.
folder). Python scripts are currently tested with 3.6 to 3.11.
The procedure for :doc:`building the documentation <Build_manual>`
*requires* Python 3.8 or later.
Getting started
^^^^^^^^^^^^^^^

View File

@ -78,8 +78,7 @@ folder. The following ``make`` commands are available:
make epub # generate LAMMPS.epub in ePUB format using Sphinx
make mobi # generate LAMMPS.mobi in MOBI format using ebook-convert
make fasthtml # generate approximate HTML in fasthtml dir using Sphinx
# some Sphinx extensions do not work correctly with this
make fasthtml # generate approximate HTML in fasthtml dir using pandoc
make clean # remove intermediate RST files created by HTML build
make clean-all # remove entire build folder and any cached data
@ -116,9 +115,9 @@ environment variable.
Prerequisites for HTML
----------------------
To run the HTML documentation build toolchain, python 3, git, doxygen,
and virtualenv have to be installed locally. Here are instructions for
common setups:
To run the HTML documentation build toolchain, Python 3.8 or later, git,
doxygen, and virtualenv have to be installed locally. Here are
instructions for common setups:
.. tabs::
@ -128,13 +127,7 @@ common setups:
sudo apt-get install git doxygen
.. tab:: RHEL or CentOS (Version 7.x)
.. code-block:: bash
sudo yum install git doxygen
.. tab:: Fedora or RHEL/CentOS (8.x or later)
.. tab:: Fedora or RHEL/AlmaLinux/RockyLinux (8.x or later)
.. code-block:: bash
@ -154,7 +147,36 @@ Prerequisites for PDF
In addition to the tools needed for building the HTML format manual,
a working LaTeX installation with support for PDFLaTeX and a selection
of LaTeX styles/packages are required. To run the PDFLaTeX translation
of LaTeX styles/packages are required. Apart from LaTeX packages that
are usually installed by default, the following packages are required:
.. table_from_list::
:columns: 11
- amsmath
- anysize
- babel
- capt-of
- cmap
- dvipng
- ellipse
- fncychap
- fontawesome
- framed
- geometry
- gyre
- hyperref
- hypcap
- needspace
- pict2e
- times
- tabulary
- titlesec
- upquote
- wrapfig
- xindy
To run the PDFLaTeX translation
the ``latexmk`` script needs to be installed as well.
Prerequisites for ePUB and MOBI
@ -182,12 +204,42 @@ documentation is required and either existing files in the ``src``
folder need to be updated or new files added. These files are written in
`reStructuredText <rst_>`_ markup for translation with the Sphinx tool.
Testing your contribution
^^^^^^^^^^^^^^^^^^^^^^^^^
Before contributing any documentation, please check that both the HTML
and the PDF format documentation can translate without errors. During
testing the html translation, you may use the ``make fasthtml`` command
which does an approximate translation (i.e. not all Sphinx features and
extensions will work), but runs very fast because it will only translate
files that have been changed since the last ``make fasthtml`` command.
and the PDF format documentation can translate without errors and that
there are no spelling issues. This is done with ``make html``, ``make pdf``,
and ``make spelling``, respectively.
Fast and approximate translation to HTML
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Translating the full manual to HTML or PDF can take a long time. Thus
there is a fast and approximate way to translate the reStructuredText to
HTML as a quick-n-dirty way of checking your manual page.
This translation uses `Pandoc <https://pandoc.org>`_ instead of Sphinx
and thus all special Sphinx features (cross-references, advanced tables,
embedding of Python docstrings or doxygen documentation, and so on) will
not render correctly. Most embedded math should render correctly. This
is a **very fast** way to check the syntax and layout of a documentation
file translated to HTML while writing or updating it.
To translate **all** manual pages, you can type ``make fasthtml`` at the
command line. The translated HTML files are then in the ``fasthtml``
folder. All subsequent ``make fasthtml`` commands will only translate
``.rst`` files that have been changed. The ``make fasthtml`` command
can be parallelized with make using the `-j` flag. You can also
directly translate only individual pages: e.g. to translate only the
``doc/src/pair_lj.rst`` page type ``make fasthtml/pair_lj.html``
After writing the documentation is completed, you will still need
to verify with ``make html`` and ``make pdf`` that it translates
correctly in both formats.
Tests for consistency, completeness, and other known issues
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Please also check the output to the console for any warnings or problems. There will
be multiple tests run automatically:

View File

@ -8,29 +8,30 @@ Optional build settings
LAMMPS can be built with several optional settings. Each subsection
explains how to do this for building both with CMake and make.
* `C++11 standard compliance`_ when building all of LAMMPS
* `C++11 and C++17 standard compliance`_ when building all of LAMMPS
* `FFT library`_ for use with the :doc:`kspace_style pppm <kspace_style>` command
* `Size of LAMMPS integer types and size limits`_
* `Read or write compressed files`_
* `Output of JPEG, PNG, and movie files`_ via the :doc:`dump image <dump_image>` or :doc:`dump movie <dump_image>` commands
* `Support for downloading files`_
* `Support for downloading files from the input`_
* `Prevent download of large potential files`_
* `Memory allocation alignment`_
* `Workaround for long long integers`_
* `Exception handling when using LAMMPS as a library`_ to capture errors
* `Trigger selected floating-point exceptions`_
----------
.. _cxx11:
C++11 standard compliance
-------------------------
C++11 and C++17 standard compliance
-----------------------------------
A C++11 standard compatible compiler is a requirement for compiling LAMMPS.
LAMMPS version 3 March 2020 is the last version compatible with the previous
C++98 standard for the core code and most packages. Most currently used
C++ compilers are compatible with C++11, but some older ones may need extra
flags to enable C++11 compliance. Example for GNU c++ 4.8.x:
A C++11 standard compatible compiler is currently the minimum
requirement for compiling LAMMPS. LAMMPS version 3 March 2020 is the
last version compatible with the previous C++98 standard for the core
code and most packages. Most currently used C++ compilers are compatible
with C++11, but some older ones may need extra flags to enable C++11
compliance. Example for GNU c++ 4.8.x:
.. code-block:: make
@ -40,6 +41,17 @@ Individual packages may require compliance with a later C++ standard
like C++14 or C++17. These requirements will be documented with the
:doc:`individual packages <Packages_details>`.
.. versionchanged:: 4Feb2025
Starting with LAMMPS version 4 February 2025 we are starting a
transition to require the C++17 standard. Most current compilers are
compatible and if the C++17 standard is available by default, LAMMPS
will enable C++17 and will compile normally. If the chosen compiler is
not compatible with C++17, but only supports C++11, then the define
-DLAMMPS_CXX11 is required to fall back to compiling with a C++11
compiler. After the next stable release of LAMMPS in summer 2025, the
LAMMPS development branch and future releases will require C++17.
----------
.. _fft:
@ -303,7 +315,7 @@ large counters can become before "rolling over". The default setting of
.. code-block:: bash
-D LAMMPS_SIZES=value # smallbig (default) or bigbig or smallsmall
-D LAMMPS_SIZES=value # smallbig (default) or bigbig
If the variable is not set explicitly, "smallbig" is used.
@ -314,7 +326,7 @@ large counters can become before "rolling over". The default setting of
.. code-block:: make
LMP_INC = -DLAMMPS_SMALLBIG # or -DLAMMPS_BIGBIG or -DLAMMPS_SMALLSMALL
LMP_INC = -DLAMMPS_SMALLBIG # or -DLAMMPS_BIGBIG
The default setting is ``-DLAMMPS_SMALLBIG`` if nothing is specified
@ -323,34 +335,27 @@ LAMMPS system size restrictions
.. list-table::
:header-rows: 1
:widths: 18 27 28 27
:widths: 27 36 37
:align: center
* -
- smallbig
- bigbig
- smallsmall
* - Total atom count
- :math:`2^{63}` atoms (= :math:`9.223 \cdot 10^{18}`)
- :math:`2^{63}` atoms (= :math:`9.223 \cdot 10^{18}`)
- :math:`2^{31}` atoms (= :math:`2.147 \cdot 10^9`)
* - Total timesteps
- :math:`2^{63}` steps (= :math:`9.223 \cdot 10^{18}`)
- :math:`2^{63}` steps (= :math:`9.223 \cdot 10^{18}`)
- :math:`2^{31}` steps (= :math:`2.147 \cdot 10^9`)
* - Atom ID values
- :math:`1 \le i \le 2^{31} (= 2.147 \cdot 10^9)`
- :math:`1 \le i \le 2^{63} (= 9.223 \cdot 10^{18})`
- :math:`1 \le i \le 2^{31} (= 2.147 \cdot 10^9)`
* - Image flag values
- :math:`-512 \le i \le 511`
- :math:`- 1\,048\,576 \le i \le 1\,048\,575`
- :math:`-512 \le i \le 511`
The "bigbig" setting increases the size of image flags and atom IDs over
"smallbig" and the "smallsmall" setting is only needed if your machine
does not support 64-bit integers or incurs performance penalties when
using them.
the default "smallbig" setting.
These are limits for the core of the LAMMPS code, specific features or
some styles may impose additional limits. The :ref:`ATC
@ -504,8 +509,8 @@ during a run.
.. _libcurl:
Support for downloading files
-----------------------------
Support for downloading files from the input
--------------------------------------------
.. versionadded:: 29Aug2024
@ -548,6 +553,25 @@ LAMMPS is compiled accordingly which needs the following settings:
----------
.. _download_pot:
Prevent download of large potential files
-----------------------------------------
.. versionadded:: 8Feb2023
LAMMPS bundles a selection of potential files in the ``potentials``
folder as examples of how those kinds of potential files look like and
for use with the provided input examples in the ``examples`` tree. To
keep the size of the distributed LAMMPS source package small, very large
potential files (> 5 MBytes) are not bundled, but only downloaded on
demand when the :doc:`corresponding package <Packages_list>` is
installed. This automatic download can be prevented when :doc:`building
LAMMPS with CMake <Build_cmake>` by adding the setting `-D
DOWNLOAD_POTENTIALS=off` when configuring.
----------
.. _align:
Memory allocation alignment
@ -634,40 +658,3 @@ code has to be set up to *catch* exceptions thrown from within LAMMPS.
throw an exception and thus other MPI ranks may get stuck waiting for
messages from the ones with errors.
----------
.. _trap_fpe:
Trigger selected floating-point exceptions
------------------------------------------
Many kinds of CPUs have the capability to detect when a calculation
results in an invalid math operation, like a division by zero or calling
the square root with a negative argument. The default behavior on
most operating systems is to continue and have values for ``NaN`` (= not
a number) or ``Inf`` (= infinity). This allows software to detect and
recover from such conditions. This behavior can be changed, however,
often through use of compiler flags. On Linux systems (or more general
on systems using the GNU C library), these so-called floating-point traps
can also be selectively enabled through library calls. LAMMPS supports
that by setting the ``-DLAMMPS_TRAP_FPE`` pre-processor define. As it is
done in the ``main()`` function, this applies only to the standalone
executable, not the library.
.. tabs::
.. tab:: CMake build
.. code-block:: bash
-D CMAKE_TUNE_FLAGS=-DLAMMPS_TRAP_FPE
.. tab:: Traditional make
.. code-block:: make
LMP_INC = -DLAMMPS_TRAP_FPE <other LMP_INC settings>
After compilation with this flag set, the LAMMPS executable will stop
and produce a core dump when a division by zero, overflow, illegal math
function argument or other invalid floating point operation is encountered.

View File

@ -140,6 +140,7 @@ additional letter in parenthesis: k = KOKKOS.
* :doc:`plugin <plugin>`
* :doc:`prd <prd>`
* :doc:`python <python>`
* :doc:`region2vmd <region2vmd>`
* :doc:`tad <tad>`
* :doc:`temper <temper>`
* :doc:`temper/grem <temper_grem>`

View File

@ -23,6 +23,7 @@ OPT.
*
* :doc:`bpm/rotational <bond_bpm_rotational>`
* :doc:`bpm/spring <bond_bpm_spring>`
* :doc:`bpm/spring/plastic <bond_bpm_spring_plastic>`
* :doc:`class2 (ko) <bond_class2>`
* :doc:`fene (iko) <bond_fene>`
* :doc:`fene/expand (o) <bond_fene_expand>`
@ -127,7 +128,7 @@ OPT.
* :doc:`harmonic (iko) <dihedral_harmonic>`
* :doc:`helix (o) <dihedral_helix>`
* :doc:`lepton (o) <dihedral_lepton>`
* :doc:`multi/harmonic (o) <dihedral_multi_harmonic>`
* :doc:`multi/harmonic (ko) <dihedral_multi_harmonic>`
* :doc:`nharmonic (o) <dihedral_nharmonic>`
* :doc:`opls (iko) <dihedral_opls>`
* :doc:`quadratic (o) <dihedral_quadratic>`

View File

@ -178,6 +178,7 @@ KOKKOS, o = OPENMP, t = OPT.
* :doc:`ti <compute_ti>`
* :doc:`torque/chunk <compute_torque_chunk>`
* :doc:`vacf <compute_vacf>`
* :doc:`vacf/chunk <compute_vacf_chunk>`
* :doc:`vcm/chunk <compute_vcm_chunk>`
* :doc:`viscosity/cos <compute_viscosity_cos>`
* :doc:`voronoi/atom <compute_voronoi_atom>`

View File

@ -19,6 +19,7 @@ An alphabetic list of all LAMMPS :doc:`dump <dump>` commands.
* :doc:`custom/gz <dump>`
* :doc:`custom/zstd <dump>`
* :doc:`dcd <dump>`
* :doc:`extxyz <dump>`
* :doc:`grid <dump>`
* :doc:`grid/vtk <dump>`
* :doc:`h5md <dump_h5md>`

View File

@ -162,6 +162,8 @@ OPT.
* :doc:`phonon <fix_phonon>`
* :doc:`pimd/langevin <fix_pimd>`
* :doc:`pimd/nvt <fix_pimd>`
* :doc:`pimd/langevin/bosonic <fix_pimd>`
* :doc:`pimd/nvt/bosonic <fix_pimd>`
* :doc:`planeforce <fix_planeforce>`
* :doc:`plumed <fix_plumed>`
* :doc:`poems <fix_poems>`
@ -184,6 +186,7 @@ OPT.
* :doc:`qeq/fire <fix_qeq>`
* :doc:`qeq/point <fix_qeq>`
* :doc:`qeq/reaxff (ko) <fix_qeq_reaxff>`
* :doc:`qeq/rel/reaxff <fix_qeq_rel_reaxff>`
* :doc:`qeq/shielded <fix_qeq>`
* :doc:`qeq/slater <fix_qeq>`
* :doc:`qmmm <fix_qmmm>`

View File

@ -179,6 +179,7 @@ OPT.
* :doc:`lj/long/dipole/long <pair_dipole>`
* :doc:`lj/long/tip4p/long (o) <pair_lj_long>`
* :doc:`lj/mdf <pair_mdf>`
* :doc:`lj/pirani (o) <pair_lj_pirani>`
* :doc:`lj/relres (o) <pair_lj_relres>`
* :doc:`lj/spica (gko) <pair_spica>`
* :doc:`lj/spica/coul/long (gko) <pair_spica>`

View File

@ -1,7 +1,7 @@
Removed commands and packages
=============================
.. contents::
.. contents:: \
------
@ -170,6 +170,18 @@ performance characteristics on NVIDIA GPUs. Both, the KOKKOS
and the :ref:`GPU package <PKG-GPU>` are maintained
and allow running LAMMPS with GPU acceleration.
Compute atom/molecule
---------------------
.. deprecated:: 11 Dec2015
The atom/molecule command has been removed from LAMMPS since it was superseded
by the more general and extensible "chunk infrastructure". Here the system is
partitioned in one of many possible ways - including using molecule IDs -
through the :doc:`compute chunk/atom <compute_chunk_atom>` command and then
summing is done using :doc:`compute reduce/chunk <compute_reduce_chunk>` Please
refer to the :doc:`chunk HOWTO <Howto_chunk>` section for an overview.
Fix ave/spatial and fix ave/spatial/sphere
------------------------------------------

View File

@ -24,4 +24,5 @@ of time and requests from the LAMMPS user community.
Classes
Developer_platform
Developer_utils
Developer_internal
Developer_grid

View File

@ -0,0 +1,120 @@
Internal Styles
---------------
LAMMPS has a number of styles that are not meant to be used in an input
file and thus are not documented in the :doc:`LAMMPS command
documentation <Commands_all>`. The differentiation between user
commands and internal commands is through the case of the command name:
user commands and styles are all lower case, internal styles are all
upper case. Internal styles are not called from the input file, but
their classes are instantiated by other styles. Often they are
created by other styles to store internal data or to perform actions
regularly at specific steps of the simulation.
The paragraphs below document some of those styles that have general
utility and may be used to avoid redundant implementation.
DEPRECATED Styles
^^^^^^^^^^^^^^^^^
The styles called DEPRECATED (e.g. pair, bond, fix, compute, region, etc.)
have the purpose to inform users that a specific style has been removed
or renamed. This is achieved by creating an alias for the deprecated
style to the corresponding class. For example, the fix style DEPRECATED
is aliased to fix style ave/spatial and fix style ave/spatial/sphere with
the following code:
.. code-block:: c++
FixStyle(DEPRECATED,FixDeprecated);
FixStyle(ave/spatial,FixDeprecated);
FixStyle(ave/spatial/sphere,FixDeprecated);
The individual class will then determine based on the style name
what action to perform:
- inform that the style has been removed and what style replaces it, if any, and then error out
- inform that the style has been renamed and then either execute the replacement or error out
- inform that the style is no longer required, and it is thus ignored and continue
There is also a section in the user's guide for :doc:`removed commands
and packages <Commands_removed>` with additional explanations.
Internal fix styles
^^^^^^^^^^^^^^^^^^^
These provide an implementation of features that would otherwise have
been replicated across multiple styles. The used fix ID is generally
derived from the compute or fix ID creating the fix with some string
appended. When needed, the fix can be looked up with
``Modify::get_fix_by_id()``, which returns a pointer to the fix
instance. The data managed by the fix can be accessed just as for other
fixes that can be used in input files.
fix DUMMY
"""""""""
Most fix classes cannot be instantiated before the simulation box has
been created since they access data that is only available then.
However, in some cases it is required that a fix must be at or close to
the top of the list of all fixes. In those cases an instance of the
DUMMY fix style may be created by calling ``Modify::add_fix()`` and then
later replaced by the intended fix through calling ``Modify::replace_fix()``.
fix STORE/ATOM
""""""""""""""
Fix STORE/ATOM can be used as persistent storage of per-atom data.
**Syntax**
.. code-block:: LAMMPS
fix ID group-ID STORE/ATOM N1 N2 gflag rflag
* ID, group-ID are documented in :doc:`fix <fix>` command
* STORE/ATOM = style name of this fix command
* N1 = 1, N2 = 0 : data is per-atom vector = single value per atom
* N1 > 1, N2 = 0 : data is per-atom array = N1 values per atom
* N1 > 0, N2 > 0 : data is per-atom tensor = N1xN2 values per atom
* gflag = 1 communicate per-atom values with ghost atoms, 0 do not update ghost atom data
* rflag = 1 store per-atom value in restart file, 0 do not store data in restart
Similar functionality is also available through using custom per-atom
properties with :doc:`fix property/atom <fix_property_atom>`. The
choice between the two fixes should be based on whether the user should
be able to access this per-atom data: if yes, then fix property/atom is
preferred, otherwise fix STORE/ATOM.
fix STORE/GLOBAL
""""""""""""""""
Fix STORE/GLOBAL can be used as persistent storage of global data with support for restarts
**Syntax**
.. code-block:: LAMMPS
fix ID group-ID STORE/GLOBAL N1 N2
* ID, group-ID are documented in :doc:`fix <fix>` command
* STORE/GLOBAL = style name of this fix command
* N1 >=1 : number of global items to store
* N2 = 1 : data is global vector of length N1
* N2 > 1 : data is global N1xN2 array
fix STORE/LOCAL
"""""""""""""""
Fix STORE/LOCAL can be used as persistent storage for local data
**Syntax**
.. code-block:: LAMMPS
fix ID group-ID STORE/LOCAL Nreset Nvalues
* ID, group-ID are documented in :doc:`fix <fix>` command
* STORE/LOCAL = style name of this fix command
* Nreset = frequency at which local data is available
* Nvalues = number of values per local item, that is the number of columns

View File

@ -7,7 +7,7 @@ typically document what a variable stores, what a small section of
code does, or what a function does and its input/outputs. The topics
on this page are intended to document code functionality at a higher level.
.. contents::
.. contents:: Available notes
----

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,11 +1,15 @@
Warning messages
================
This is an alphabetic list of the WARNING messages LAMMPS prints out
and the reason why. If the explanation here is not sufficient, the
documentation for the offending command may help. Warning messages
also list the source file and line number where the warning was
generated. For example, a message like this:
This is an alphabetic list of some of the WARNING messages LAMMPS prints
out and the reason why. If the explanation here is not sufficient, the
documentation for the offending command may help. This is a historic
list and no longer updated. Instead the LAMMPS developers are trying
to provide more details right with the error message or link to a
paragraph with :doc:`detailed explanations <Errors_details>`.
Warning messages also list the source file and line number where the
warning was generated. For example, a message like this:
.. parsed-literal::
@ -14,7 +18,7 @@ generated. For example, a message like this:
means that line #187 in the file src/domain.cpp generated the error.
Looking in the source code may help you figure out what went wrong.
Doc page with :doc:`ERROR messages <Errors_messages>`
Please also see the page with :doc:`Error messages <Errors_messages>`
----------
@ -28,16 +32,10 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
cutoff is set too short or the angle has blown apart and an atom is
too far away.
*Angle style in data file differs from currently defined angle style*
Self-explanatory.
*Angles are defined but no angle style is set*
The topology contains angles, but there are no angle forces computed
since there was no angle_style command.
*Atom style in data file differs from currently defined atom style*
Self-explanatory.
*Bond atom missing in box size check*
The second atom needed to compute a particular bond is missing on this
processor. Typically this is because the pairwise cutoff is set too
@ -53,9 +51,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
processor. Typically this is because the pairwise cutoff is set too
short or the bond has blown apart and an atom is too far away.
*Bond style in data file differs from currently defined bond style*
Self-explanatory.
*Bonds are defined but no bond style is set*
The topology contains bonds, but there are no bond forces computed
since there was no bond_style command.
@ -68,9 +63,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
length, multiplying by the number of bonds in the interaction (e.g. 3
for a dihedral) and adding a small amount of stretch.
*Both groups in compute group/group have a net charge; the Kspace boundary correction to energy will be non-zero*
Self-explanatory.
*Calling write_dump before a full system init.*
The write_dump command is used before the system has been fully
initialized as part of a 'run' or 'minimize' command. Not all dump
@ -86,18 +78,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
This means the temperature associated with the rigid bodies may be
incorrect on this timestep.
*Cannot include log terms without 1/r terms; setting flagHI to 1*
Self-explanatory.
*Cannot include log terms without 1/r terms; setting flagHI to 1.*
Self-explanatory.
*Charges are set, but coulombic solver is not used*
Self-explanatory.
*Charges did not converge at step %ld: %lg*
Self-explanatory.
*Communication cutoff is 0.0. No ghost atoms will be generated. Atoms may get lost*
The communication cutoff defaults to the maximum of what is inferred from
pair and bond styles (will be zero, if none are defined) and what is specified
@ -123,9 +103,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
is not changed automatically and the warning may be ignored depending
on the specific system being simulated.
*Communication cutoff is too small for SNAP micro load balancing, increased to %lf*
Self-explanatory.
*Compute cna/atom cutoff may be too large to find ghost atom neighbors*
The neighbor cutoff used may not encompass enough ghost atoms
to perform this operation correctly.
@ -158,9 +135,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
Conformation of the 4 listed dihedral atoms is extreme; you may want
to check your simulation geometry.
*Dihedral style in data file differs from currently defined dihedral style*
Self-explanatory.
*Dihedrals are defined but no dihedral style is set*
The topology contains dihedrals, but there are no dihedral forces computed
since there was no dihedral_style command.
@ -177,9 +151,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
*Estimated error in splitting of dispersion coeffs is %g*
Error is greater than 0.0001 percent.
*Ewald/disp Newton solver failed, using old method to estimate g_ewald*
Self-explanatory. Choosing a different cutoff value may help.
*FENE bond too long*
A FENE bond has stretched dangerously far. It's interaction strength
will be truncated to attempt to prevent the bond from blowing up.
@ -192,9 +163,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
A FENE bond has stretched dangerously far. It's interaction strength
will be truncated to attempt to prevent the bond from blowing up.
*Fix halt condition for fix-id %s met on step %ld with value %g*
Self explanatory.
*Fix SRD walls overlap but fix srd overlap not set*
You likely want to set this in your input script.
@ -238,21 +206,12 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
*Fix property/atom mol or charge w/out ghost communication*
A model typically needs these properties defined for ghost atoms.
*Fix qeq CG convergence failed (%g) after %d iterations at %ld step*
Self-explanatory.
*Fix qeq has non-zero lower Taper radius cutoff*
Absolute value must be <= 0.01.
*Fix qeq has very low Taper radius cutoff*
Value should typically be >= 5.0.
*Fix qeq/dynamic tolerance may be too small for damped dynamics*
Self-explanatory.
*Fix qeq/fire tolerance may be too small for damped fires*
Self-explanatory.
*Fix rattle should come after all other integration fixes*
This fix is designed to work after all other integration fixes change
atom positions. Thus it should be the last integration fix specified.
@ -285,9 +244,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
The user-specified force accuracy cannot be achieved unless the table
feature is disabled by using 'pair_modify table 0'.
*Geometric mixing assumed for 1/r\^6 coefficients*
Self-explanatory.
*Group for fix_modify temp != fix group*
The fix_modify command is specifying a temperature computation that
computes a temperature on a different group of atoms than the fix
@ -310,46 +266,14 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
Conformation of the 4 listed improper atoms is extreme; you may want
to check your simulation geometry.
*Improper style in data file differs from currently defined improper style*
Self-explanatory.
*Impropers are defined but no improper style is set*
The topology contains impropers, but there are no improper forces computed
since there was no improper_style command.
*Inconsistent image flags*
The image flags for a pair on bonded atoms appear to be inconsistent.
Inconsistent means that when the coordinates of the two atoms are
unwrapped using the image flags, the two atoms are far apart.
Specifically they are further apart than half a periodic box length.
Or they are more than a box length apart in a non-periodic dimension.
This is usually due to the initial data file not having correct image
flags for the two atoms in a bond that straddles a periodic boundary.
They should be different by 1 in that case. This is a warning because
inconsistent image flags will not cause problems for dynamics or most
LAMMPS simulations. However they can cause problems when such atoms
are used with the fix rigid or replicate commands. Note that if you
have an infinite periodic crystal with bonds then it is impossible to
have fully consistent image flags, since some bonds will cross
periodic boundaries and connect two atoms with the same image
flag.
*Increasing communication cutoff for GPU style*
The pair style has increased the communication cutoff to be consistent with
the communication cutoff requirements for this pair style when run on the GPU.
*KIM Model does not provide 'energy'; Potential energy will be zero*
Self-explanatory.
*KIM Model does not provide 'forces'; Forces will be zero*
Self-explanatory.
*KIM Model does not provide 'particleEnergy'; energy per atom will be zero*
Self-explanatory.
*KIM Model does not provide 'particleVirial'; virial per atom will be zero*
Self-explanatory.
*Kspace_modify slab param < 2.0 may cause unphysical behavior*
The kspace_modify slab parameter should be larger to ensure periodic
grids padded with empty space do not overlap.
@ -401,20 +325,10 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
box, or moved further than one processor's subdomain away before
reneighboring.
*MSM mesh too small, increasing to 2 points in each direction*
Self-explanatory.
*Mismatch between velocity and compute groups*
The temperature computation used by the velocity command will not be
on the same group of atoms that velocities are being set for.
*Mixing forced for lj coefficients*
Self-explanatory.
*Molecule attributes do not match system attributes*
An attribute is specified (e.g. diameter, charge) that is
not defined for the specified atom style.
*Molecule has bond topology but no special bond settings*
This means the bonded atoms will not be excluded in pairwise
interactions.
@ -449,9 +363,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
*More than one compute damage/atom*
It is not efficient to use compute ke/atom more than once.
*More than one compute dilatation/atom*
Self-explanatory.
*More than one compute erotate/sphere/atom*
It is not efficient to use compute erorate/sphere/atom more than once.
@ -464,24 +375,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
*More than one compute orientorder/atom*
It is not efficient to use compute orientorder/atom more than once.
*More than one compute plasticity/atom*
Self-explanatory.
*More than one compute sna/atom*
Self-explanatory.
*More than one compute sna/grid*
Self-explanatory.
*More than one compute sna/grid/local*
Self-explanatory.
*More than one compute snad/atom*
Self-explanatory.
*More than one compute snav/atom*
Self-explanatory.
*More than one fix poems*
It is not efficient to use fix poems more than once.
@ -557,21 +450,12 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
*Pair COMB charge %.10f with force %.10f hit min barrier*
Something is possibly wrong with your model.
*Pair brownian needs newton pair on for momentum conservation*
Self-explanatory.
*Pair dpd needs newton pair on for momentum conservation*
Self-explanatory.
*Pair dsmc: num_of_collisions > number_of_A*
Collision model in DSMC is breaking down.
*Pair dsmc: num_of_collisions > number_of_B*
Collision model in DSMC is breaking down.
*Pair style in data file differs from currently defined pair style*
Self-explanatory.
*Pair style restartinfo set but has no restart support*
This pair style has a bug, where it does not support reading and
writing information to a restart file, but does not set the member
@ -681,9 +565,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
cluster specified by the fix shake command is numerically suspect. LAMMPS
will set it to 0.0 and continue.
*Shell command '%s' failed with error '%s'*
Self-explanatory.
*Shell command returned with non-zero status*
This may indicate the shell command did not operate as expected.
@ -694,15 +575,9 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
This will lead to invalid constraint forces in the SHAKE/RATTLE
computation.
*Simulations might be very slow because of large number of structure factors*
Self-explanatory.
*Slab correction not needed for MSM*
Slab correction is intended to be used with Ewald or PPPM and is not needed by MSM.
*Specifying an 'subset' value of '0' is equivalent to no 'subset' keyword*
Self-explanatory.
*System is not charge neutral, net charge = %g*
The total charge on all atoms on the system is not 0.0.
For some KSpace solvers this is only a warning.
@ -734,9 +609,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
assumed to also be for all atoms. Thus the pressure printed by thermo
could be inaccurate.
*The fix ave/spatial command has been replaced by the more flexible fix ave/chunk and compute chunk/atom commands -- fix ave/spatial will be removed in the summer of 2015*
Self-explanatory.
*The minimizer does not re-orient dipoles when using fix efield*
This means that only the atom coordinates will be minimized,
not the orientation of the dipoles.
@ -745,9 +617,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
More than the maximum # of neighbors was found multiple times. This
was unexpected.
*Too many inner timesteps in fix ttm*
Self-explanatory.
*Too many neighbors in CNA for %d atoms*
More than the maximum # of neighbors was found multiple times. This
was unexpected.
@ -775,24 +644,6 @@ Doc page with :doc:`ERROR messages <Errors_messages>`
The deformation will heat the SRD particles so this can
be dangerous.
*Using kspace solver on system with no charge*
Self-explanatory.
*Using largest cut-off for lj/long/dipole/long long long*
Self-explanatory.
*Using largest cutoff for buck/long/coul/long*
Self-explanatory.
*Using largest cutoff for lj/long/coul/long*
Self-explanatory.
*Using largest cutoff for pair_style lj/long/tip4p/long*
Self-explanatory.
*Using package gpu without any pair style defined*
Self-explanatory.
*Using pair potential shift with pair_modify compute no*
The shift effects will thus not be computed.

View File

@ -54,7 +54,7 @@ Lowercase directories
+-------------+------------------------------------------------------------------+
| body | body particles, 2d system |
+-------------+------------------------------------------------------------------+
| bpm | BPM simulations of pouring elastic grains and plate impact |
| bpm | simulations of solid elastic/plastic deformation and fracture |
+-------------+------------------------------------------------------------------+
| cmap | CMAP 5-body contributions to CHARMM force field |
+-------------+------------------------------------------------------------------+

View File

@ -2773,8 +2773,7 @@ Procedures Bound to the :f:type:`lammps` Derived Type
END SUBROUTINE external_callback
END INTERFACE
where ``c_bigint`` is ``c_int`` if ``-DLAMMPS_SMALLSMALL`` was used and
``c_int64_t`` otherwise; and ``c_tagint`` is ``c_int64_t`` if
where ``c_bigint`` is ``c_int64_t`` and ``c_tagint`` is ``c_int64_t`` if
``-DLAMMPS_BIGBIG`` was used and ``c_int`` otherwise.
The argument *caller* to :f:subr:`set_fix_external_callback` is unlimited

View File

@ -40,6 +40,7 @@ Settings howto
Howto_walls
Howto_nemd
Howto_dispersion
Howto_bulk2slab
Analysis howto
==============

View File

@ -42,12 +42,14 @@ such as those created by pouring grains using :doc:`fix pour
----------
Currently, there are two types of bonds included in the BPM package. The
Currently, there are three types of bonds included in the BPM package. The
first bond style, :doc:`bond bpm/spring <bond_bpm_spring>`, only applies
pairwise, central body forces. Point particles must have :doc:`bond atom
style <atom_style>` and may be thought of as nodes in a spring
network. An optional multibody term can be used to adjust the network's
Poisson's ratio. Alternatively, the second bond style, :doc:`bond bpm/rotational
Poisson's ratio. The :doc:`bpm/spring/plastic <bond_bpm_spring_plastic>`
bond style is similar except it adds a plastic yield strain.
Alternatively, the third bond style, :doc:`bond bpm/rotational
<bond_bpm_rotational>`, resolves tangential forces and torques arising
with the shearing, bending, and twisting of the bond due to rotation or
displacement of particles. Particles are similar to those used in the

160
doc/src/Howto_bulk2slab.rst Normal file
View File

@ -0,0 +1,160 @@
===========================
Convert bulk system to slab
===========================
A regularly encountered simulation problem is how to convert a bulk
system that has been run for a while to equilibrate into a slab system
with some vacuum space and free surfaces. The challenge here is that
one cannot just change the box dimensions with the :doc:`change_box
command <change_box>` or edit the box boundaries in a data file because
some atoms will have non-zero image flags from diffusing around.
Changing the box dimensions results in an undesired displacement of
those atoms, since the image flags indicate how many times the box
length in x-, y-, or z-direction needs to be added or subtracted to get
the "unwrapped" coordinates. By changing the box dimension this
distance is changed and thus those atoms move unphysically relative to
their neighbors with zero image flags. Setting image flags forcibly to
zero creates problems because that could break apart molecules by having
one atom of a bond on the top of the system and the other at the bottom.
.. _bulk2slab:
.. figure:: JPG/rhodo-both.jpg
:figwidth: 80%
:figclass: align-center
Snapshots of the bulk Rhodopsin in lipid layer and water system (right)
and the generated slab geometry (left)
.. admonition:: Disclaimer
:class: note
The following workflow will work for many bulk systems, but not all.
Some systems cannot be converted (e.g. polymers with bonds to the
same molecule across periodic boundaries, sometimes called "infinite
polymers"). The amount of vacuum that needs to be added depends on
the length of the molecules where the system is split (the example
here splits where there is water with short molecules). In some
cases, the system may need to be re-centered in the box first using
the :doc:`displace_atoms command <displace_atoms>`. Also, the time
spent on strong thermalization and equilibration will depend on the
specific system and its thermodynamic conditions.
Below is a suggested workflow using the :doc:`Rhodopsin benchmark input
<Speed_bench>` for demonstration. The figure shows the state *before*
the procedure on the left (with unwrapped atoms that have diffused out
of the box) and *after* on the right (with the vacuum added above and
below). The procedure is implemented by modifying a copy of the
``in.rhodo`` input file. The first lines up to and including the
:doc:`read_data command <read_data>` remain unchanged. Then we insert
the following lines to add vacuum to the z direction above and below the
system:
.. code-block:: LAMMPS
variable delta index 10.0
reset_atoms image all
write_dump all custom rhodo-unwrap.lammpstrj id xu yu zu
change_box all z final $(zlo-2.0*v_delta) $(zhi+2.0*v_delta) &
boundary p p f
read_dump rhodo-unwrap.lammpstrj 0 x y z box no replace yes
kspace_modify slab 3.0
Specifically, the :doc:`variable delta <variable>` (set to 10.0)
represents a distance that determines the amount of vacuum added: we add
twice its value in each direction to the z-dimension; thus in total
:math:`40 \AA` get added. The :doc:`reset_atoms image all
<reset_atoms>` command shall reset any image flags to become either 0 or
:math:`\pm 1` and thus have the minimum distance from the center of the
simulation box, but the correct relative distance for bonded atoms.
The :doc:`write_dump command <write_dump>` then writes out the resulting
*unwrapped* coordinates of the system. After expanding the box,
coordinates that were outside the box should now be inside and the
unwrapped coordinates will become "wrapped", while atoms outside the
periodic boundaries will be wrapped back into the box and their image
flags in those directions restored.
The :doc:`change_box command <change_box>` adds the desired
distance to the low and high box boundary in z-direction and then changes
the :doc:`boundary to "p p f" <boundary>` which will force the image
flags in z-direction to zero and create an undesired displacement for
the atoms with non-zero image flags.
With the :doc:`read_dump command <read_dump>` we read back and replace
partially incorrect coordinates with the previously saved, unwrapped
coordinates. It is important to ignore the box dimensions stored in the
dump file. We want to preserve the expanded box. Finally, we turn on
the slab correction for the PPPM long-range solver with the
:doc:`kspace_modify command <kspace_modify>` as required when using a
long range Coulomb solver for non-periodic z-dimension.
Next we replace the :doc:`fix npt command <fix_nh>` with:
.. code-block:: LAMMPS
fix 2 nvt temp 300.0 300.0 10.0
We now have an open system and thus the adjustment of the cell in
z-direction is no longer required. Since splitting the bulk water
region where the vacuum is inserted, creates surface atoms with high
potential energy, we reduce the thermostat time constant from 100.0 to
10.0 to remove excess kinetic energy resulting from that change faster.
Also the high potential energy of the surface atoms can cause that some
of them are ejected from the slab. In order to suppress that, we add
soft harmonic walls to push back any atoms that want to leave the slab.
To determine the position of the wall, we first need to to determine the
extent of the atoms in z-direction and then place the harmonic walls
based on that information:
.. code-block:: LAMMPS
compute zmin all reduce min z
compute zmax all reduce max z
thermo_style custom zlo c_zmin zhi c_zmax
run 0 post no
fix 3 all wall/harmonic zhi $(c_zmax+v_delta) 10.0 0.0 ${delta} &
zlo $(c_zmin-v_delta) 10.0 0.0 ${delta}
The two :doc:`compute reduce <compute_reduce>` command determine the
minimum and maximum z-coordinate across all atoms. In order to trigger
the execution of the compute commands we need to "consume" them. This
is done with the :doc:`thermo_style custom <thermo_style>` command
followed by the :doc:`run 0 <run>` command. This avoids and error
accessing the min/max values determined by the compute commands to
compute the location of the wall in lower and upper direction. This
uses the previously defined *delta* variable to determine the distance
of the wall from the extent of the system and the cutoff for the wall
interaction. This way only atoms that move beyond the min/max values in
z-direction will experience a restoring force, nudging them back to the
slab. The force constant of :math:`10.0 \frac{\mathrm{kcal/mol}}{\AA}`
was determined empirically.
Adding these "restoring" soft walls assist in making the free surfaces
above and below the slab flat, instead of having rugged or ondulated
surfaces. The impact of the walls can be changed by adjusting the force
constant, cutoff, and position of the wall.
Finally, we replace the :doc:`run 100 <run>` of the original input with:
.. code-block:: LAMMPS
run 1000 post no
unfix 3
fix 2 all nvt temp 300.0 300.0 100.0
run 1000 post no
write_data data.rhodo-slab
This runs the system converted to a slab first for 1000 MD steps using
the walls and stronger Nose-Hoover thermostat. Then the walls are
removed with :doc:`unfix 3 <unfix>` and the thermostat time constant
reset to 100.0 and the system run for another 1000 steps. Finally the
resulting slab geometry is written to a new data file
``data.rhodo-slab`` with a :doc:`write_data command <write_data>`. The
number of MD steps required to reach a proper equilibrium state is very
likely larger. The number of 1000 steps (corresponding to 2
picoseconds) was chosen for demonstration purposes, so that the
procedure can be easily and quickly tested.

View File

@ -285,7 +285,7 @@ when used before the CMake directory, there may be a space between the
can have boolean values (on/off, yes/no, or 1/0 are all valid) or are
strings representing a choice, or a path, or are free format. If the
string would contain whitespace, it must be put in quotes, for example
``-D CMAKE_TUNE_FLAGS="-ftree-vectorize -ffast-math"``.
``-D CMAKE_CXX_FLAGS="-O3 -Wall -ftree-vectorize -ffast-math"``.
CMake variables fall into two categories: 1) common CMake variables that
are used by default for any CMake configuration setup and 2) project
@ -341,8 +341,6 @@ Some common LAMMPS specific variables
- compile some additional executables from the ``tools`` folder (default: ``off``)
* - ``BUILD_DOC``
- include building the HTML format documentation for packaging/installing (default: ``off``)
* - ``CMAKE_TUNE_FLAGS``
- common compiler flags, for optimization or instrumentation (default:)
* - ``LAMMPS_MACHINE``
- when set to ``name`` the LAMMPS executable and library will be called ``lmp_name`` and ``liblammps_name.a``
* - ``FFT``

View File

@ -487,10 +487,10 @@ updates are back-ported from the *develop* branch to the *maintenance*
branch and occasionally merged to *stable* as an update release.
Furthermore, the naming of the release tags now follow the pattern
"patch_<Day><Month><Year>" to simplify comparisons between releases.
For stable releases additional "stable_<Day><Month><Year>" tags are
"patch\_<Day><Month><Year>" to simplify comparisons between releases.
For stable releases additional "stable\_<Day><Month><Year>" tags are
applied and update releases are tagged with
"stable_<Day><Month><Year>_update<Number>", Finally, all releases and
"stable\_<Day><Month><Year>\_update<Number>", Finally, all releases and
submissions are subject to automatic testing and code checks to make
sure they compile with a variety of compilers and popular operating
systems. Some unit and regression testing is applied as well.
@ -498,3 +498,7 @@ systems. Some unit and regression testing is applied as well.
A detailed discussion of the LAMMPS developer GitHub workflow can be
found in the file `doc/github-development-workflow.md
<https://github.com/lammps/lammps/blob/develop/doc/github-development-workflow.md>`_
.. raw:: latex
\clearpage

View File

@ -1,35 +1,25 @@
Using LAMMPS-GUI
================
LAMMPS-GUI is a graphical text editor programmed using the `Qt Framework
<https://www.qt.io/>`_ and customized for editing LAMMPS input files. It
is linked to the :ref:`LAMMPS library <lammps_c_api>` and thus can run
LAMMPS directly using the contents of the editor's text buffer as input.
It *differs* from other known interfaces to LAMMPS in that it can
retrieve and display information from LAMMPS *while it is running*,
display visualizations created with the :doc:`dump image command
<dump_image>`, can launch the online LAMMPS documentation for known
LAMMPS commands and styles, and directly integrates with a collection
of LAMMPS tutorials (:ref:`Gravelle1 <Gravelle1>`).
This document describes **LAMMPS-GUI version 1.6**.
-----
LAMMPS-GUI is a graphical text editor customized for editing LAMMPS
input files that is linked to the :ref:`LAMMPS library <lammps_c_api>`
and thus can run LAMMPS directly using the contents of the editor's text
buffer as input. It can retrieve and display information from LAMMPS
while it is running, display visualizations created with the :doc:`dump
image command <dump_image>`, and is adapted specifically for editing
LAMMPS input files through text completion and reformatting, and linking
to the online LAMMPS documentation for known LAMMPS commands and styles.
.. contents::
.. note::
Pre-compiled, ready-to-use LAMMPS-GUI executables for Linux x86\_64
(Ubuntu 20.04LTS or later and compatible), macOS (version 11 aka Big
Sur or later), and Windows (version 10 or later) :ref:`are available
<lammps_gui_install>` for download. Non-MPI LAMMPS executables (as
``lmp``) for running LAMMPS from the command-line and :doc:`some
LAMMPS tools <Tools>` compiled executables are also included.
Also, the pre-compiled LAMMPS-GUI packages include the WHAM executables
from http://membrane.urmc.rochester.edu/content/wham/ for use with
LAMMPS tutorials.
The source code for LAMMPS-GUI is included in the LAMMPS source code
distribution and can be found in the ``tools/lammps-gui`` folder. It
can be compiled alongside LAMMPS when :doc:`compiling with CMake
<Build_cmake>`.
----
LAMMPS-GUI tries to provide an experience similar to what people
traditionally would have running LAMMPS using a command-line window and
@ -64,8 +54,8 @@ simple LAMMPS simulations. It is very suitable for tutorials on LAMMPS
since you only need to learn how to use a single program for most tasks
and thus time can be saved and people can focus on learning LAMMPS.
The tutorials at https://lammpstutorials.github.io/ are specifically
updated for use with LAMMPS-GUI and can their tutorial materials can
be downloaded and loaded directly from the GUI.
updated for use with LAMMPS-GUI and their tutorial materials can
be downloaded and edited directly from the GUI.
Another design goal is to keep the barrier low when replacing part of
the functionality of LAMMPS-GUI with external tools. That said, LAMMPS-GUI
@ -78,10 +68,31 @@ has some unique functionality that is not found elsewhere:
- monitoring of simulation progress
- interactive visualization using the :doc:`dump image <dump_image>`
command with the option to copy-paste the resulting settings
- automatic slide show generation from dump image out at runtime
- automatic plotting of thermodynamics data at runtime
- automatic slide show generation from dump image output at runtime
- automatic plotting of thermodynamic data at runtime
- inspection of binary restart files
.. admonition:: Download LAMMPS-GUI for your platform
:class: Hint
Pre-compiled, ready-to-use LAMMPS-GUI executables for Linux x86\_64
(Ubuntu 20.04LTS or later and compatible), macOS (version 11 aka Big
Sur or later), and Windows (version 10 or later) :ref:`are available
<lammps_gui_install>` for download. Non-MPI LAMMPS executables (as
``lmp``) for running LAMMPS from the command-line and :doc:`some
LAMMPS tools <Tools>` compiled executables are also included. Also,
the pre-compiled LAMMPS-GUI packages include the WHAM executables
from http://membrane.urmc.rochester.edu/content/wham/ for use with
LAMMPS tutorials documented in this paper (:ref:`Gravelle1
<Gravelle1>`).
The source code for LAMMPS-GUI is included in the LAMMPS source code
distribution and can be found in the ``tools/lammps-gui`` folder. It
can be compiled alongside LAMMPS when :doc:`compiling with CMake
<Build_cmake>`.
-----
The following text provides a detailed tour of the features and
functionality of LAMMPS-GUI. Suggestions for new features and
reports of bugs are always welcome. You can use the :doc:`the same
@ -92,9 +103,12 @@ channels as for LAMMPS itself <Errors_bugs>` for that purpose.
Installing Pre-compiled LAMMPS-GUI Packages
-------------------------------------------
LAMMPS-GUI is available as pre-compiled binary packages for Linux
x86\_64, macOS 11 and later, and Windows 10 and later. Alternately, it
can be compiled from source.
LAMMPS-GUI is available for download as pre-compiled binary packages for
Linux x86\_64 (Ubuntu 20.04LTS or later and compatible), macOS (version
11 aka Big Sur or later), and Windows (version 10 or later) from the
`LAMMPS release pages on GitHub <https://github.com/lammps/lammps/releases/>`_.
A backup download location is at https://download.lammps.org/static/
Alternately, LAMMPS-GUI can be compiled from source when building LAMMPS.
Windows 10 and later
^^^^^^^^^^^^^^^^^^^^
@ -349,8 +363,13 @@ data or both. The smoothing uses a `Savitzky-Golay convolution filter
window width (left) and order (right) parameters can be set in the boxes
next to the drop down menu. Default settings are 10 and 4 which means
that the smoothing window includes 10 points each to the left and the
right of the current data point and a fourth order polynomial is fit to
the data in the window.
right of the current data point for a total of 21 points and a fourth
order polynomial is fitted to the data in the window.
The "Title:" and "Y:" input boxes allow to edit the text shown as the
plot title and the y-axis label, respectively. The text entered in the
"Title:" box is applied to *all* charts, while the "Y:" text changes
only the y-axis label of the currently *selected* plot.
You can use the mouse to zoom into the graph (hold the left button and
drag to mark an area) or zoom out (right click) and you can reset the
@ -382,6 +401,11 @@ here you get the compounded data set starting with the last change of
output fields or timestep setting, while the export from the log will
contain *all* YAML output but *segmented* into individual runs.
The *Preferences* dialog has a *Charts* tab, where you can configure
multiple chart-related settings, like the default title, colors for the
graphs, default choice of the raw / smooth graph selection, and the
default chart graph size.
Image Slide Show
----------------
@ -461,11 +485,11 @@ correspond to (via their mass) and then colorize them in the image and
set their atom diameters accordingly. If this is not possible, for
instance when using reduced (= 'lj') :doc:`units <units>`, then
LAMMPS-GUI will check the current pair style and if it is a
Lennard-Jones type potential, it will extract the *sigma* parameter
for each atom type and assign atom diameters from those numbers.
For cases where atom diameters are not auto-detected, the *Atom size* field
can be edited and a suitable value set manually. The default value
is inferred from the x-direction lattice spacing.
Lennard-Jones type potential, it will extract the *sigma* parameter for
each atom type and assign atom diameters from those numbers. For cases
where atom diameters are not auto-detected, the *Atom size* field can be
edited and a suitable value set manually. The default value is inferred
from the x-direction lattice spacing.
If elements cannot be detected the default sequence of colors of the
:doc:`dump image <dump_image>` command is assigned to the different atom
@ -480,22 +504,31 @@ types.
|gui-image1| |gui-image2|
The default image size, some default image quality settings, the view
style and some colors can be changed in the *Preferences* dialog
window. From the image viewer window further adjustments can be made:
actual image size, high-quality (SSAO) rendering, anti-aliasing, view
style, display of box or axes, zoom factor. The view of the system can
be rotated horizontally and vertically. It is also possible to only
display the atoms within a group defined in the input script (default is
"all"). The image can also be re-centered on the center of mass of the
selected group. After each change, the image is rendered again and the
display updated. The small palette icon on the top left is colored
while LAMMPS is running to render the new image; it is grayed out when
LAMMPS is finished. When there are many atoms to render and high
quality images with anti-aliasing are requested, re-rendering may take
several seconds. From the *File* menu of the image window, the
current image can be saved to a file (keyboard shortcut `Ctrl-S`) or
copied to the clipboard (keyboard shortcut `Ctrl-C`) for pasting the
image into another application.
style and some colors can be changed in the *Preferences* dialog window.
From the image viewer window further adjustments can be made: actual
image size, high-quality (SSAO) rendering, anti-aliasing, view style,
display of box or axes, zoom factor. The view of the system can be
rotated horizontally and vertically.
It is also possible to display only the atoms within a :doc:`group
defined in the input script <group>` (default is "all"). The available
groups can be selected from the drop down list next to the "Group:"
label. Similarly, if there are :doc:`molecules defined in the input
<molecule>`, it is possible to select one of them (default is "none")
and visualize it (it will be shown at the center of the simulation box).
While a molecule is selected, the group selection is disabled. It can
be restored by selecting the molecule "none".
The image can also be re-centered on the center of mass of the selected
group. After each change, the image is rendered again and the display
updated. The small palette icon on the top left is colored while LAMMPS
is running to render the new image; it is grayed out when LAMMPS is
finished. When there are many atoms to render and high quality images
with anti-aliasing are requested, re-rendering may take several seconds.
From the *File* menu of the image window, the current image can be saved
to a file (keyboard shortcut `Ctrl-S`) or copied to the clipboard
(keyboard shortcut `Ctrl-C`) for pasting the image into another
application.
From the *File* menu it is also possible to copy the current
:doc:`dump image <dump_image>` and :doc:`dump_modify <dump_image>`
@ -720,6 +753,22 @@ output, charts, slide show, variables, or snapshot images. The
default settings for their visibility can be changed in the
*Preferences* dialog.
Tutorials
^^^^^^^^^
The *Tutorials* menu is to support the set of LAMMPS tutorials for
beginners and intermediate LAMMPS users documented in (:ref:`Gravelle1
<Gravelle1>`). From the drop down menu you can select which of the
eight currently available tutorial sessions you want to begin. This
opens a 'wizard' dialog where you can choose in which folder you want to
work, whether you want that folder to be wiped from *any* files, whether
you want to download the solutions files (which can be large) to a
``solution`` sub-folder, and whether you want the corresponding
tutorial's online version opened in your web browser. The dialog will
then start downloading the files requested (download progress is
reported in the status line) and load the first input file for the
selected session into LAMMPS-GUI.
About
^^^^^
@ -783,18 +832,21 @@ look of LAMMPS-GUI. The settings are grouped and each group is
displayed within a tab.
.. |guiprefs1| image:: JPG/lammps-gui-prefs-general.png
:width: 24%
:width: 19%
.. |guiprefs2| image:: JPG/lammps-gui-prefs-accel.png
:width: 24%
:width: 19%
.. |guiprefs3| image:: JPG/lammps-gui-prefs-image.png
:width: 24%
:width: 19%
.. |guiprefs4| image:: JPG/lammps-gui-prefs-editor.png
:width: 24%
:width: 19%
|guiprefs1| |guiprefs2| |guiprefs3| |guiprefs4|
.. |guiprefs5| image:: JPG/lammps-gui-prefs-charts.png
:width: 19%
|guiprefs1| |guiprefs2| |guiprefs3| |guiprefs4| |guiprefs5|
General Settings:
^^^^^^^^^^^^^^^^^
@ -848,6 +900,11 @@ General Settings:
the plots in the *Charts* window in milliseconds. The default is to
redraw the plots every 500 milliseconds. This is just for the drawing,
data collection is managed with the previous setting.
- *HTTPS proxy setting:* Allows to enter a URL for an HTTPS proxy. This
may be needed when the LAMMPS input contains :doc:`geturl commands <geturl>`
or for downloading tutorial files from the *Tutorials* menu. If the
``https_proxy`` environment variable was set externally, its value is
displayed but cannot be changed.
Accelerators:
^^^^^^^^^^^^^
@ -884,7 +941,7 @@ lists to select the background and box colors.
Editor Settings:
^^^^^^^^^^^^^^^^
This tab allows tweaking settings of the editor window. Specifically
This tab allows tweaking settings of the editor window. Specifically,
the amount of padding to be added to LAMMPS commands, types or type
ranges, IDs (e.g. for fixes), and names (e.g. for groups). The value
set is the minimum width for the text element and it can be chosen in
@ -896,6 +953,16 @@ the completion pop-up window, and whether auto-save mode is enabled.
In auto-save mode the editor buffer is saved before a run or before
exiting LAMMPS-GUI.
Charts Settings:
----------------
This tab allows tweaking settings of the *Charts* window. Specifically,
one can set the default chart title (if the title contains '%f' it will
be replaced with the name of the current input file), one can select
whether by default the raw data, the smoothed data or both will be
plotted, one can set the colors for the two lines, the default smoothing
parameters, and the default size of the chart graph in pixels.
-----------
Keyboard Shortcuts
@ -976,10 +1043,25 @@ available (On macOS use the Command key instead of Ctrl/Control).
- Ctrl+Shift+T
- LAMMPS Tutorial
Further editing keybindings `are documented with the Qt documentation
Further keybindings of the editor window `are documented with the Qt
documentation
<https://doc.qt.io/qt-5/qplaintextedit.html#editing-key-bindings>`_. In
case of conflicts the list above takes precedence.
All other windows only support a subset of keyboard shortcuts listed
above. Typically, the shortcuts `Ctrl-/` (Stop Run), `Ctrl-W` (Close
Window), and `Ctrl-Q` (Quit Application) are supported.
-------------
.. _Gravelle1:
**(Gravelle1)** Gravelle, Gissinger, Kohlmeyer, `arXiv:2503.14020 \[physics.comp-ph\] <https://doi.org/10.48550/arXiv.2503.14020>`_ (2025)
.. _Gravelle2:
**(Gravelle2)** Gravelle https://lammpstutorials.github.io/
.. raw:: latex
\clearpage

View File

@ -2,14 +2,18 @@ Moltemplate Tutorial
====================
In this tutorial, we are going to use the tool :ref:`Moltemplate
<moltemplate>` to set up a classical molecular dynamic simulation using
the :ref:`OPLS-AA force field <OPLSAA96>`. The first
task is to describe an organic compound and create a complete input deck
for LAMMPS. The second task is to map the OPLS-AA force field to a
molecular sample created with an external tool, e.g. PACKMOL, and
exported as a PDB file. The files used in this tutorial can be found
in the ``tools/moltemplate/tutorial-files`` folder of the LAMMPS
source code distribution.
<Moltemplate1>` from https://moltemplate.org/ to set up a classical
molecular dynamic simulation using the :ref:`OPLS-AA force field
<oplsaa2024>`. The first task is to describe an organic compound and
create a complete input deck for LAMMPS. The second task is to use
moltemplate to build a polymer. The third task is to map the OPLS-AA
force field to a molecular sample created with an external tool,
e.g. PACKMOL, and exported as a PDB file. The files used in this
tutorial can be found in the ``tools/moltemplate/tutorial-files`` folder
of the LAMMPS source code distribution.
Many more examples can be found here: https://moltemplate.org/examples.html
Simulating an organic solvent
"""""""""""""""""""""""""""""
@ -17,14 +21,13 @@ Simulating an organic solvent
This example aims to create a cubic box of the organic solvent
formamide.
The first step is to create a molecular topology in the
LAMMPS-template (LT) file format representing a single molecule, which
will be stored in a Moltemplate object called ``_FAM inherits OPLSAA {}``.
The first step is to create a molecular topology in the LAMMPS-template
(LT) file format representing a single molecule, which will be
stored in a Moltemplate object called ``_FAM inherits OPLSAA {}``.
This command states that the object ``_FAM`` is based on an existing
object called ``OPLSAA``, which contains OPLS-AA parameters, atom type
definitions, partial charges, masses and bond-angle rules for many organic
and biological compounds.
The atomic structure is the starting point to populate the command
``write('Data Atoms') {}``, which will write the ``Atoms`` section in the
LAMMPS data file. The OPLS-AA force field uses the ``atom_style full``,
@ -36,21 +39,23 @@ to the ``molID``, except that the same variable is used for the whole
molecule. The atom types are assigned using ``@``-type variables. The
assignment of atom types (e.g. ``@atom:177``, ``@atom:178``) is done using
the OPLS-AA atom types defined in the "In Charges" section of the file
``oplsaa.lt``, looking for a reasonable match with the description of the atom.
``oplsaa2024.lt``, looking for a reasonable match with the description of the atom.
The resulting file (``formamide.lt``) follows:
.. code-block:: bash
import /usr/local/moltemplate/moltemplate/force_fields/oplsaa2024.lt # defines OPLSAA
_FAM inherits OPLSAA {
# atomID molID atomType charge coordX coordY coordZ
write('Data Atoms') {
$atom:C00 $mol @atom:177 0.00 0.100 0.490 0.0
$atom:O01 $mol @atom:178 0.00 1.091 -0.250 0.0
$atom:N02 $mol @atom:179 0.00 -1.121 -0.181 0.0
$atom:H03 $mol @atom:182 0.00 -2.013 0.272 0.0
$atom:H04 $mol @atom:182 0.00 -1.056 -1.190 0.0
$atom:H05 $mol @atom:221 0.00 0.144 1.570 0.0
$atom:C00 $mol @atom:235 0.00 0.100 0.490 0.0
$atom:O01 $mol @atom:236 0.00 1.091 -0.250 0.0
$atom:N02 $mol @atom:237 0.00 -1.121 -0.181 0.0
$atom:H03 $mol @atom:240 0.00 -2.013 0.272 0.0
$atom:H04 $mol @atom:240 0.00 -1.056 -1.190 0.0
$atom:H05 $mol @atom:279 0.00 0.144 1.570 0.0
}
# A list of the bonds in the molecule:
@ -64,16 +69,17 @@ The resulting file (``formamide.lt``) follows:
}
}
You don't have to specify the charge in this example because they will
be assigned according to the atom type. Analogously, only a
"Data Bond List" section is needed as the atom type will determine the
bond type. The other bonded interactions (e.g. angles,
dihedrals, and impropers) will be automatically generated by
You don't have to specify the charge in this example because the OPLSAA
force-field assigns charge according to the atom type. (This is not true
when using other force fields.) A "Data Bond List" section is needed as
the atom type will determine the bond type. The other bonded interactions
(e.g. angles, dihedrals, and impropers) will be automatically generated by
Moltemplate.
If the simulation is non-neutral, or Moltemplate complains that you have
missing bond, angle, or dihedral types, this means at least one of your
atom types is incorrect.
If the simulation is not charge-neutral, or Moltemplate complains that
you have missing bond, angle, or dihedral types, this probably means that
at least one of your atom types is incorrect (or that perhaps there is no
suitable atom type currently defined in the ``oplsaa2024.lt`` file).
The second step is to create a master file with instructions to build a
starting structure and the LAMMPS commands to run an NPT simulation. The
@ -81,11 +87,9 @@ master file (``solv_01.lt``) follows:
.. code-block:: bash
# Import the force field.
import /usr/local/moltemplate/moltemplate/force_fields/oplsaa.lt
import formamide.lt # after oplsaa.lt, as it depends on it.
import formamide.lt # Defines "_FAM" and OPLSAA
# Create the input sample.
# Distribute the molecules on a 5x5x5 cubic grid with spacing 4.6
solv = new _FAM [5].move( 4.6, 0, 0)
[5].move( 0, 4.6, 0)
[5].move( 0, 0, 4.6)
@ -98,8 +102,11 @@ master file (``solv_01.lt``) follows:
-11.5 11.5 zlo zhi
}
# Create an input deck for LAMMPS.
write_once("In Init"){
# Note: The lines below in the "In Run" section are often omitted.
write_once("In Run"){
# Create an input deck for LAMMPS.
# Run an NPT simulation.
# Input variables.
variable run string solv_01 # output name
variable ts equal 1 # timestep
@ -109,12 +116,6 @@ master file (``solv_01.lt``) follows:
variable equi equal 5000 # Equilibration steps
variable prod equal 30000 # Production steps
# PBC (set them before the creation of the box).
boundary p p p
}
# Run an NPT simulation.
write_once("In Run"){
# Derived variables.
variable tcouple equal \$\{ts\}*100
variable pcouple equal \$\{ts\}*1000
@ -143,7 +144,7 @@ master file (``solv_01.lt``) follows:
unfix NPT
}
The first two commands insert the content of files ``oplsaa.lt`` and
The first two commands insert the content of files ``oplsaa2024.lt`` and
``formamide.lt`` into the master file. At this point, we can use the
command ``solv = new _FAM [N]`` to create N copies of a molecule of type
``_FAM``. In this case, we create an array of 5*5*5 molecules on a cubic
@ -153,21 +154,37 @@ the sample was created from scratch, we also specify the simulation box
size in the "Data Boundary" section.
The LAMMPS setting for the force field are specified in the file
``oplsaa.lt`` and are written automatically in the input deck. We also
``oplsaa2024.lt`` and are written automatically in the input deck. We also
specify the boundary conditions and a set of variables in
the "In Init" section. The remaining commands to run an NPT simulation
the "In Init" section.
The remaining commands to run an NPT simulation
are written in the "In Run" section. Note that in this script, LAMMPS
variables are protected with the escape character ``\`` to distinguish
them from Moltemplate variables, e.g. ``\$\{run\}`` is a LAMMPS
variable that is written in the input deck as ``${run}``.
(Note: Moltemplate can be slow to run, so you need to change you run
settings frequently, I recommended moving those commands (from "In Run")
out of your .lt files and into a separate file. Moltemplate creates a
file named ``run.in.EXAMPLE`` for this purpose. You can put your run
settings and fixes that file and then invoke LAMMPS using
``mpirun -np 4 lmp -in run.in.EXAMPLE`` instead.)
Compile the master file with:
.. code-block:: bash
moltemplate.sh -overlay-all solv_01.lt
moltemplate.sh solv_01.lt
cleanup_moltemplate.sh # <-- optional: see below
And execute the simulation with the following:
(Note: The optional "cleanup_moltemplate.sh" command deletes
unused atom types, which sometimes makes LAMMPS run faster.
But it does not work with many-body pair styles or dreiding-style h-bonds.
Fortunately most force fields, including OPLSAA, don't use those features.)
Then execute the simulation with the following:
.. code-block:: bash
@ -180,15 +197,116 @@ And execute the simulation with the following:
Snapshot of the sample at the beginning and end of the simulation.
Rendered with Ovito.
Building a simple polymer
"""""""""""""""""""""""""
Moltemplate is particularly useful for building polymers (and other molecules
with sub-units). As an simple example, consider butane:
.. figure:: JPG/butane.jpg
The ``butane.lt`` file below defines Butane as a polymer containing
4 monomers (of type ``CH3``, ``CH2``, ``CH2``, ``CH3``).
.. code-block:: bash
import /usr/local/moltemplate/moltemplate/force_fields/oplsaa2024.lt # defines OPLSAA
CH3 inherits OPLSAA {
# atomID molID atomType charge coordX coordY coordZ
write("Data Atoms") {
$atom:c $mol:... @atom:54 0.0 0.000000 0.4431163 0.000000
$atom:h1 $mol:... @atom:60 0.0 0.000000 1.0741603 0.892431
$atom:h2 $mol:... @atom:60 0.0 0.000000 1.0741603 -0.892431
$atom:h3 $mol:... @atom:60 0.0 -0.892431 -0.1879277 0.000000
}
# (Using "$mol:..." indicates this object ("CH3") is part of a larger
# molecule. Moltemplate will share the molecule-ID with that molecule.)
# A list of the bonds within the "CH3" molecular sub-unit:
# BondID AtomID1 AtomID2
write('Data Bond List') {
$bond:ch1 $atom:c $atom:h1
$bond:ch2 $atom:c $atom:h2
$bond:ch3 $atom:c $atom:h3
}
}
CH2 inherits OPLSAA {
# atomID molID atomType charge coordX coordY coordZ
write("Data Atoms") {
$atom:c $mol:... @atom:57 0.0 0.000000 0.4431163 0.000000
$atom:h1 $mol:... @atom:60 0.0 0.000000 1.0741603 0.892431
$atom:h2 $mol:... @atom:60 0.0 0.000000 1.0741603 -0.892431
}
# A list of the bonds within the "CH2" molecular sub-unit:
# BondID AtomID1 AtomID2
write('Data Bond List') {
$bond:ch1 $atom:c $atom:h1
$bond:ch2 $atom:c $atom:h2
}
}
Butane inherits OPLSAA {
create_var {$mol} # optional:force all monomers to share the same molecule-ID
# - Create 4 monomers
# - Move them along the X axis using ".move()",
# - Rotate them 180 degrees with respect to the previous monomer
monomer1 = new CH3
monomer2 = new CH2.rot(180,1,0,0).move(1.2533223,0,0)
monomer3 = new CH2.move(2.5066446,0,0)
monomer4 = new CH3.rot(180,0,0,1).move(3.7599669,0,0)
# A list of the bonds connecting different monomers together:
write('Data Bond List') {
$bond:b1 $atom:monomer1/c $atom:monomer2/c
$bond:b2 $atom:monomer2/c $atom:monomer3/c
$bond:b3 $atom:monomer3/c $atom:monomer4/c
}
}
Again, you don't have to specify the charge in this example because OPLSAA
assigns charges according to the atom type.
This ``Butane`` object is a molecule which can be used anywhere other molecules
can be used. (You can arrange ``Butane`` molecules on a lattice, as we did previously.
You can also modify individual butane molecules by adding or deleting atoms or bonds.
You can add bonds between specific butane molecules or use ``Butane`` as a
sub-unit to define even larger molecules. See the moltemplate manual for details.)
How to build a complex polymer
""""""""""""""""""""""""""""""""""""""""""
A similar procedure can be used to create more complicated polymers,
such as the NIPAM polymer example shown below. For details, see:
https://github.com/jewettaij/moltemplate/tree/master/examples/all_atom/force_field_OPLSAA/NIPAM_polymer+water+ions
Mapping an existing structure
"""""""""""""""""""""""""""""
Another helpful way to use Moltemplate is mapping an existing molecular
sample to a force field. This is useful when a complex sample is
assembled from different simulations or created with specialized
software (e.g. PACKMOL). As in the previous example, all molecular
species in the sample must be defined using single-molecule Moltemplate
objects. For this example, we use a short polymer in a box containing
sample to a force field. This is useful when a complex sample is assembled
from different simulations or created with specialized software (e.g. PACKMOL).
(Note: The previous link shows how to build this entire system from scratch
using only moltemplate. However here we will assume instead that we obtained
a PDB file for this system using PACKMOL.)
As in the previous examples, all molecular species in the sample
are defined using single-molecule Moltemplate objects.
For this example, we use a short polymer in a box containing
water molecules and ions in the PDB file ``model.pdb``.
It is essential to understand that the order of atoms in the PDB file
@ -246,25 +364,25 @@ The resulting master LT file defining short annealing at a fixed volume
.. code-block:: bash
# Use the OPLS-AA force field for all species.
import /usr/local/moltemplate/moltemplate/force_fields/oplsaa.lt
import /usr/local/moltemplate/moltemplate/force_fields/oplsaa2024.lt
import PolyNIPAM.lt
# Define the SPC water and ions as in the OPLS-AA
Ca inherits OPLSAA {
write("Data Atoms"){
$atom:a1 $mol:. @atom:354 0.0 0.00000 0.00000 0.000000
$atom:a1 $mol:. @atom:412 0.0 0.00000 0.00000 0.000000
}
}
Cl inherits OPLSAA {
write("Data Atoms"){
$atom:a1 $mol:. @atom:344 0.0 0.00000 0.00000 0.000000
$atom:a1 $mol:. @atom:401 0.0 0.00000 0.00000 0.000000
}
}
SPC inherits OPLSAA {
write("Data Atoms"){
$atom:O $mol:. @atom:76 0. 0.0000000 0.00000 0.000000
$atom:H1 $mol:. @atom:77 0. 0.8164904 0.00000 0.5773590
$atom:H2 $mol:. @atom:77 0. -0.8164904 0.00000 0.5773590
$atom:O $mol:. @atom:9991 0. 0.0000000 0.00000 0.0000000
$atom:H1 $mol:. @atom:9990 0. 0.8164904 0.00000 0.5773590
$atom:H2 $mol:. @atom:9990 0. -0.8164904 0.00000 0.5773590
}
write("Data Bond List") {
$bond:OH1 $atom:O $atom:H1
@ -285,8 +403,15 @@ The resulting master LT file defining short annealing at a fixed volume
0 26 zlo zhi
}
# Define the input variables.
write_once("In Init"){
boundary p p p # "p p p" is the default. This line is optional.
neighbor 3 bin # (This line is also optional in this example.)
}
# Note: The lines below in the "In Run" section are often omitted.
# Run an NVT simulation.
write_once("In Run"){
# Input variables.
variable run string sample01 # output name
variable ts equal 2 # timestep
@ -294,13 +419,6 @@ The resulting master LT file defining short annealing at a fixed volume
variable p equal 1. # equilibrium pressure
variable equi equal 30000 # equilibration steps
# PBC (set them before the creation of the box).
boundary p p p
neighbor 3 bin
}
# Run an NVT simulation.
write_once("In Run"){
# Set the output.
thermo 1000
thermo_style custom step etotal evdwl ecoul elong ebond eangle &
@ -314,8 +432,8 @@ The resulting master LT file defining short annealing at a fixed volume
write_data \$\{run\}.min
# Set the constrains.
group watergroup type @atom:76 @atom:77
fix 0 watergroup shake 0.0001 10 0 b @bond:042_043 a @angle:043_042_043
group watergroup type @atom:9991 @atom:9990
fix 0 watergroup shake 0.0001 10 0 b @bond:spcO_spcH a @angle:spcH_spcO_spcH
# Short annealing.
timestep \$\{ts\}
@ -327,7 +445,7 @@ The resulting master LT file defining short annealing at a fixed volume
In this example, the water model is SPC and it is defined in the
``oplsaa.lt`` file with atom types ``@atom:76`` and ``@atom:77``. For
``oplsaa2024.lt`` file with atom types ``@atom:9991`` and ``@atom:9990``. For
water we also use the ``group`` and ``fix shake`` commands with
Moltemplate ``@``-type variables, to ensure consistency with the
numerical values assigned during compilation. To identify the bond and
@ -336,19 +454,20 @@ are:
.. code-block:: bash
replace{ @atom:76 @atom:76_b042_a042_d042_i042 }
replace{ @atom:77 @atom:77_b043_a043_d043_i043 }
replace{ @atom:9991 @atom:9991_bspcO_aspcO_dspcO_ispcO }
replace{ @atom:9990 @atom:9990_bspcH_aspcH_dspcH_ispcH }
From which we can identify the following "Data Bonds By Type":
``@bond:042_043 @atom:*_b042*_a*_d*_i* @atom:*_b043*_a*_d*_i*`` and
"Data Angles By Type": ``@angle:043_042_043 @atom:*_b*_a043*_d*_i*
@atom:*_b*_a042*_d*_i* @atom:*_b*_a043*_d*_i*``
``@bond:spcO_spcH @atom:*_bspcO*_a*_d*_i* @atom:*_bspcH*_a*_d*_i*``
and "Data Angles By Type":
``@angle:spcH_spcO_spcH @atom:*_b*_aspcH*_d*_i* @atom:*_b*_aspcO*_d*_i* @atom:*_b*_aspcH*_d*_i*``
Compile the master file with:
.. code-block:: bash
moltemplate.sh -overlay-all -pdb model.pdb sample01.lt
moltemplate.sh -pdb model.pdb sample01.lt
cleanup_moltemplate.sh
And execute the simulation with the following:
@ -363,8 +482,13 @@ And execute the simulation with the following:
Sample visualized with Ovito loading the trajectory into the DATA
file written after minimization.
------------
.. _OPLSAA96:
.. _oplsaa2024:
**(OPLS-AA)** Jorgensen, Maxwell, Tirado-Rives, J Am Chem Soc, 118(45), 11225-11236 (1996).
**(OPLS-AA)** Jorgensen, W.L., Ghahremanpour, M.M., Saar, A., Tirado-Rives, J., J. Phys. Chem. B, 128(1), 250-262 (2024).
.. _Moltemplate1:
**(Moltemplate)** Jewett et al., J. Mol. Biol., 433(11), 166841 (2021)

View File

@ -197,7 +197,7 @@ The LPS model has a force scalar state
.. math::
\underline{t} = \frac{3K\theta}{m}\underline{\omega}\,\underline{x} +
\alpha \underline{\omega}\,\underline{e}^{\rm d}, \qquad\qquad\textrm{(3)}
\alpha \underline{\omega}\,\underline{e}^\mathrm{d}, \qquad\qquad\textrm{(3)}
with :math:`K` the bulk modulus and :math:`\alpha` related to the shear
modulus :math:`G` as
@ -242,14 +242,14 @@ scalar state are defined, respectively, as
.. math::
\underline{e}^{\rm i}=\frac{\theta \underline{x}}{3}, \qquad
\underline{e}^{\rm d} = \underline{e}- \underline{e}^{\rm i},
\underline{e}^\mathrm{i}=\frac{\theta \underline{x}}{3}, \qquad
\underline{e}^\mathrm{d} = \underline{e}- \underline{e}^\mathrm{i},
where the arguments of the state functions and the vectors on which they
operate are omitted for simplicity. We note that the LPS model is linear
in the dilatation :math:`\theta`, and in the deviatoric part of the
extension :math:`\underline{e}^{\rm d}`.
extension :math:`\underline{e}^\mathrm{d}`.
.. note::

View File

@ -62,17 +62,17 @@ with :ref:`PNG, JPEG and FFMPEG output support <graphics>` enabled.
cd $LAMMPS_DIR/src
# add packages if necessary
# add LAMMPS packages if necessary
make yes-MOLECULE
make yes-PYTHON
# compile shared library using Makefile
make mpi mode=shlib LMP_INC="-DLAMMPS_PNG -DLAMMPS_JPEG -DLAMMPS_FFMPEG" JPG_LIB="-lpng -ljpeg"
Step 2: Installing the LAMMPS Python package
""""""""""""""""""""""""""""""""""""""""""""
Step 2: Installing the LAMMPS Python module
"""""""""""""""""""""""""""""""""""""""""""
Next install the LAMMPS Python package into your current Python installation with:
Next install the LAMMPS Python module into your current Python installation with:
.. code-block:: bash
@ -89,6 +89,29 @@ privileges) or into your personal Python module folder.
Recompiling the shared library requires re-installing the Python
package.
.. _externally_managed:
.. admonition:: Handling an "externally-managed-environment" Error
:class: Hint
Some Python installations made through Linux distributions
(e.g. Ubuntu 24.04LTS or later) will prevent installing the LAMMPS
Python module into a system folder or a corresponding folder of the
individual user as attempted by ``make install-python`` with an error
stating that an *externally managed* python installation must be only
managed by the same package package management tool. This is an
optional setting, so not all Linux distributions follow it currently
(Spring 2025). The reasoning and explanations for this error can be
found in the `Python Packaging User Guide
<https://packaging.python.org/en/latest/specifications/externally-managed-environments/>`_
These guidelines suggest to create a virtual environment and install
the LAMMPS Python module there (see below). This is generally a good
idea and the LAMMPS developers recommend this, too. If, however, you
want to proceed and install the LAMMPS Python module regardless, you
can install the "wheel" file (see above) manually with the ``pip``
command by adding the ``--break-system-packages`` flag.
Installation inside of a virtual environment
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

View File

@ -249,23 +249,23 @@ as follows:
.. math::
a = & {\rm lx} \\
b^2 = & {\rm ly}^2 + {\rm xy}^2 \\
c^2 = & {\rm lz}^2 + {\rm xz}^2 + {\rm yz}^2 \\
\cos{\alpha} = & \frac{{\rm xy}*{\rm xz} + {\rm ly}*{\rm yz}}{b*c} \\
\cos{\beta} = & \frac{\rm xz}{c} \\
\cos{\gamma} = & \frac{\rm xy}{b} \\
a = & \mathrm{lx} \\
b^2 = & \mathrm{ly}^2 + \mathrm{xy}^2 \\
c^2 = & \mathrm{lz}^2 + \mathrm{xz}^2 + \mathrm{yz}^2 \\
\cos{\alpha} = & \frac{\mathrm{xy}*\mathrm{xz} + \mathrm{ly}*\mathrm{yz}}{b*c} \\
\cos{\beta} = & \frac{\mathrm{xz}}{c} \\
\cos{\gamma} = & \frac{\mathrm{xy}}{b} \\
The inverse relationship can be written as follows:
.. math::
{\rm lx} = & a \\
{\rm xy} = & b \cos{\gamma} \\
{\rm xz} = & c \cos{\beta}\\
{\rm ly}^2 = & b^2 - {\rm xy}^2 \\
{\rm yz} = & \frac{b*c \cos{\alpha} - {\rm xy}*{\rm xz}}{\rm ly} \\
{\rm lz}^2 = & c^2 - {\rm xz}^2 - {\rm yz}^2 \\
\mathrm{lx} = & a \\
\mathrm{xy} = & b \cos{\gamma} \\
\mathrm{xz} = & c \cos{\beta}\\
\mathrm{ly}^2 = & b^2 - \mathrm{xy}^2 \\
\mathrm{yz} = & \frac{b*c \cos{\alpha} - \mathrm{xy}*\mathrm{xz}}{\mathrm{ly}} \\
\mathrm{lz}^2 = & c^2 - \mathrm{xz}^2 - \mathrm{yz}^2 \\
The values of *a*, *b*, *c*, :math:`\alpha` , :math:`\beta`, and
:math:`\gamma` can be printed out or accessed by computes using the

View File

@ -12,19 +12,10 @@ several advantages:
LAMMPS. For that, you should first create your own :doc:`fork on
GitHub <Howto_github>`, though.
You must have `git <git_>`_ installed on your system to use the
commands explained below to communicate with the git servers on
GitHub. For people still using subversion (svn), GitHub also
provides `limited support for subversion clients <svn_>`_.
.. note::
As of October 2016, the official home of public LAMMPS development is
on GitHub. The previously advertised LAMMPS git repositories on
git.lammps.org and bitbucket.org are now offline or deprecated.
You must have `git <git_>`_ installed on your system to use the commands
explained below to communicate with the git servers on GitHub.
.. _git: https://git-scm.com
.. _svn: https://help.github.com/en/github/importing-your-projects-to-github/working-with-subversion-on-github
You can follow the LAMMPS development on 4 different git branches:

View File

@ -5,8 +5,7 @@ LAMMPS can be downloaded, built, and configured for macOS with `Homebrew
<homebrew_>`_. (Alternatively, see the installation instructions for
:doc:`downloading an executable via Conda <Install_conda>`.) The
following LAMMPS packages are unavailable at this time because of
additional requirements not yet met: GPU, KOKKOS, MSCG, POEMS,
VORONOI.
additional requirements not yet met: GPU, KOKKOS.
After installing Homebrew, you can install LAMMPS on your system with
the following commands:

View File

@ -20,13 +20,21 @@ acceleration.
.. _lws: https://www.lammps.org
.. _omp: https://www.openmp.org
LAMMPS is written in C++ and requires a compiler that is at least
compatible with the C++-11 standard. Earlier versions were written in
F77, F90, and C++-98. See the `History page
LAMMPS is written in C++ and currently requires a compiler that is at
least compatible with the C++-11 standard. Earlier versions were
written in F77, F90, and C++-98. See the `History page
<https://www.lammps.org/history.html>`_ of the website for details. All
versions can be downloaded as source code from the `LAMMPS website
<lws_>`_.
Through a :ref:`C language API <lammps_c_api>` LAMMPS functionality can
be accessed and managed from other programming languages rather than
running the LAMMPS executable. Ready to use modules for :ref:`Python
<lammps_python_api>` and :ref:`Fortran <lammps_fortran_api>` exist, and
an example :ref:`SWIG interface file <swig>` as well as example C files
for dynamically loading LAMMPS as a shared library into other
executables are provided.
LAMMPS is designed to be easy to modify or extend with new capabilities,
such as new force fields, atom types, boundary conditions, or
diagnostics. See the :doc:`Modify` section of for more details.

View File

@ -13,10 +13,14 @@ Programming language standards
Most of the C++ code currently requires a compiler compatible with the
C++11 standard, the KOKKOS package currently requires C++17. Most of
the Python code is written to be compatible with Python 3.5 or later or
Python 2.7. Some Python scripts *require* Python 3 and a few others
still need to be ported from Python 2 to Python 3.
the Python code is written to be compatible with Python 3.6 or later.
.. deprecated:: 2Apr2025
Python 2.x is no longer supported and trying to use it, e.g. for the
LAMMPS Python module should result in an error. If you come across
some part of the LAMMPS distribution that is not (yet) compatible with
Python 3, please notify the LAMMPS developers.
Build systems
^^^^^^^^^^^^^
@ -24,8 +28,8 @@ Build systems
LAMMPS can be compiled from source code using a (traditional) build
system based on shell scripts, a few shell utilities (grep, sed, cat,
tr) and the GNU make program. This requires running within a Bourne
shell (``/bin/sh``). Alternatively, a build system with different back ends
can be created using CMake. CMake must be at least version 3.16.
shell (``/bin/sh``). Alternatively, a build system with different back
ends can be created using CMake. CMake must be at least version 3.16.
Operating systems
^^^^^^^^^^^^^^^^^

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 94 KiB

BIN
doc/src/JPG/butane.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 106 KiB

After

Width:  |  Height:  |  Size: 117 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 59 KiB

After

Width:  |  Height:  |  Size: 57 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 44 KiB

After

Width:  |  Height:  |  Size: 44 KiB

BIN
doc/src/JPG/rhodo-both.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 568 KiB

View File

@ -19,9 +19,9 @@ there are now a few requirements for including new changes or extensions.
be added.
- New features should also be implemented and documented not just
for the C interface, but also the Python and Fortran interfaces.
- All additions should work and be compatible with ``-DLAMMPS_BIGBIG``,
``-DLAMMPS_SMALLBIG``, ``-DLAMMPS_SMALLSMALL`` as well as when
compiling with and without MPI support.
- All additions should work and be compatible with
``-DLAMMPS_BIGBIG``, ``-DLAMMPS_SMALLBIG`` as well as when compiling
with and without MPI support.
- The ``library.h`` file should be kept compatible to C code at
a level similar to C89. Its interfaces may not reference any
custom data types (e.g. ``bigint``, ``tagint``, and so on) that

View File

@ -20,6 +20,7 @@ functions. They do not directly call the LAMMPS library.
- :cpp:func:`lammps_force_timeout`
- :cpp:func:`lammps_has_error`
- :cpp:func:`lammps_get_last_error_message`
- :cpp:func:`lammps_set_show_error`
- :cpp:func:`lammps_python_api_version`
The :cpp:func:`lammps_free` function is a clean-up function to free
@ -110,6 +111,11 @@ where such memory buffers were allocated that require the use of
-----------------------
.. doxygenfunction:: lammps_set_show_error
:project: progguide
-----------------------
.. doxygenfunction:: lammps_python_api_version
:project: progguide

View File

@ -2,9 +2,15 @@ What does a LAMMPS version mean
-------------------------------
The LAMMPS "version" is the date when it was released, such as 1 May
2014. LAMMPS is updated continuously, and we aim to keep it working
correctly and reliably at all times. Also, several variants of static
code analysis are run regularly to maintain or improve the overall code
2014. LAMMPS is updated continuously, and with the help of extensive
automated testing (mostly applied *before* changes are included) we aim
to keep it working correctly and reliably at all times, but there also
are regular *feature releases* with new and expanded functionality, and
there are designated *stable releases* that receive updates with bug
fixes back-ported from the development branch.
In addition to automated testing, several variants of static code
analysis are run regularly to maintain or improve the overall code
quality, consistency, and compliance with programming standards, best
practices and style conventions. You can follow its development in a
public `git repository on GitHub <https://github.com/lammps/lammps>`_.
@ -19,17 +25,18 @@ Identifying the Version
The version date is printed to the screen and log file every time you
run LAMMPS. There also is an indication, if a LAMMPS binary was
compiled from version with modifications **after** a release.
It is also visible in the file src/version.h and in the LAMMPS directory
name created when you unpack a downloaded tarball. And it is on the
first page of the :doc:`manual <Manual>`.
compiled from version with modifications **after** a release, either
from the development version or the maintenance version of the last
stable release. It is also visible in the file src/version.h and in the
LAMMPS directory name created when you unpack a downloaded tarball. And
it is on the first page of the :doc:`manual <Manual>`.
* If you browse the HTML pages of the online version of the LAMMPS
manual, they will by default describe the most current feature release
version of LAMMPS. In the navigation bar on the bottom left, there is
the option to view instead the documentation for the most recent
*stable* version or the documentation corresponding to the state of
the development branch.
the development branch *develop*.
* If you browse the HTML pages included in your downloaded tarball, they
describe the version you have, which may be older than the online
version.
@ -48,8 +55,9 @@ Development
Modifications of the LAMMPS source code (like bug fixes, code
refactoring, updates to existing features, or addition of new features)
are organized into pull requests. Pull requests will be merged into the
*develop* branch of the git repository after they pass automated testing
and code review by the LAMMPS developers.
*develop* branch of the LAMMPS git repository on GitHub after they pass
automated testing and code review by :doc:`core LAMMPS developers
<Intro_authors>`.
Feature Releases
""""""""""""""""
@ -62,8 +70,7 @@ repository is updated with every such *feature release* and a tag in the
format ``patch_1May2014`` is added. A summary of the most important
changes of these releases for the current year are posted on `this
website page <https://www.lammps.org/bug.html>`_. More detailed release
notes are `available on GitHub
<https://github.com/lammps/lammps/releases/>`_.
notes are `available on GitHub <https://github.com/lammps/lammps/releases/>`_.
Stable Releases
"""""""""""""""
@ -71,18 +78,18 @@ Stable Releases
About once a year, we release a *stable release* version of LAMMPS.
This is done after a "stabilization period" where we apply only bug
fixes and small, non-intrusive changes to the *develop* branch but no
new features. At the same time, the code is subjected to more detailed
and thorough manual testing than the default automated testing.
After such a *stable release*, both the *release* and the *stable*
branches are updated and two tags are applied, a ``patch_1May2014`` format
and a ``stable_1May2014`` format tag.
new features to the core code. At the same time, the code is subjected
to more detailed and thorough manual testing than the default automated
testing. After such a *stable release*, both the *release* and the
*stable* branches are updated and two tags are applied, a
``patch_1May2014`` format and a ``stable_1May2014`` format tag.
Stable Release Updates
""""""""""""""""""""""
Between *stable releases*, we collect bug fixes and updates back-ported
from the *develop* branch in a branch called *maintenance*. From the
*maintenance* branch we make occasional *stable update releases* and
update the *stable* branch accordingly. The first update to the
``stable_1May2014`` release would be tagged as
Between *stable releases*, we collect bug fixes and updates that are
back-ported from the *develop* branch in a branch called *maintenance*.
From the *maintenance* branch we make occasional *stable update
releases* and update the *stable* branch accordingly. The first update
to the ``stable_1May2014`` release would be tagged as
``stable_1May2014_update1``. These updates contain no new features.

View File

@ -1,19 +1,21 @@
Compute styles
==============
Classes that compute scalar and vector quantities like temperature
and the pressure tensor, as well as classes that compute per-atom
quantities like kinetic energy and the centro-symmetry parameter
are derived from the Compute class. New styles can be created
to add new calculations to LAMMPS.
Classes that compute scalar and vector quantities like temperature and
the pressure tensor, as well as classes that compute per-atom quantities
like kinetic energy and the centro-symmetry parameter are derived from
the Compute class. New styles can be created to add new calculations to
LAMMPS.
Compute_temp.cpp is a simple example of computing a scalar
temperature. Compute_ke_atom.cpp is a simple example of computing
per-atom kinetic energy.
The ``src/compute_temp.cpp`` file is a simple example of computing a
scalar temperature. The ``src/compute_ke_atom.cpp`` file is a simple
example of computing per-atom kinetic energy.
Here is a brief description of methods you define in your new derived
class. See compute.h for details.
class. See ``src/compute.h`` for additional details.
+-----------------------+------------------------------------------------------------------+
| post_constructor | perform tasks that cannot be run in the constructor (optional) |
+-----------------------+------------------------------------------------------------------+
| init | perform one time setup (required) |
+-----------------------+------------------------------------------------------------------+
@ -50,10 +52,11 @@ class. See compute.h for details.
| memory_usage | tally memory usage (optional) |
+-----------------------+------------------------------------------------------------------+
Tally-style computes are a special case, as their computation is done
in two stages: the callback function is registered with the pair style
and then called from the Pair::ev_tally() function, which is called for
each pair after force and energy has been computed for this pair. Then
the tallied values are retrieved with the standard compute_scalar or
compute_vector or compute_peratom methods. The :doc:`compute styles in the TALLY package <compute_tally>`
provide *examples* for utilizing this mechanism.
Tally-style computes are a special case, as their computation is done in
two stages: the callback function is registered with the pair style and
then called from the Pair::ev_tally() function, which is called for each
pair after force and energy has been computed for this pair. Then the
tallied values are retrieved with the standard compute_scalar or
compute_vector or compute_peratom methods. The :doc:`compute styles in
the TALLY package <compute_tally>` provide *examples* for utilizing this
mechanism.

View File

@ -1,23 +1,25 @@
Fix styles
==========
In LAMMPS, a "fix" is any operation that is computed during
timestepping that alters some property of the system. Essentially
everything that happens during a simulation besides force computation,
neighbor list construction, and output, is a "fix". This includes
time integration (update of coordinates and velocities), force
constraints or boundary conditions (SHAKE or walls), and diagnostics
(compute a diffusion coefficient). New styles can be created to add
new options to LAMMPS.
In LAMMPS, a "fix" is any operation that is computed during timestepping
that alters some property of the system. Essentially everything that
happens during a simulation besides force computation, neighbor list
construction, and output, is a "fix". This includes time integration
(update of coordinates and velocities), force constraints or boundary
conditions (SHAKE or walls), and diagnostics (compute a diffusion
coefficient). New styles can be created to add new options to LAMMPS.
Fix_setforce.cpp is a simple example of setting forces on atoms to
prescribed values. There are dozens of fix options already in LAMMPS;
choose one as a template that is similar to what you want to
implement.
The file ``src/fix_setforce.cpp`` is a simple example of setting forces
on atoms to prescribed values. There are dozens of fix options already
in LAMMPS; choose one as a template that is similar to what you want to
implement. There also is a detailed discussion of :doc:`how to write
new fix styles <Developer_write_fix>` in LAMMPS.
Here is a brief description of methods you can define in your new
derived class. See fix.h for details.
derived class. See ``src/fix.h`` for additional details.
+---------------------------+--------------------------------------------------------------------------------------------+
| post_constructor | perform tasks that cannot be run in the constructor (optional) |
+---------------------------+--------------------------------------------------------------------------------------------+
| setmask | determines when the fix is called during the timestep (required) |
+---------------------------+--------------------------------------------------------------------------------------------+
@ -130,10 +132,11 @@ derived class. See fix.h for details.
Typically, only a small fraction of these methods are defined for a
particular fix. Setmask is mandatory, as it determines when the fix
will be invoked during the timestep. Fixes that perform time
integration (\ *nve*, *nvt*, *npt*\ ) implement initial_integrate() and
final_integrate() to perform velocity Verlet updates. Fixes that
constrain forces implement post_force().
will be invoked during :doc:`the evolution of a timestep
<Developer_flow>`. Fixes that perform time integration (\ *nve*, *nvt*,
*npt*\ ) implement initial_integrate() and final_integrate() to perform
velocity Verlet updates. Fixes that constrain forces implement
post_force().
Fixes that perform diagnostics typically implement end_of_step(). For
an end_of_step fix, one of your fix arguments must be the variable
@ -143,13 +146,13 @@ is the first argument the fix defines (after the ID, group-ID, style).
If the fix needs to store information for each atom that persists from
timestep to timestep, it can manage that memory and migrate the info
with the atoms as they move from processors to processor by
implementing the grow_arrays, copy_arrays, pack_exchange, and
unpack_exchange methods. Similarly, the pack_restart and
unpack_restart methods can be implemented to store information about
the fix in restart files. If you wish an integrator or force
constraint fix to work with rRESPA (see the :doc:`run_style <run_style>`
command), the initial_integrate, post_force_integrate, and
final_integrate_respa methods can be implemented. The thermo method
enables a fix to contribute values to thermodynamic output, as printed
quantities and/or to be summed to the potential energy of the system.
with the atoms as they move from processors to processor by implementing
the grow_arrays, copy_arrays, pack_exchange, and unpack_exchange
methods. Similarly, the pack_restart and unpack_restart methods can be
implemented to store information about the fix in restart files. If you
wish an integrator or force constraint fix to work with rRESPA (see the
:doc:`run_style <run_style>` command), the initial_integrate,
post_force_integrate, and final_integrate_respa methods can be
implemented. The thermo method enables a fix to contribute values to
thermodynamic output, as printed quantities and/or to be summed to the
potential energy of the system.

View File

@ -46,6 +46,8 @@ Here is a brief list of some the class methods in the Pair class that
+---------------------------------+------------------------------------------------------------------------+
| compute_inner/middle/outer | versions of compute used by rRESPA |
+---------------------------------+------------------------------------------------------------------------+
| compute_atomic_energy | energy of one atom, equivalent to per-atom energy |
+---------------------------------+------------------------------------------------------------------------+
| memory_usage | return estimated amount of memory used by the pair style |
+---------------------------------+------------------------------------------------------------------------+
| modify_params | process arguments to pair_modify command |
@ -122,3 +124,5 @@ setting.
+---------------------------------+-------------------------------------------------------------+---------+
| spinflag | 1 if compatible with spin kspace_style | 0 |
+---------------------------------+-------------------------------------------------------------+---------+
| atomic_energy_enable | 1 if compute_atomic_energy() routine exists | 0 |
+---------------------------------+-------------------------------------------------------------+---------+

View File

@ -189,10 +189,8 @@ of the contribution. As of January 2023, all previously included
Fortran code for the LAMMPS executable has been replaced by equivalent
C++ code.
Python code must be compatible with Python 3.5 and later. Large parts
of LAMMPS (including the :ref:`PYTHON package <PKG-PYTHON>`) are also
compatible with Python 2.7. Compatibility with Python 2.7 is desirable,
but compatibility with Python 3.5 is **required**.
Python code currently must be compatible with Python 3.6. If a later
version or Python is required, it needs to be documented.
Compatibility with older programming language standards is very
important to maintain portability and availability of LAMMPS on many

View File

@ -2428,7 +2428,7 @@ ways to use LAMMPS and Python together.
Building with the PYTHON package assumes you have a Python development
environment (headers and libraries) available on your system, which needs
to be either Python version 2.7 or Python 3.5 and later.
to be Python version 3.6 or later.
**Install:**

View File

@ -7,6 +7,10 @@ LAMMPS shared library through the Python `ctypes <ctypes_>`_
module. Because of the dynamic loading, it is required that LAMMPS is
compiled in :ref:`"shared" mode <exe>`.
.. versionchanged:: 2Apr2025
LAMMPS currently only supports Python version 3.6 or later.
Two components are necessary for Python to be able to invoke LAMMPS code:
* The LAMMPS Python Package (``lammps``) from the ``python`` folder
@ -106,13 +110,16 @@ folder that the dynamic loader searches or inside of the installed
.. code-block:: bash
python install.py -p <python package> -l <shared library> -v <version.h file> [-n]
python install.py -p <python package> -l <shared library> -v <version.h file> [-n] [-f]
* The ``-p`` flag points to the ``lammps`` Python package folder to be installed,
* the ``-l`` flag points to the LAMMPS shared library file to be installed,
* the ``-v`` flag points to the LAMMPS version header file to extract the version date,
* and the optional ``-n`` instructs the script to only build a wheel file
but not attempt to install it.
* the optional ``-n`` instructs the script to only build a wheel file but not attempt
to install it,
* and the optional ``-f`` argument instructs the script to force installation even if
pip would otherwise refuse installation with an
:ref:`error about externally managed environments <externally_managed>`.
.. tab:: Virtual environment
@ -136,11 +143,6 @@ folder that the dynamic loader searches or inside of the installed
# create virtual environment in folder $HOME/myenv
python3 -m venv $HOME/myenv
For Python versions prior 3.3 you can use `virtualenv
<https://packaging.python.org/en/latest/key_projects/#virtualenv>`_
command instead of "python3 -m venv". This step has to be done
only once.
To activate the virtual environment type:
.. code-block:: bash
@ -199,6 +201,10 @@ folder that the dynamic loader searches or inside of the installed
The ``PYTHONPATH`` needs to point to the parent folder that contains the ``lammps`` package!
In case you run into an "externally-managed-environment" error when
trying to install the LAMMPS Python module, please refer to
:ref:`corresponding paragraph <externally_managed>` in the Python HOWTO
page to learn about options for handling this error.
To verify if LAMMPS can be successfully started from Python, start the
Python interpreter, load the ``lammps`` Python module and create a
@ -245,14 +251,14 @@ make MPI calls directly from Python in your script, if you desire.
We have tested this with `MPI for Python <https://mpi4py.readthedocs.io/>`_
(aka mpi4py) and you will find installation instruction for it below.
Installation of mpi4py (version 3.0.3 as of Sep 2020) can be done as
Installation of mpi4py (version 4.0.1 as of Feb 2025) can be done as
follows:
- Via ``pip`` into a local user folder with:
.. code-block:: bash
pip install --user mpi4py
python3 -m pip install --user mpi4py
- Via ``dnf`` into a system folder for RedHat/Fedora systems:
@ -261,20 +267,20 @@ follows:
# for use with OpenMPI
sudo dnf install python3-mpi4py-openmpi
# for use with MPICH
sudo dnf install python3-mpi4py-openmpi
sudo dnf install python3-mpi4py-mpich
- Via ``pip`` into a virtual environment (see above):
.. code-block:: console
$ source $HOME/myenv/activate
(myenv)$ pip install mpi4py
(myenv)$ python -m pip install mpi4py
- Via ``pip`` into a system folder (not recommended):
.. code-block:: bash
sudo pip install mpi4py
sudo python3 -m pip install mpi4py
For more detailed installation instructions and additional options,
please see the `mpi4py installation <https://mpi4py.readthedocs.io/en/stable/install.html>`_ page.

View File

@ -1,7 +1,7 @@
Running LAMMPS and Python in serial
-----------------------------------
To run a LAMMPS in serial, type these lines into Python
To run a LAMMPS input in serial, type these lines into Python
interactively from the ``bench`` directory:
.. code-block:: python

View File

@ -44,15 +44,11 @@ Below is an example output for Python version 3.8.5.
.. warning::
The options described in this section of the manual for using Python
with LAMMPS currently support either Python 2 or 3. Specifically
version 2.7 or later and 3.6 or later. Since the Python community no
longer maintains Python 2 (see `this notice
<https://www.python.org/doc/sunset-python-2/>`_), we recommend use of
Python 3 with LAMMPS. While Python 2 code should continue to work,
that is not something we can guarantee long-term. If you notice
Python code in the LAMMPS distribution that is not compatible with
Python 3, please contact the LAMMPS developers or submit `and issue
on GitHub <https://github.com/lammps/lammps/issues>`_
with LAMMPS support only Python 3.6 or later. For use with Python
2.x you will need to use an older LAMMPS version like 29 Aug 2024
or older. If you notice Python code in the LAMMPS distribution that
is not compatible with Python 3, please contact the LAMMPS developers
or submit `and issue on GitHub <https://github.com/lammps/lammps/issues>`_
---------

View File

@ -3,17 +3,16 @@ Scatter/gather operations
.. code-block:: python
data = lmp.gather_atoms(name,type,count) # return per-atom property of all atoms gathered into data, ordered by atom ID
# name = "x", "charge", "type", etc
data = lmp.gather_atoms_concat(name,type,count) # ditto, but concatenated atom values from each proc (unordered)
data = lmp.gather_atoms_subset(name,type,count,ndata,ids) # ditto, but for subset of Ndata atoms with IDs
data = lmp.gather_atoms(name,dtype,count) # return per-atom property of all atoms gathered into data, ordered by atom ID
# name = "x", "q", "type", etc
data = lmp.gather_atoms_concat(name,dtype,count) # ditto, but concatenated atom values from each proc (unordered)
data = lmp.gather_atoms_subset(name,dtype,count,ndata,ids) # ditto, but for subset of Ndata atoms with IDs
lmp.scatter_atoms(name,type,count,data) # scatter per-atom property to all atoms from data, ordered by atom ID
# name = "x", "charge", "type", etc
# count = # of per-atom values, 1 or 3, etc
lmp.scatter_atoms_subset(name,type,count,ndata,ids,data) # ditto, but for subset of Ndata atoms with IDs
lmp.scatter_atoms(name,dtype,count,data) # scatter per-atom property to all atoms from data, ordered by atom ID
# name = "x", "q", "type", etc
# count = # of per-atom values, 1 or 3, etc
lmp.scatter_atoms_subset(name,dtype,count,ndata,ids,data) # ditto, but for subset of Ndata atoms with IDs
The gather methods collect peratom info of the requested type (atom
coords, atom types, forces, etc) from all processors, and returns the
@ -22,6 +21,12 @@ functions do the inverse. They distribute a vector of peratom values,
passed by all calling processors, to individual atoms, which may be
owned by different processors.
The *dtype* parameter is 0 for ``int`` values and 1 for ``double``
values. The *count* parameter is 1 for per-atom vectors like "type"
or "q" and 3 for per-atom arrays like "x", "v", "f". Use *count* = 3
with name = "image" if you want the single integer storing the image
flags unpacked into 3 components ("x", "y", and "z").
Note that the data returned by the gather methods,
e.g. :py:meth:`gather_atoms("x") <lammps.lammps.gather_atoms()>`, is
different from the data structure returned by

416
doc/src/Run_formats.rst Normal file
View File

@ -0,0 +1,416 @@
File formats used by LAMMPS
===========================
This page provides a general overview of the kinds of files and file
formats that LAMMPS is reading and writing.
.. contents:: On this page
:depth: 2
:backlinks: top
-------------------
Character Encoding
^^^^^^^^^^^^^^^^^^
For processing text files, the LAMMPS source code assumes `ASCII
character encoding <https://en.wikipedia.org/wiki/ASCII>`_ which
represents the digits 0 to 9, the lower and upper case letters a to z,
some common punctuation and other symbols and a few whitespace
characters including a regular "space character", "line feed", "carriage
return", "tabulator". These characters are all represented by single
bytes with a value smaller than 128 and only 95 of those 128 values
represent printable characters. This list is sufficient to represent
most English text, but misses accented characters or umlauts or Greek
symbols and more.
Modern text often uses `UTF-8 character encoding
<https://en.wikipedia.org/wiki/UTF-8>`_ instead. This encoding is a way
to represent many more different characters as defined by the Unicode
standard. UFT-8 is compatible with ASCII, since the first 128 values
are identical with the ASCII encoding. It is important to note,
however, that there are Unicode characters that *look* similar to ASCII
characters, but have a different binary representation. As a general
rule, these characters may not be correctly recognized by LAMMPS. For
some parts of LAMMPS' text processing, translation tables with known
"lookalike" characters are used. The tables are used to substitute
non-ASCII characters with their ASCII equivalents. Non-ASCII lookalike
characters are often used by web browsers or PDF viewers to improve the
readability of text. Thus, when using copy and paste to transfer text
from such an application to your input file, you may unintentionally
create text that is not exclusively using ASCII encoding and may cause
errors when LAMMPS is trying to read it.
Lines with non-printable and non-ASCII characters in text files can be
detected for example with a (Linux) command like the following:
.. code-block:: bash
env LC_ALL=C grep -n '[^ -~]' some_file.txt
Number Formatting
^^^^^^^^^^^^^^^^^
Different countries and languages have different conventions to format
numbers. While in some regions commas are used for fractions and points
to indicate thousand, million and so on, this is reversed in other
regions. Modern operating systems have facilities to adjust input and
output accordingly that are collectively referred to as "native language
support" (NLS). The exact rules are often applied according to the
value of the ``$LANG`` environment variable (e.g. "en_US.utf8" for
English text in UTF-8 encoding).
For the sake of simplicity of the implementation and transferability of
results, LAMMPS does not support this and instead expects numbers being
formatted in the generic or "C" locale. The "C" locale has no
punctuation for thousand, million and so on and uses a decimal point for
fractions. One thousand would be represented as "1000.0" and not as
"1,000.0" nor as "1.000,0". Having native language support enabled for
a locale other than "C" will result in different behavior when
converting or formatting numbers that can trigger unexpected errors.
LAMMPS also only accepts integer numbers when an integer is required, so
using floating point equivalents like "1.0" are not accepted; you *must*
use "1" instead.
For floating point numbers in scientific notation, the Fortran double
precision notation "1.1d3" is not accepted; you have to use "1100",
"1100.0" or "1.1e3".
Input file
^^^^^^^^^^
A LAMMPS input file is a text file with commands. It is read
line-by-line and each line is processed *immediately*. Before looking
for commands and executing them, there is a pre-processing step where
comments (non-quoted text starting with a pound sign '#') are removed,
``${variable}`` and ``$(expression)`` constructs are expanded or
evaluated, and lines that end in the ampersand character '&' are
combined with the next line (similar to Fortran 90 free-format source
code). After the pre-processing, lines are split into "words" and
evaluated. The first word must be a :doc:`command <Commands_all>` and
all following words are arguments. Below are some example lines:
.. code-block:: LAMMPS
# full line comment
# some global settings
units lj
atom_style atomic
# ^^ command ^^ argument(s)
variable x index 1 # may be overridden from command line with -var x <value>
variable xx equal 20*$x # variable "xx" is always 20 times "x"
lattice fcc 0.8442
# example of a command written across multiple lines
# the "region" command uses spacing from "lattice" command, unless "units box" is specified
region box block 0.0 ${xx} &
0.0 40.0 &
0.0 30.0
# create simulation box and fill with atoms according to lattice setting
create_box 1 box
create_atoms 1 box
# set force field and parameters
mass 1 1.0
pair_style lj/cut 2.5
pair_coeff 1 1 1.0 1.0 2.5
# run simulation
fix 1 all nve
run 1000
The pivotal command in this example input is the :doc:`create_box
command <create_box>`. It defines the simulation system and many
parameters that go with it: units, atom style, number of atom types (and
other types) and more. Those settings are *locked in* after the box is
created. Commands that change these kind of settings are only allowed
**before** a simulation box is created and many other commands are only
allowed **after** the simulation box is defined (e.g. :doc:`pair_coeff
<pair_coeff>`). Very few commands (e.g. :doc:`pair_style <pair_style>`)
may be used in either part of the input. The :doc:`read_data
<read_data>` and :doc:`read_restart <read_restart>` commands also create
the system box and thus have a similar pivotal function.
The LAMMPS input syntax has minimal support for conditionals and loops,
but if more complex operations are required, it is recommended to use
the library interface, e.g. :doc:`from Python using the LAMMPS Python
module <Python_run>`.
There is a frequent misconception about the :doc:`if command <if>`:
this is a command for conditional execution **outside** a run or
minimization. To trigger actions on specific conditions **during**
a run is a non-trivial operation that usually requires adopting one
of the available "fix" commands or creating a new "fix" command.
LAMMPS commands change the internal state and thus the order of commands
matters and reordering them can produce different results. For example,
the region defined by the :doc:`region command <region>` in the example
above depends on the :doc:`lattice setting <lattice>` and thus its
dimensions will be different depending on the order of the two commands.
Each line must have an "end-of-line" character (line feed or carriage
return plus line feed). Some text editors do not automatically insert
one which may cause LAMMPS to ignore the last command. It is thus
recommended to always have an empty line at the end of an input file.
The specific details describing how LAMMPS input is processed and parsed
are explained in :doc:`Commands_parse`.
Data file
^^^^^^^^^
A LAMMPS data file contains a description of a system suitable for
reading with the :doc:`read_data command <read_data>`. Data files are
commonly used for setting up complex molecular systems that can be
difficult to achieve with the commands :doc:`create_box <create_box>`
and :doc:`create_atoms <create_atoms>` alone. Also, data files can be
used as a portable alternatives to a :doc:`binary restart file
<restart>`. A restart file can be converted into a data file from the
:doc:`command line <Run_options>`.
Data files have a header section at the very beginning of the file and
multiple titled sections such as "Atoms", Masses", "Pair Coeffs", and so
on. Header keywords can only be used *before* the first title section.
The data file **always** starts with a "title" line, which will be
**ignored** by LAMMPS. Omitting the title line can lead to unexpected
behavior because a line of the header with an actual setting may be
ignored. In this case, the mistakenly ignored line often contains the
"atoms" keyword, which results in LAMMPS assuming that there are no
atoms in the data file and thus throwing an error on the contents of the
"Atoms" section. The title line may contain some keywords that can be
used by external programs to convey information about the system
(included as comments), that is not required and not read by LAMMPS.
The line following a section title is also **ignored**. An error will
occur if an empty line is not placed after a section title. The number
of lines in titled sections depends on header keywords, like the number
of atom types, the number of atoms, the number of bond types, the number
of bonds, and so on. The data in those sections has to be complete. A
special case are the "Pair Coeffs" and "PairIJ Coeffs" sections; the
former is for force fields and pair styles that use mixing of non-bonded
potential parameters, the latter for pair styles and force fields
requiring explicit coefficients. Thus with *N* being the number of atom
types, the "Pair Coeffs" section has *N* entries while "PairIJ Coeffs"
has :math:`N \cdot (N-1)` entries. Internally, these sections will be
converted to :doc:`pair_coeff <pair_coeff>` commands. Thus the
corresponding :doc:`pair style <pair_style>` must have been set *before*
the :doc:`read_data command <read_data>` reads the data file.
Data files may contain comments, which start with the pound sign '#'.
There must be at least one blank between a valid keyword and the pound
sign. Below is a simple example case of a data file for :doc:`atom style
full <atom_style>`.
.. code-block:: bash
LAMMPS Title line (ignored)
# full line comment
10 atoms # comment
4 atom types
-36.840194 64.211560 xlo xhi
-41.013691 68.385058 ylo yhi
-29.768095 57.139462 zlo zhi
Masses
1 12.0110
2 12.0110
3 15.9990
4 1.0080
Pair Coeffs # this section is optional
1 0.110000 3.563595 0.110000 3.563595
2 0.080000 3.670503 0.010000 3.385415
3 0.120000 3.029056 0.120000 2.494516
4 0.022000 2.351973 0.022000 2.351973
Atoms # full
1 1 1 0.560 43.99993 58.52678 36.78550 0 0 0
2 1 2 -0.270 45.10395 58.23499 35.86693 0 0 0
3 1 3 -0.510 43.81519 59.54928 37.43995 0 0 0
4 1 4 0.090 45.71714 57.34797 36.13434 0 0 0
5 1 4 0.090 45.72261 59.13657 35.67007 0 0 0
6 1 4 0.090 44.66624 58.09539 34.85538 0 0 0
7 1 3 -0.470 43.28193 57.47427 36.91953 0 0 0
8 1 4 0.070 42.07157 57.45486 37.62418 0 0 0
9 1 1 0.510 42.19985 57.57789 39.12163 0 0 0
10 1 1 0.510 41.88641 58.62251 39.70398 0 0 0
# ^^atomID ^^molID ^^type ^^charge ^^xcoord ^^ycoord ^^ycoord ^^image^^flags (optional)
Velocities # this section is optional
1 0.0050731 -0.00398928 0.00391473
2 -0.0175184 0.0173484 -0.00489207
3 0.00597225 -0.00202006 0.00166454
4 -0.010395 -0.0082582 0.00316419
5 -0.00390877 0.00470331 -0.00226911
6 -0.00111157 -0.00374545 -0.0169374
7 0.00209054 -0.00594936 -0.000124563
8 0.00635002 -0.0120093 -0.0110999
9 -0.004955 -0.0123375 0.000403422
10 0.00265028 -0.00189329 -0.00293198
The common problem is processing the "Atoms" section, since its format
depends on the :doc:`atom style <atom_style>` used, and that setting
must be done in the input file *before* reading the data file. To
assist with detecting incompatible data files, a comment is appended to
the "Atoms" title indicating the atom style used (or intended) when
*writing* the data file. For example, below is an "Atoms" section for
:doc:`atom style charge <atom_style>`, which omits the molecule ID
column.
.. code-block:: bash
Atoms # charge
1 1 0.560 43.99993 58.52678 36.78550
2 2 -0.270 45.10395 58.23499 35.86693
3 3 -0.510 43.81519 59.54928 37.43995
4 4 0.090 45.71714 57.34797 36.13434
5 4 0.090 45.72261 59.13657 35.67007
6 4 0.090 44.66624 58.09539 34.85538
7 3 -0.470 43.28193 57.47427 36.91953
8 4 0.070 42.07157 57.45486 37.62418
9 1 0.510 42.19985 57.57789 39.12163
10 1 0.510 41.88641 58.62251 39.70398
# ^^atomID ^^type ^^charge ^^xcoord ^^ycoord ^^ycoord
Another source of confusion about the "Atoms" section format is the
ordering of columns. The three atom style variants `atom_style full`,
`atom_style hybrid charge molecular`, and `atom_style hybrid molecular
charge` all carry the same per-atom information. However, in data files,
the Atoms section has the columns 'Atom-ID Molecule-ID Atom-type Charge
X Y Z' for atom style full, but for hybrid atom styles the first columns
are always 'Atom-ID Atom-type X Y Z' followed by any *additional* data
added by the hybrid styles, for example, 'Charge Molecule-ID' for the
first hybrid style and 'Molecule-ID Charge' in the second hybrid style
variant. Finally, an alternative to a hybrid atom style is to use fix
property/atom, e.g. to add molecule IDs to atom style charge. In this
case the "Atoms" section is formatted according to atom style charge and
a new section, "Molecules" is added that contains lines with 'Atom-ID
Molecule-ID', one for each atom in the system. For adding charges to
atom style molecular with fix property/atom, the "Atoms" section is now
formatted according to the atom style and a "Charges" section is added.
Molecule file
^^^^^^^^^^^^^
Molecule files for use with the :doc:`molecule command <molecule>` look
quite similar to data files but they do not have a compatible format,
i.e., one cannot use a data file as molecule file and vice versa. Below
is a simple example for a water molecule (SPC/E model). Same as a data
file, there is an ignored title line and you can use comments. However,
there is no information about the number of types or the box dimensions.
These parameters are set when the simulation box is created. Thus the
header only has the count of atoms, bonds, and so on.
Molecule files have a header followed by sections (just as in data
files), but the section names are different than those of a data file.
There is no "Atoms" section and the section formats in molecule files is
independent of the atom style. Its information is split across multiple
sections, like "Coords", "Types", and "Charges". Note that no "Masses"
section is needed here. The atom masses are by default tied to the atom
type and set with a data file or the :doc:`mass command <mass>`. A
"Masses" section would only be required for atom styles with per-atom
masses, e.g. atom style sphere, where in data files you would provide
the density and the diameter instead of the mass.
Since the entire file is a 'molecule', LAMMPS will assign a new
molecule-ID (if supported by the atom style) when atoms are instantiated
from a molecule file, e.g. with the :doc:`create_atoms command
<create_atoms>`. It is possible to include a "Molecules" section to
indicate that the atoms belong to multiple 'molecules'. Atom-IDs and
molecule-IDs in the molecule file are relative for the file
(i.e. starting from 1) and will be translated into actual atom-IDs also
when the atoms from the molecule are created.
.. code-block:: bash
# Water molecule. SPC/E model.
3 atoms
2 bonds
1 angles
Coords
1 1.12456 0.09298 1.27452
2 1.53683 0.75606 1.89928
3 0.49482 0.56390 0.65678
Types
1 1
2 2
3 2
Charges
1 -0.8472
2 0.4236
3 0.4236
Bonds
1 1 1 2
2 1 1 3
Angles
1 1 2 1 3
There are also optional sections, e.g. about :doc:`SHAKE <fix_shake>`
and :doc:`special bonds <special_bonds>`. Those sections are only needed
if the molecule command is issued *before* the simulation box is
defined. Otherwise, the molecule command can derive the required
settings internally.
Restart file
^^^^^^^^^^^^
LAMMPS restart files are binary files and not available in text format.
They can be identified by the first few bytes that contain the (C-style)
string ``LammpS RestartT`` as `magic string
<https://en.wikipedia.org/wiki/Magic_string>`_. This string is followed
by a 16-bit integer of the number 1 used for detecting whether the
computer writing the restart has the same `endianness
<https://en.wikipedia.org/wiki/Endianness>`_ as the computer reading it.
If not, the file cannot be read correctly. This integer is followed by
a 32-bit integer indicating the file format revision (currently 3),
which can be used to implement backward compatibility for reading older
revisions.
This information has been added to the `Unix "file" command's
<https://www.darwinsys.com/file/>` "magic" file so that restart files
can be identified without opening them. If you have a fairly recent
version, it should already be included. If you have an older version,
the LAMMPS source package :ref:`contains a file with the necessary
additions <magic>`.
The rest of the file is organized in sections of a 32-bit signed integer
constant indicating the kind of content and the corresponding value (or
values). If those values are arrays (including C-style strings), then
the integer constant is followed by a 32-bit integer indicating the
length of the array. This mechanism will read the data regardless of
the ordering of the sections. Symbolic names of the section constants
are in the ``lmprestart.h`` header file.
LAMMPS restart files are not expected to be portable between platforms
or LAMMPS versions, but changes to the file format are rare.
.. Native Dump file
.. ^^^^^^^^^^^^^^^^
..
.. Potential files
.. ^^^^^^^^^^^^^^^

View File

@ -1,10 +1,11 @@
Run LAMMPS
**********
These pages explain how to run LAMMPS once you have :doc:`installed an executable <Install>` or :doc:`downloaded the source code <Install>`
and :doc:`built an executable <Build>`. The :doc:`Commands <Commands>`
doc page describes how input scripts are structured and the commands
they can contain.
These pages explain how to run LAMMPS once you have :doc:`installed an
executable <Install>` or :doc:`downloaded the source code <Install>` and
:doc:`built an executable <Build>`. The :doc:`Commands <Commands>` doc
page describes how input scripts are structured and the commands they
can contain.
.. toctree::
:maxdepth: 1
@ -12,4 +13,5 @@ they can contain.
Run_basics
Run_options
Run_output
Run_formats
Run_windows

View File

@ -44,11 +44,6 @@ section below for examples where this has been done.
system the crossover (in single precision) is often about 50K-100K
atoms per GPU. When performing double precision calculations the
crossover point can be significantly smaller.
* Both KOKKOS and GPU package compute bonded interactions (bonds, angles,
etc) on the CPU. If the GPU package is running with several MPI processes
assigned to one GPU, the cost of computing the bonded interactions is
spread across more CPUs and hence the GPU package can run faster in these
cases.
* When using LAMMPS with multiple MPI ranks assigned to the same GPU, its
performance depends to some extent on the available bandwidth between
the CPUs and the GPU. This can differ significantly based on the
@ -85,10 +80,10 @@ section below for examples where this has been done.
code (with a performance penalty due to having data transfers between
host and GPU).
* The GPU package requires neighbor lists to be built on the CPU when using
exclusion lists, or a triclinic simulation box.
* The GPU package can be compiled for CUDA or OpenCL and thus supports
both, NVIDIA and AMD GPUs well. On NVIDIA hardware, using CUDA is typically
resulting in equal or better performance over OpenCL.
hybrid pair styles, exclusion lists, or a triclinic simulation box.
* The GPU package can be compiled for CUDA, HIP, or OpenCL and thus supports
NVIDIA, AMD, and Intel GPUs well. On NVIDIA hardware, using CUDA is
typically resulting in equal or better performance over OpenCL.
* OpenCL in the GPU package does theoretically also support Intel CPUs or
Intel Xeon Phi, but the native support for those in KOKKOS (or INTEL)
is superior.

View File

@ -930,7 +930,7 @@ dependencies and redirects the download to the local cache.
mkdir build
cd build
cmake -D LAMMPS_DOWNLOADS_URL=${HTTP_CACHE_URL} -C "${LAMMPS_HTTP_CACHE_CONFIG}" -C ../cmake/presets/most.cmake ../cmake
cmake -D LAMMPS_DOWNLOADS_URL=${HTTP_CACHE_URL} -C "${LAMMPS_HTTP_CACHE_CONFIG}" -C ../cmake/presets/most.cmake -D DOWNLOAD_POTENTIALS=off ../cmake
make -j 8
deactivate_caches
@ -1250,10 +1250,10 @@ tabulate tool
.. versionadded:: 22Dec2022
The ``tabulate`` folder contains Python scripts scripts to generate tabulated
potential files for LAMMPS. The bulk of the code is in the ``tabulate`` module
in the ``tabulate.py`` file. Some example files demonstrating its use are
included. See the README file for more information.
The ``tabulate`` folder contains Python scripts scripts to generate and
visualize tabulated potential files for LAMMPS. The bulk of the code is in the
``tabulate`` module in the ``tabulate.py`` file. Some example files
demonstrating its use are included. See the README file for more information.
----------
@ -1276,11 +1276,13 @@ Those scripts were written by Steve Plimpton sjplimp at gmail.com
valgrind tool
-------------
The ``valgrind`` folder contains additional suppressions fur LAMMPS when using
valgrind's memcheck tool to search for memory access violation and memory
leaks. These suppressions are automatically invoked when running tests through
CMake "ctest -T memcheck". See the provided README file to add these
suppressions when running LAMMPS.
The ``valgrind`` folder contains additional suppressions for LAMMPS when
using `valgrind's <https://valgrind.org/>`_ ` `memcheck tool
<https://valgrind.org/info/tools.html#memcheck>`_ to search for memory
access violation and memory leaks. These suppressions are automatically
invoked when running tests through CMake "ctest -T memcheck". See the
instruction in the ``README`` file to add these suppressions when using
valgrind with LAMMPS or other programs.
----------

View File

@ -215,6 +215,9 @@ for an overview of LAMMPS output options.
The vector or array will be floating point values that correspond to
the specified attribute.
Any settings with the *store/local* option are not saved to a restart
file and must be redefined.
The single() function of this bond style returns 0.0 for the energy
of a bonded interaction, since energy is not conserved in these
dissipative potentials. It also returns only the normal component of

View File

@ -10,7 +10,7 @@ Syntax
bond_style bpm/spring keyword value attribute1 attribute2 ...
* optional keyword = *overlay/pair* or *store/local* or *smooth* or *break* or *volume/factor*
* optional keyword = *overlay/pair* or *store/local* or *smooth* or *normalize* or *break* or *volume/factor*
.. parsed-literal::
@ -141,7 +141,8 @@ calculated using bond lengths squared and the cube root in the above equation
is accordingly replaced with a square root. This approximation assumes bonds
are evenly distributed on a spherical surface and neglects constant prefactors
which are irrelevant since only the ratio of volumes matters. This term may be
used to adjust the Poisson's ratio.
used to adjust the Poisson's ratio. See the simulation in the
``examples/bpm/poissons_ratio`` directory for a demonstration of this effect.
If a bond is broken (or created), :math:`V_{0,i}` is updated by subtracting
(or adding) that bond's contribution.
@ -152,7 +153,7 @@ the data file or restart files read by the :doc:`read_data
<read_data>` or :doc:`read_restart <read_restart>` commands:
* :math:`k` (force/distance units)
* :math:`\epsilon_c` (unit less)
* :math:`\epsilon_c` (unitless)
* :math:`\gamma` (force/velocity units)
Additionally, if *volume/factor* is set to *yes*, a fourth coefficient
@ -214,11 +215,14 @@ for an overview of LAMMPS output options.
The vector or array will be floating point values that correspond to
the specified attribute.
The single() function of this bond style returns 0.0 for the energy
of a bonded interaction, since energy is not conserved in these
dissipative potentials. The single() function also calculates an
extra bond quantity, the initial distance :math:`r_0`. This
extra quantity can be accessed by the
Any settings with the *store/local* option are not saved to a restart
file and must be redefined.
The potential energy and the single() function of this bond style return
:math:`k (r - r_0)^2 / 2` as a proxy of the energy of a bonded interaction,
ignoring any volumetric/smoothing factors or dissipative forces. The single()
function also calculates an extra bond quantity, the initial distance
:math:`r_0`. This extra quantity can be accessed by the
:doc:`compute bond/local <compute_bond_local>` command as *b1*\ .
Restrictions

View File

@ -0,0 +1,184 @@
.. index:: bond_style bpm/spring/plastic
bond_style bpm/spring/plastic command
=====================================
Syntax
""""""
.. code-block:: LAMMPS
bond_style bpm/spring/plastic keyword value attribute1 attribute2 ...
* optional keyword = *overlay/pair* or *store/local* or *smooth* or *normalize* or *break*
.. parsed-literal::
*store/local* values = fix_ID N attributes ...
* fix_ID = ID of associated internal fix to store data
* N = prepare data for output every this many timesteps
* attributes = zero or more of the below attributes may be appended
*id1, id2* = IDs of two atoms in the bond
*time* = the timestep the bond broke
*x, y, z* = the center of mass position of the two atoms when the bond broke (distance units)
*x/ref, y/ref, z/ref* = the initial center of mass position of the two atoms (distance units)
*overlay/pair* value = *yes* or *no*
bonded particles will still interact with pair forces
*smooth* value = *yes* or *no*
smooths bond forces near the breaking point
*normalize* value = *yes* or *no*
normalizes bond forces by the reference length
*break* value = *yes* or *no*
indicates whether bonds break during a run
Examples
""""""""
.. code-block:: LAMMPS
bond_style bpm/spring/plastic
bond_coeff 1 1.0 0.05 0.1 0.02
bond_style bpm/spring/plastic myfix 1000 time id1 id2
dump 1 all local 1000 dump.broken f_myfix[1] f_myfix[2] f_myfix[3]
dump_modify 1 write_header no
Description
"""""""""""
.. versionadded:: 2Apr2025
The *bpm/spring/plastic* bond style computes forces based on
deviations from the initial reference state of the two atoms and the
strain history. The reference length of the bond :math:`r_0` is stored
by each bond when it is first computed in the setup of a run. Initially,
the equilibrium length of each bond :math:`r_\mathrm{eq}` is set equal
to :math:`r_0` but can evolve. data is then preserved across run commands
and is written to :doc:`binary restart files <restart>` such that restarting
the system will not modify either of these quantities.
This bond style only applies central-body forces which conserve the
translational and rotational degrees of freedom of a bonded set of
particles. The force has a magnitude of
.. math::
F = -k (r_\mathrm{eq} - r) w
where :math:`k` is a stiffness, :math:`r` is the current distance between
the two particles, and :math:`w` is an optional smoothing factor discussed
below. If the bond stretches beyond a strain of :math:`\epsilon_p` in compression
or extension, it will plastically activate and :math:`r_\mathrm{eq}` will evolve
to ensure :math:`|(r-r_\mathrm{eq})/r_\mathrm{eq}|` never exceeds :math:`\epsilon_p`.
Therefore, if a bond is continually loaded in either tension or compression, the
force will initially grow elastically before plateauing. See
:ref:`(Clemmer) <plastic-Clemmer>` for more details on these mechanics.
Bonds will break at a strain of :math:`\epsilon_c`. This is done by setting
the bond type to 0 such that forces are no longer computed.
An additional damping force is applied to the bonded
particles. This forces is proportional to the difference in the
normal velocity of particles:
.. math::
F_D = - \gamma w (\hat{r} \bullet \vec{v})
where :math:`\gamma` is the damping strength, :math:`\hat{r}` is the
radial normal vector, and :math:`\vec{v}` is the velocity difference
between the two particles.
The smoothing factor :math:`w` is constructed such that forces smoothly
go to zero, avoiding discontinuities, as bonds approach the critical
breaking strain
.. math::
w = 1.0 - \left( \frac{r - r_0}{r_0 \epsilon_c} \right)^8 .
The following coefficients must be defined for each bond type via the
:doc:`bond_coeff <bond_coeff>` command as in the example above, or in
the data file or restart files read by the :doc:`read_data
<read_data>` or :doc:`read_restart <read_restart>` commands:
* :math:`k` (force/distance units)
* :math:`\epsilon_c` (unitless)
* :math:`\gamma` (force/velocity units)
* :math:`\epsilon_p` (unitless)
See the :doc:`bpm/spring doc page <bond_bpm_spring>` for information on
the *smooth*, *normalize*, *break*, *overlay/pair*, and *store/local*
keywords.
Note that when unbroken bonds are dumped to a file via the
:doc:`dump local <dump>` command, bonds with type 0 (broken bonds)
are not included.
The :doc:`delete_bonds <delete_bonds>` command can also be used to
query the status of broken bonds or permanently delete them, e.g.:
.. code-block:: LAMMPS
delete_bonds all stats
delete_bonds all bond 0 remove
----------
Restart and other info
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
This bond style writes the reference state and plastic history of each
bond to :doc:`binary restart files <restart>`. Loading a restart file
will properly restore bonds. However, the reference state is NOT written
to data files. Therefore reading a data file will not restore bonds and
will cause their reference states to be redefined.
The potential energy and the single() function of this bond style
returns zero. The single() function also calculates two extra bond
quantities, the initial distance :math:`r_0` and the current equilibrium
length :math:`r_eq`. These extra quantities can be accessed by the
:doc:`compute bond/local <compute_bond_local>` command as *b1* and *b2*,
respectively.
Restrictions
""""""""""""
This bond style is part of the BPM package. It is only enabled if
LAMMPS was built with that package. See the :doc:`Build package
<Build_package>` page for more info.
By default if pair interactions between bonded atoms are to be disabled,
this bond style requires setting
.. code-block:: LAMMPS
special_bonds lj 0 1 1 coul 1 1 1
and :doc:`newton <newton>` must be set to bond off. If the *overlay/pair*
keyword is set to *yes*, this bond style alternatively requires setting
.. code-block:: LAMMPS
special_bonds lj/coul 1 1 1
Related commands
""""""""""""""""
:doc:`bond_coeff <bond_coeff>`, :doc:`bond bpm/spring <bond_bpm_spring>`
Default
"""""""
The option defaults are *overlay/pair* = *no*, *smooth* = *yes*, *normalize* = *no*, and *break* = *yes*
----------
.. _plastic-Clemmer:
**(Clemmer)** Clemmer and Lechman, Powder Technology (2025).

View File

@ -60,6 +60,8 @@ Related commands
""""""""""""""""
:doc:`bond_coeff <bond_coeff>`, :doc:`delete_bonds <delete_bonds>`
:doc:`bond style harmonic/shift <bond_harmonic_shift>`,
:doc:`bond style harmonic/shift/cut <bond_harmonic_shift_cut>`
Default
"""""""

View File

@ -31,9 +31,15 @@ the potential
E = \frac{U_{\text{min}}}{(r_0-r_c)^2} \left[ (r-r_0)^2-(r_c-r_0)^2 \right]
where :math:`r_0` is the equilibrium bond distance, and :math:`r_c` the critical distance.
The potential is :math:`-U_{\text{min}}` at :math:`r0` and zero at :math:`r_c`. The spring constant is
:math:`k = U_{\text{min}} / [ 2 (r_0-r_c)^2]`.
where :math:`r_0` is the equilibrium bond distance, and :math:`r_c` the
critical distance. The potential energy has the value
:math:`-U_{\text{min}}` at :math:`r_0` and zero at :math:`r_c`. This
bond style differs from :doc:`bond_style harmonic <bond_harmonic>`
by the value of the potential energy.
The equivalent spring constant value *K* for use with :doc:`bond_style
harmonic <bond_harmonic>` can be computed using :math:`K =
U_{\text{min}} / [(r_0-r_c)^2]`.
The following coefficients must be defined for each bond type via the
:doc:`bond_coeff <bond_coeff>` command as in the example above, or in
@ -41,9 +47,7 @@ the data file or restart files read by the :doc:`read_data <read_data>`
or :doc:`read_restart <read_restart>` commands:
* :math:`U_{\text{min}}` (energy)
* :math:`r_0` (distance)
* :math:`r_c` (distance)
----------
@ -63,7 +67,8 @@ Related commands
""""""""""""""""
:doc:`bond_coeff <bond_coeff>`, :doc:`delete_bonds <delete_bonds>`,
:doc:`bond_harmonic <bond_harmonic>`
:doc:`bond style harmonic <bond_harmonic>`,
:doc:`bond style harmonic/shift/cut <bond_harmonic_shift_cut>`
Default
"""""""

View File

@ -31,9 +31,14 @@ uses the potential
E = \frac{U_{\text{min}}}{(r_0-r_c)^2} \left[ (r-r_0)^2-(r_c-r_0)^2 \right]
where :math:`r_0` is the equilibrium bond distance, and rc the critical distance.
The bond potential is zero for distances :math:`r > r_c`. The potential is :math:`-U_{\text{min}}`
at :math:`r_0` and zero at :math:`r_c`. The spring constant is :math:`k = U_{\text{min}} / [ 2 (r_0-r_c)^2]`.
where :math:`r_0` is the equilibrium bond distance, and :math:`r_c` the
critical distance. The bond potential is zero and thus its force also
zero for distances :math:`r > r_c`. The potential energy has the value
:math:`-U_{\text{min}}` at :math:`r_0` and zero at :math:`r_c`.
The equivalent spring constant value *K* for use with :doc:`bond_style
harmonic <bond_harmonic>` for :math:`r <= r_c`, can be computed using
:math:`K = U_{\text{min}} / [(r_0-r_c)^2]`
The following coefficients must be defined for each bond type via the
:doc:`bond_coeff <bond_coeff>` command as in the example above, or in

View File

@ -94,7 +94,7 @@ the data file or restart files read by the :doc:`read_data
<read_data>` or :doc:`read_restart <read_restart>` commands:
* :math:`k` (force/distance units)
* :math:`\epsilon_c` (unit less)
* :math:`\epsilon_c` (unitless)
* :math:`\gamma` (force/velocity units)
Unlike other BPM-style bonds, this bond style does not update special

View File

@ -10,7 +10,7 @@ Syntax
bond_style style args
* style = *none* or *zero* or *hybrid* or *bpm/rotational* or *bpm/spring* or *class2* or *fene* or *fene/expand* or *fene/nm* or *gaussian* or *gromos* or *harmonic* or *harmonic/restrain* *harmonic/shift* or *harmonic/shift/cut* or *lepton* or *morse* or *nonlinear* or *oxdna/fene* or *oxdena2/fene* or *oxrna2/fene* or *quartic* or *special* or *table*
* style = *none* or *zero* or *hybrid* or *bpm/rotational* or *bpm/spring* or *bpm/spring/plastic* or *class2* or *fene* or *fene/expand* or *fene/nm* or *gaussian* or *gromos* or *harmonic* or *harmonic/restrain* *harmonic/shift* or *harmonic/shift/cut* or *lepton* or *morse* or *nonlinear* or *oxdna/fene* or *oxdena2/fene* or *oxrna2/fene* or *quartic* or *special* or *table*
* args = none for any style except *hybrid*
@ -86,6 +86,7 @@ accelerated styles exist.
* :doc:`bpm/rotational <bond_bpm_rotational>` - breakable bond with forces and torques based on deviation from reference state
* :doc:`bpm/spring <bond_bpm_spring>` - breakable bond with forces based on deviation from reference length
* :doc:`bpm/spring/plastic <bond_bpm_spring_plastic>` - a similar breakable bond with plastic yield
* :doc:`class2 <bond_class2>` - COMPASS (class 2) bond
* :doc:`fene <bond_fene>` - FENE (finite-extensible non-linear elastic) bond
* :doc:`fene/expand <bond_fene_expand>` - FENE bonds with variable size particles

View File

@ -82,6 +82,7 @@ Commands
read_dump
read_restart
region
region2vmd
replicate
rerun
reset_atoms

View File

@ -356,6 +356,7 @@ The individual style names on the :doc:`Commands compute <Commands_compute>` pag
* :doc:`ti <compute_ti>` - thermodynamic integration free energy values
* :doc:`torque/chunk <compute_torque_chunk>` - torque applied on each chunk
* :doc:`vacf <compute_vacf>` - velocity auto-correlation function of group of atoms
* :doc:`vacf/chunk <compute_vacf_chunk>` - velocity auto-correlation for the center of mass velocities of chunks of atoms
* :doc:`vcm/chunk <compute_vcm_chunk>` - velocity of center-of-mass for each chunk
* :doc:`viscosity/cos <compute_viscosity_cos>` - velocity profile under cosine-shaped acceleration
* :doc:`voronoi/atom <compute_voronoi_atom>` - Voronoi volume and neighbors for each atom

View File

@ -217,13 +217,16 @@ scaled differently in the two different dimensions to transform them
into ellipses).
The created bins (and hence the chunk IDs) are numbered consecutively
from 1 to the number of bins = *Nchunk*\ . For *bin2d* and *bin3d*, the
numbering varies most rapidly in the first dimension (which could be
*x*, *y*, or *z*), next rapidly in the second dimension, and most slowly in the
third dimension. For *bin/sphere*, the bin with smallest radii is chunk
1 and the bin with largest radii is chunk Nchunk = *ncbin*\ . For
*bin/cylinder*, the numbering varies most rapidly in the dimension
along the cylinder axis and most slowly in the radial direction.
from 1 to the number of bins = *Nchunk*\ . For *bin2d* and *bin3d*, the
numbering varies fastest in the last dimension (which could be
*x*, *y*, or *z*), slower in the second dimension, and slowest in the
first dimension. For *bin/sphere*, the bin with smallest radius is chunk
1 and the bin with largest radius is chunk Nchunk = *ncbin*\ . For
*bin/cylinder*, the numbering varies faster in the dimension
along the cylinder axis and slower in the radial direction.
In all cases, for a given dimension, the numbering increases
with increasing value of the coordinate (Cartesian coordinate,
sphere or cylinder radius, axial position).
Each time this compute is invoked, each atom is mapped to a bin based
on its current position. Note that between reneighboring timesteps,

View File

@ -67,7 +67,7 @@ following relation should also be satisfied:
.. math::
r_c + r_s > 2*{\rm cutoff}
r_c + r_s > 2*\mathrm{cutoff}
where :math:`r_c` is the cutoff distance of the potential, :math:`r_s`
is the skin

View File

@ -74,7 +74,7 @@ following relation should also be satisfied:
.. math::
r_c + r_s > 2*{\rm cutoff}
r_c + r_s > 2*\mathrm{cutoff}
where :math:`r_c` is the cutoff distance of the potential, :math:`r_s` is
the skin

Some files were not shown because too many files have changed in this diff Show More