| name | vibeflow-lammps |
| description | Use when preparing, running, debugging, post-processing, or extending VibeFlow/VibeCAE LAMMPS molecular dynamics and particle simulation workflows from 0-caseDict/caseDict, including LAMMPS input scripts, data files, potentials, fixes, computes, dumps, restarts, Python post-processing, and optional custom LAMMPS package or style development. |
VibeFlow LAMMPS
This skill is responsible for using LAMMPS as VibeCAE's backend for molecular dynamics, particulate systems, material microscale simulation, and coarse-grained particle simulation.
- Usage mode: generate LAMMPS inputs, data, potential configuration, run scripts, and post-processing from
0-caseDict/caseDict.
- Development mode: develop reusable LAMMPS workflows, input templates, Python analysis tools, or custom styles/packages when explicitly needed.
When to Use
- The user task involves molecular dynamics, particulate systems, atomistic materials, soft matter, heat transport, diffusion, collision, deposition, or coarse-grained particle simulation.
in.* input scripts, data.* structure files, potential file references, dump, compute, fix, or thermo_style need to be generated or repaired.
- MD results need to be converted into trajectories, statistics, radial distribution functions, mean-square displacement, stress-strain curves, thermal conductivity, diffusion coefficients, or similar quantities.
- LAMMPS results need to be weakly coupled with, or handed off as data to, continuum CAE workflows.
First Decide: Usage Mode or Development Mode
- If only the current case needs to be configured, run with LAMMPS, and post-processed: use usage mode.
- If Python data processors, template generators, batch parameter sweeps, coupling interfaces, or custom LAMMPS styles are needed: use development mode.
- If
lmp, MPI, shared libraries, or package availability are abnormal: switch to vibeflow-toolchain first.
- If an initial particle distribution must be generated from CAD or mesh data: switch first to the relevant geometry or mesh skill.
What to Read First
- The physical system, materials, particle/atom species, boundaries, initial conditions, thermodynamic ensemble, run controls, and post-processing objectives in
0-caseDict/caseDict.
references/lammps-playbook.md
references/lammps-practical-tips.md: software knowledge base, key concepts, failure interpretation, and adapter design points.
- Existing potentials, structure files, or reference inputs under
C-run/lammps/, D-post/, and Ref/.
Inputs
0-caseDict/caseDict
- LAMMPS data files, molecule files, potential files, and restart files
- User-provided material parameters, lattices, particle-size distributions, temperature/pressure conditions, loading paths, and time scales
Outputs
C-run/lammps/case-*/in.case
C-run/lammps/case-*/data.*
C-run/lammps/case-*/potentials/
C-run/lammps/case-*/Allrun and Allclean
C-run/lammps/case-*/logs/
C-run/lammps/case-*/dumps/
D-post/lammps_postprocess.py
- Charts, statistics tables, converted trajectory artifacts, and result notes
Recommended Structure
C-run/lammps/
└── case-1/
├── in.case
├── data.system
├── potentials/
├── dumps/
├── restarts/
├── logs/
├── Allrun
└── Allclean
D-post/
└── lammps_postprocess.py
Usage Mode Workflow
- Map the unified physical description in
caseDict to LAMMPS concepts: units, atom_style, boundary, region, group, pair_style, bond_style, fix, and compute.
- Clarify the potential source and applicability; do not use a potential that merely looks similar but does not match the physical system.
- Generate
in.case and data files; before running, check units, time step, neighbor list, thermostat/barostat method, and output frequency.
- Write
Allrun, preferably selecting the LAMMPS executable through an environment variable instead of hard-coding a local path.
- Run a short-step smoke test, confirming that the input parses, initializes, and produces no
ERROR.
- During the production run, record logs, dumps, restarts, and key thermo outputs.
- Use
D-post/lammps_postprocess.py to read logs or dumps and extract the physical quantities that the user actually cares about.
- Write artifacts, assumptions, potential sources, and error status back to
caseDict.
Development Mode Workflow
- Define the development target: template generator, Python analyzer, coupling interface, custom fix/compute/pair style, or batch-processing tool.
- Write development notes first, recording the LAMMPS version, package dependencies, input interface, output interface, and validation examples.
- For custom styles, prefer an independent development directory and do not directly pollute the system LAMMPS source; modify upstream source only when the user explicitly asks for it.
- Provide units, defaults, error messages, and a minimal example for every new input keyword.
- Use at least one tiny system for a loading or run smoke test.
Core Rules
- The LAMMPS input script is an execution artifact;
caseDict is the source of truth for case intent.
- Potential functions must record their source, version, applicable elements or particle types, unit system, and limitations.
- Time step, thermostat, barostat, constraints, walls, and contact models must be consistent with
units.
- Do not judge correctness only by "it runs"; also check whether energy, temperature, pressure, particle count, and boundary conditions are reasonable.
- Large dump files should not be fully loaded into memory by default; post-processing should stream chunks or read only necessary fields.
Validation
- The LAMMPS executable is available.
in.case can parse and initialize.
- The smoke test has no
ERROR, no obvious NaN, and no lost particles.
- Thermo output contains the required monitored quantities.
D-post can generate target charts from logs or dumps.
Fallback Rules
- Physical system, potential, or units are unclear: return to
vibeflow-case-dict
- LAMMPS environment is unavailable: return to
vibeflow-toolchain
- Post-processing charts are insufficient to support the conclusion: return to the post-processing step in this skill
- Continuum CFD/FEM is needed: hand off to the corresponding OpenFOAM, SU2, Code_Aster, Elmer, CalculiX, or similar skill