# lammps-inputs-and-modeling > This skill should be used when users ask about inputs and modeling in lammps; it prioritizes documentation references and then source inspection only for unresolved details. - Author: Tao E. Li - Repository: TEL-Research-Group/lammps - Version: 20260207223556 - Stars: 0 - Forks: 0 - Last Updated: 2026-02-08 - Source: https://github.com/TEL-Research-Group/lammps - Web: https://mule.run/skillshub/@@TEL-Research-Group/lammps~lammps-inputs-and-modeling:20260207223556 --- --- name: lammps-inputs-and-modeling description: This skill should be used when users ask about inputs and modeling in lammps; it prioritizes documentation references and then source inspection only for unresolved details. --- # lammps: Inputs and Modeling ## High-Signal Playbook ### Route the request - Use `lammps-simulation-workflows` for run segmentation, restart chaining, and production sequencing. - Use `lammps-analysis-and-output` for thermo/dump schema and post-processing outputs. - Use `lammps-troubleshooting` for bad dynamics (lost atoms, NaN/Inf, unstable pressure). - Use `lammps-parallel-hpc` when setup choices are constrained by hardware scaling. ### Triage questions - Which `units` style is mandated by the force field or potential file? - Which `atom_style` matches required per-atom attributes/topology? - Is geometry built with `create_box/create_atoms` or read from `read_data`? - Are long-range electrostatics needed (`coul/long` + `kspace_style`)? - Is topology molecular (bond/angle/dihedral/improper) or atomic? - Are multiple subsystems/data files being merged with offsets/shifts? ### Canonical workflow - Set immutable pre-box commands first: `units`, `atom_style`, `boundary` (`doc/src/units.rst`, `doc/src/atom_style.rst`, `doc/src/boundary.rst`). - Create/read the system (`doc/src/read_data.rst`, `doc/src/create_box.rst`, `doc/src/create_atoms.rst`). - Define force-field styles and coefficients (`doc/src/pair_style.rst`, `doc/src/pair_coeff.rst`, bonded style docs). - Add long-range solver when required and ensure compatible pair style (`doc/src/kspace_style.rst`). - Configure neighbor behavior conservatively first (`doc/src/neighbor.rst`, `doc/src/neigh_modify.rst`). - Choose timestep and initialize velocities (`doc/src/timestep.rst`, `doc/src/velocity.rst`). - Run short relaxation, then tighten settings for production (`doc/src/run.rst`). ### Minimal working examples - Data-driven charged setup (`doc/src/read_data.rst`, `doc/src/kspace_style.rst`): ```LAMMPS units real atom_style full boundary p p p read_data data.system pair_style lj/cut/coul/long 10.0 pair_coeff 1 1 0.1553 3.166 kspace_style pppm 1.0e-4 neighbor 2.0 bin neigh_modify every 1 delay 0 check yes timestep 1.0 ``` - Multiple data-file assembly pattern (`doc/src/read_data.rst`): ```LAMMPS read_data data.substrate extra/atom/types 4 read_data data.fluid add append offset 2 0 0 0 0 shift 0.0 0.0 50.0 ``` ### Pitfalls - Mismatch between potential-file units and `units` setting (`doc/src/units.rst`, `doc/src/pair_coeff.rst`). - `pair_style` not set before reading data-file coefficient sections (`doc/src/Run_formats.rst`, `doc/src/read_data.rst`). - `atom_style` too narrow for topology (e.g., missing molecule/charge fields) (`doc/src/atom_style.rst`). - Aggressive `neigh_modify` settings causing missing interactions (`doc/src/neigh_modify.rst`). - Using `neigh_modify exclude` with long-range KSpace and expecting exact cancellation (`doc/src/neigh_modify.rst`). ### Convergence and validation checklist - Validate force-field completeness for all type pairs and bonded terms. - Confirm no lost atoms, no missing bonded-atom warnings, and stable thermo values. - Check sensitivity to timestep and neighbor skin on short A/B runs. - Verify target observables (density, pressure, energy components) are physically consistent. ## Scope - Handle questions about inputs, system setup, models, and physical parameterization. - Keep responses abstract and architectural for large codebases; avoid exhaustive per-function documentation unless requested. ## Primary documentation references - `doc/src/Run_formats.rst` - `doc/src/units.rst` - `doc/src/atom_style.rst` - `doc/src/boundary.rst` - `doc/src/read_data.rst` - `doc/src/create_box.rst` - `doc/src/create_atoms.rst` - `doc/src/pair_style.rst` - `doc/src/pair_coeff.rst` - `doc/src/kspace_style.rst` - `doc/src/neighbor.rst` - `doc/src/neigh_modify.rst` ## Workflow - Start with the primary references above. - If details are missing, inspect `references/doc_map.md` for additional topic documents (generated inventory plus curated anchors). - Use tutorials/examples as executable usage patterns when available. - Use tests as behavior or regression references when available. - If ambiguity remains after docs, inspect `references/source_map.md` and start with the ranked source entry points. - Cite exact documentation file paths in responses. ## Tutorials and examples - `examples` ## Test references - None discovered. ## Optional deeper inspection - `fortran` - `lib` - `python` - `src` ## Source entry points for unresolved issues - `src/APIP/pair_lambda_input_csp_apip.h` - `src/APIP/pair_lambda_input_csp_apip.cpp` - `src/APIP/pair_lambda_input_apip.h` - `src/APIP/pair_lambda_input_apip.cpp` - `src/compute_heat_flux.h` - `src/compute_heat_flux.cpp` - `src/APIP/pair_lambda_zone_apip.h` - `src/APIP/pair_lambda_zone_apip.cpp` - Prefer targeted source search (for example: `rg -n "" fortran lib python src`).