科研 Skill

分子动力学力场选型验证

md-force-fields

Covers selection, validation, and deployment of classical interatomic force fields for MD: physical basis and transferability limits of EAM, MEAM, Tersoff. Use when choosing a force field.

发布者 Codar安全审核通过v0.1.0更新于 2026-11-18

SKILL.md

MD Force Fields

Description

This skill covers selection, validation, and deployment of interatomic force fields for molecular dynamics: the physical basis and transferability limits of every major functional form (EAM, MEAM, Tersoff, Stillinger-Weber, Buckingham, COMB, ReaxFF, AMBER, CHARMM, OPLS, GROMOS, and ML potentials); parameter-file sourcing and provenance verification; unit and format compatibility across LAMMPS, GROMACS, OpenMM, and ASE; mixing rules, long-range electrostatics, cutoff conventions, neighbor-list settings, and bonded constraints; and validation of any force field against DFT, experiment, or higher-level simulation. Invoke this skill when selecting a force field for a new system, diagnosing a simulation failure that may originate from a wrong or misapplied force field, or verifying the transferability of an existing parameterization to a new application domain.

Domain Context

A force field is a function that maps a set of atomic positions {rᵢ} to a potential energy U({rᵢ}) and, by differentiation, to forces Fᵢ = -∂U/∂rᵢ. Every force field encodes assumptions about which physical interactions are important and which are negligible. These assumptions are baked into the functional form; they cannot be corrected by changing parameter values alone.

The central issue with force fields is transferability: a parameterization fitted to reproduce a set of reference properties in one regime is not guaranteed to be accurate in a different regime. The reference data (crystal structures, elastic constants, bond lengths, heats of formation, vibrational frequencies) used to fit the parameters determines the validity domain. Using the force field outside that domain is extrapolation — the errors are unbounded and often silent.

Hierarchy of approximations, from most to least severe:

  1. Born-Oppenheimer surface: All classical force fields assume the ground-state PES. Electronically excited states, non-adiabatic dynamics, metallic-band effects on bonding, and charge-transfer-driven structural changes are outside the Born-Oppenheimer classical picture entirely.
  2. Fixed topology vs. reactive: Fixed-topology force fields (AMBER, CHARMM, EAM, Tersoff) assign bonds at the start of the simulation and never break or form them. Reactive force fields (ReaxFF, COMB) allow bond-order to vary continuously. ML potentials can be either reactive or non-reactive depending on the training data.
  3. Many-body vs. pairwise: Pure pairwise potentials (LJ, Buckingham) cannot reproduce the Cauchy pressure discrepancy in metals (C₁₂ ≠ C₄₄) or the angular dependence of covalent bonds. Many-body terms (EAM embedding energy, Tersoff bond-order, AMBER dihedral) correct specific deficiencies but add parameters.
  4. Classical nuclei: All MD force fields integrate classical equations of motion. Zero-point energy and nuclear tunneling are neglected. This fails for light atoms (H, He, Li) at low temperature.
  5. Mean-field charges: Classical force fields use fixed partial charges (AMBER, CHARMM) or fluctuating charges (ReaxFF QEq, COMB). Neither is a first-principles electron density; both fail when charge delocalization or metallic screening becomes important.

The parameter-provenance problem: Two LAMMPS input files can both say pair_style eam and produce physically different results because the .eam parameter file version differs. Published force fields are revised between papers; parameters with the same name from different sources are not identical. Always record the exact parameter file, its SHA-256 hash, and the primary publication in every simulation directory.

When to Use This Skill

  • Selecting a force-field functional form for a new system or application, before setting up any LAMMPS or GROMACS input.
  • Verifying that a force-field parameter file obtained from a repository or collaborator is the correct version for the intended application.
  • Diagnosing a simulation failure (energy explosion, wrong density, incorrect melting temperature, spurious phase transition) that may originate from a misapplied or out-of-domain force field.
  • Determining whether a classical force field, reactive force field, or ML potential is appropriate given the simulation goals, system, and available computational resources.
  • Validating a literature or community force field against DFT reference data before using it for production property calculations.
  • Porting a force field between codes (LAMMPS → GROMACS → OpenMM → ASE) and verifying that energies and forces are consistent after conversion.

When Not to Use This Skill

  • When the required property is fundamentally electronic. Band gaps, optical spectra, magnetic ordering, Mott localization, and electronically driven phase transitions require DFT or TDDFT regardless of system size. No classical force field, including ML potentials, can predict these properties unless explicitly trained on electronic labels.
  • When an ML potential has already been validated for the exact system and conditions. If a MACE or NequIP model has been trained and validated (see mlp-validation) for the target composition and temperature range, it supersedes classical force-field selection for that system. Use this skill only to decide whether to use the ML potential or to fall back to a cheaper classical potential for initial equilibration.
  • When bond breaking or forming is needed but ReaxFF has not been parameterized and validated for the system. An unvalidated reactive potential is more dangerous than an admittedly non-reactive classical potential — the wrong chemistry is worse than no chemistry at all. If no validated reactive FF exists, use DFT-MD or ML potentials trained on reactive trajectories.
  • For coarse-grained simulations. Martini, SIRAH, and other CG force fields operate on groups of atoms, not individual atoms. Their parameterization and transferability differ qualitatively from atomistic force fields; their deployment follows different protocols.

Core Concepts

  • Functional form: The mathematical expression for U({rᵢ}). The functional form is fixed; it determines what physics can be reproduced and what cannot. Parameters are fitted to reference data but cannot compensate for a missing physical term (e.g., a pairwise potential cannot reproduce the correct Cauchy pressure ratio in a metal, regardless of parameter choice).
  • Parameterization domain: The set of structures, compositions, temperatures, and pressures for which the parameters were fitted. Structures outside this domain are extrapolations. For EAM potentials, the domain is typically the equilibrium crystal structure, point defects, and phonons at moderate temperatures. For AMBER ff14SB, the domain is standard protein residues in water near physiological conditions.
  • Transferability: The degree to which a force field retains accuracy outside its parameterization domain. EAM potentials for pure metals have moderate transferability to grain boundaries and surfaces. CHARMM36 has low transferability to non-standard ligands (use CGENFF for those). ML potentials have higher intrinsic flexibility but limited transferability outside the training composition space.
  • Pair potential: A contribution U(rᵢⱼ) that depends only on the scalar distance between atoms i and j. Computationally cheap; misses angular and many-body effects. Lennard-Jones, Buckingham, Coulomb, and Morse are pairwise.
  • Embedding energy (EAM): U = Σᵢ F(ρ̄ᵢ) + ½ Σᵢⱼ φ(rᵢⱼ), where ρ̄ᵢ = Σⱼ ρ(rᵢⱼ) is the local electron density at site i and F is the embedding energy. Captures metallic bonding (non-directional, many-body) without explicit electron density. Valid for FCC and BCC metals near equilibrium.
  • Bond-order potential (Tersoff, REBO): The pair repulsion/attraction strength is modulated by a bond-order function bᵢⱼ that depends on the coordination environment of atoms i and j. Captures directional covalent bonding (Si, Ge, C, SiC). The cutoff function introduces a smooth decay but can produce spurious forces near the cutoff if a coordination shell boundary falls within it.
  • Bonded force field (molecular mechanics): U = Σ bonds k_b(r-r₀)² + Σ angles k_θ(θ-θ₀)² + Σ dihedrals V_n(1+cos(nφ-γ)) + Σ impropers + Σ nonbonded. The bond list is fixed at the start of the simulation. Requires a topology file (data file in LAMMPS, .top in GROMACS). The nonbonded interactions between atoms separated by 1–2 bonds are excluded; 1–3 may be excluded; 1–4 use scaled interactions (AMBER: fudgeLJ=0.5, fudgeQQ=0.8333; CHARMM: different defaults).
  • Long-range electrostatics: Coulomb interactions decay as 1/r and cannot be truncated at a short cutoff without introducing large artifacts in polar, ionic, or biomolecular systems. Particle Mesh Ewald (PME) or Particle-Particle Particle-Mesh (P³M/PPPM) sums the real-space short-range part and the reciprocal-space long-range part with O(N log N) cost. Required for any system with net partial charges; not needed for pure metals or neutral LJ systems. The real-space cutoff rcoulomb and k-space accuracy must be set consistently.
  • Mixing rules: For pairs of unlike atoms in a pairwise LJ or Buckingham potential, parameters are derived from like-pair parameters using combining rules. Lorentz-Berthelot: σᵢⱼ = (σᵢ + σⱼ)/2, εᵢⱼ = √(εᵢεⱼ). Geometric: σᵢⱼ = √(σᵢσⱼ), εᵢⱼ = √(εᵢεⱼ). Waldman-Hagler: for noble gases. The mixing rule is part of the force-field definition; mixing rules from one force field must not be applied to parameters from another. AMBER uses Lorentz-Berthelot; OPLS-AA uses geometric (for σ) + geometric (for ε). Using the wrong mixing rule changes cross-pair interactions by up to 30%.
  • ReaxFF charge equilibration (QEq): ReaxFF assigns fluctuating charges by minimizing a charge-dependent energy functional at every timestep via the electronegativity equalization principle. In LAMMPS this is a separate fix (fix qeq/reaxff). QEq can fail if the system undergoes charge separation that exceeds the QEq damping radius, or if the parameter file's electronegativity parameters are physically inconsistent for the system.
  • SHAKE/LINCS constraints: High-frequency bond vibrations (O-H, C-H, N-H) require sub-femtosecond timesteps unless constrained. SHAKE (LAMMPS, older GROMACS) and LINCS (GROMACS preferred) constrain bond lengths to their equilibrium values, eliminating the highest-frequency vibrational modes and allowing 2 fs timesteps for bonded systems. Constraints modify the equations of motion; they must be used consistently with the force-field parameterization (AMBER ff14SB was parameterized assuming H-bond constraints).
  • Special bonds / 1-4 scaling: In molecular force fields, nonbonded interactions between atoms in 1-4 position (separated by three bonds) are scaled rather than excluded. AMBER: 1-4 LJ × 0.5, 1-4 Coulomb × 0.8333. CHARMM: all 1-4 included at full weight but pair parameters adjusted during fitting. OPLS-AA: 1-4 LJ × 0.5, 1-4 Coulomb × 0.5. Mixing these scaling factors across force fields is a frequent source of systematic energy errors.

Key Workflows

Full steps for each part are in references/key-workflows/; open the one you need:

Common Failure Modes

Moved to references/common-failure-modes.md to keep this file short; read it when this part is needed.

Best Practices

  • Validate every force field on your specific system before production, regardless of reputation. A force field that is well-validated for one alloy composition may give 50% error in lattice parameter for a 10-at.% compositional variant. Spend one day on validation before spending one month on production.
  • Record SHA-256 hashes and full citations for every parameter file. sha256sum filename > filename.sha256. Store this alongside the simulation directory. Parameter files update silently; the file hash is the only reliable version identifier.
  • Match the units command to the force field — this is not negotiable. EAM, Tersoff, MACE, NequIP, CHGNet: units metal. AMBER, CHARMM, GAFF, OPLS-AA in LAMMPS: units real. ReaxFF: units real. Buckingham for oxides: units metal (if parameters are in eV/Å). GROMACS always uses nm/kJ/mol/ps internally regardless of what the original FF uses.
  • For molecular force fields, use CHARMM-GUI or AmberTools to build the topology. Manually constructing GROMACS .top files or LAMMPS data files for proteins, lipids, or drug-like molecules is error-prone. CHARMM-GUI validates topology against the force-field database and outputs consistent parameter, coordinate, and script files.
  • Never mix parameters from different force fields unless explicitly supported. AMBER partial charges are not compatible with CHARMM partial charges. OPLS-AA LJ parameters use geometric mixing; combining them with AMBER LJ parameters under Lorentz-Berthelot mixing is not physical. If you need cross-FF interactions (e.g., protein in CHARMM + surface in Tersoff), the interface interaction must be parameterized explicitly.
  • For ReaxFF: use exactly one ffield.reax file, from exactly one publication, for a system it was validated on. ReaxFF parameters are globally coupled — element electronegativity, bond order, and angular terms are all interdependent. Importing one element's parameters from a different ffield.reax file invalidates the rest of the parameterization.
  • Always verify the 1-4 nonbonded scaling factors match the force field definition. This requires checking the LAMMPS special_bonds line or the GROMACS .top [defaults] section against the force-field documentation. A wrong scaling factor introduces a systematic error in all dihedral-containing conformational preferences.
  • For ML potentials as force fields: run the NVE energy conservation test before any production NPT. MACE, NequIP, and DeePMD all require this check — a trained model can still have unphysical high-energy configurations near the boundary of the training set that inject energy and destabilize the trajectory. See mlp-validation for the protocol.
  • Use the NIST Interatomic Potentials Repository as the primary source for materials force fields. The repository (https://www.ctcms.nist.gov/potentials/) stores validated parameter files with metadata, source publications, and verified properties. Prefer it over files distributed with simulation codes (which may be outdated) or informal sources.
  • For universal ML potentials (MACE-MP-0, CHGNet, M3GNet): validate before production even though they are pre-trained. These models cover broad composition space but may be less accurate for unusual coordination environments, high-pressure phases, or systems at the edge of the Materials Project training distribution. Always compare a₀, B₀, and phonon frequencies to DFT for the specific composition before committing to production. [EXPERT REVIEW NEEDED]

Integration with Other Skills

  • lammps-workflow: That skill covers the full LAMMPS input-script mechanics (pair_style, pair_coeff, units, atom_style, neighbor lists, and restart protocol). This skill specifies which pair_style to choose and why, and what the parameter files mean physically. Use both skills together: this one for force-field selection and validation, that one for input-script construction.
  • md-equilibration: A common symptom of a misapplied force field is failure to equilibrate — the thermostat masks force-field errors by continuously injecting or removing energy. That skill's NVE energy-drift test is the most reliable way to detect force-field problems that the thermostat is compensating: if total energy drifts in NVE after correct equilibration, the force field or timestep is wrong.
  • md-analysis: Structural observables (RDF peak position, coordination number, lattice parameter from MSD plateau) computed in that skill are the primary runtime diagnostics for force-field validity. If the RDF first peak is at the wrong distance or the coordination number is physically impossible, the force field is misapplied.
  • gromacs-workflow: GROMACS uses .top/.itp topology files and .mdp parameter files in nm/kJ/mol units. The topology construction, charge assignment, and constraint protocol for AMBER/CHARMM in GROMACS are covered in that skill; this skill provides the physical rationale for each choice.
  • reactive-md: ReaxFF and COMB — the reactive force fields described here — are deployed in LAMMPS with constraints and analysis tools described in that skill. That skill covers species-tracking, reaction-event detection, and validation of bond-breaking kinetics against DFT reaction pathways.
  • mlp-validation: The validation protocol in this skill (EOS, phonons, force MAE on DFT test set) is identical to the protocol for ML potentials in that skill. When an ML potential is used as a drop-in replacement for a classical force field, all of this skill's validation checks apply equally. That skill additionally covers NVE MD stability and LAMMPS vs. ASE consistency.
  • mlp-to-lammps: Deploying MACE, NequIP, or DeePMD as a force field in LAMMPS — including compilation flags, pair_style invocation syntax, no_domain_decomposition requirement, element-ordering convention, and GPU parallelization limits — is covered in detail in that skill.
  • mace-training: When classical force fields are insufficient for the target system and no universal MLP covers the composition, training a custom MACE model is the next option. That skill covers dataset construction, training hyperparameters, and model selection. This skill's validation workflows (EOS, force MAE, phonons) apply directly to the trained model.
  • active-learning-mlp: One motivation for active learning is the inadequacy of classical force fields for a particular configuration space. A classical force field can be used for cheap initial exploration to identify likely thermodynamically accessible configurations, which are then added to the DFT training set for an MLP. The force-field accuracy requirements for this seeding role are lower than for production property calculations.
  • universal-potentials: MACE-MP-0, CHGNet, M3GNet, and ORB are drop-in force-field replacements that cover broad inorganic composition space. This skill provides the decision logic for when to use a universal potential vs. a classical FF vs. a custom-trained MLP; that skill covers the practical deployment, accuracy benchmarks, and known failure modes of each universal model.
  • dft-convergence: All force-field validation against DFT requires converged DFT reference calculations. Energy, force, and stress labels used for validation must be computed at the same ENCUT, k-point density, and POTCAR as used for training data. Inconsistent DFT convergence between validation reference and training data inflates apparent force-field errors.
  • vasp-workflow: DFT reference calculations for EOS, elastic constants, phonons, and per-structure force validation are typically run with VASP. The ISIF tag (ISIF=2 for fixed-cell force calculations, ISIF=3 for full relaxation) and the stress sign convention (VASP: compression-positive, must be negated for ASE) are covered in that skill and must be applied consistently when building validation datasets.

Key References

  1. Daw, M. S. & Baskes, M. I. (1984). Embedded-atom method: Derivation and application to impurities, surfaces, and other defects in metals. Physical Review B, 29(12), 6443–6453. https://doi.org/10.1103/PhysRevB.29.6443
  2. Tersoff, J. (1988). New empirical approach for the structure and energy of covalent systems. Physical Review B, 37(12), 6991–7000. https://doi.org/10.1103/PhysRevB.37.6991
  3. van Duin, A. C. T., et al. (2001). ReaxFF: A reactive force field for hydrocarbons. Journal of Physical Chemistry A, 105(41), 9396–9409. https://doi.org/10.1021/jp004368u
  4. Cornell, W. D., et al. (1995). A second generation force field for the simulation of proteins, nucleic acids, and organic molecules. Journal of the American Chemical Society, 117(19), 5179–5197. https://doi.org/10.1021/ja00124a002
  5. MacKerell, A. D., et al. (1998). All-atom empirical potential for molecular modeling and dynamics studies of proteins. Journal of Physical Chemistry B, 102(18), 3586–3616. https://doi.org/10.1021/jp973084f
  6. Becker, C. A., et al. (2013). Considerations for choosing and using force fields and interatomic potentials in materials science and engineering. Current Opinion in Solid State and Materials Science, 17(6), 277–283. https://doi.org/10.1016/j.cossms.2013.10.001
  7. Mishin, Y., et al. (1999). Interatomic potentials for monoatomic metals from experimental data and ab initio calculations. Physical Review B, 59(5), 3393–3407. https://doi.org/10.1103/PhysRevB.59.3393
  8. Jorgensen, W. L., et al. (1996). Development and testing of the OPLS all-atom force field on conformational energetics and properties of organic liquids. Journal of the American Chemical Society, 118(45), 11225–11236. https://doi.org/10.1021/ja9621760

示例提示词

帮我为这个反应性体系挑选合适的ReaxFF力场参数并验证可迁移性。

所属插件

计算材料学:第一性原理与原子模拟面向计算材料研究:DFT 与第一性原理(VASP、Quantum ESPRESSO、CP2K、AiiDA)、缺陷/表面/声子/弹性常数、机器学习势函数训练与验证、分子动力学与增强采样、晶体性质图神经网络与生成模型。

安装该插件会一并获得同领域的 35 个 Skill / MCP。

同插件的其他科研 Skill

常见问题

分子动力学力场选型验证能做什么?

Covers selection, validation, and deployment of classical interatomic force fields for MD: physical basis and transferability limits of EAM, MEAM, Tersoff. Use when choosing a force field。

如何安装分子动力学力场选型验证?

在科搭 Codar 左侧点击「插件」,在「组件」页签搜索「分子动力学力场选型验证」并安装;在 Claude Code 或 Codex 中可以发送本页的安装提示词,或下载 Skill 包后解压到 ~/.claude/skills 或 ~/.codex/skills。

分子动力学力场选型验证需要哪些权限?

该科研 Skill没有声明额外权限;执行具体操作时仍由 Agent 按自身规则请求确认。

分子动力学力场选型验证经过官方审核吗?

是。SpeedSkills 收录的每个版本都会记录内容摘要与权限声明,当前版本已通过安全审核。