diff --git a/doc/src/Section_commands.txt b/doc/src/Section_commands.txt index 1aed719d73..3a3ef81916 100644 --- a/doc/src/Section_commands.txt +++ b/doc/src/Section_commands.txt @@ -618,6 +618,7 @@ package"_Section_start.html#start_3. "drude/transform/reverse"_fix_drude_transform.html, "eos/cv"_fix_eos_cv.html, "eos/table"_fix_eos_table.html, +"eos/table/rx"_fix_eos_table_rx.html, "gle"_fix_gle.html, "imd"_fix_imd.html, "ipi"_fix_ipi.html, @@ -646,6 +647,7 @@ package"_Section_start.html#start_3. "qtb"_fix_qtb.html, "reax/c/bonds"_fix_reax_bonds.html, "reax/c/species"_fix_reaxc_species.html, +"rx"_fix_rx.html, "saed/vtk"_fix_saed_vtk.html, "shardlow"_fix_shardlow.html, "smd"_fix_smd.html, @@ -934,6 +936,7 @@ package"_Section_start.html#start_3. "eam/cd (o)"_pair_eam.html, "edip (o)"_pair_edip.html, "eff/cut"_pair_eff.html, +"exp6/rx"_pair_exp6_rx.html, "gauss/cut"_pair_gauss.html, "lennard/mdf"_pair_mdf.html, "list"_pair_list.html, @@ -955,6 +958,7 @@ package"_Section_start.html#start_3. "morse/smooth/linear"_pair_morse.html, "morse/soft"_pair_morse.html, "multi/lucy"_pair_multi_lucy.html, +"multi/lucy/rx"_pair_multi_lucy_rx.html, "quip"_pair_quip.html, "reax/c"_pair_reax_c.html, "smd/hertz"_pair_smd_hertz.html, @@ -969,6 +973,7 @@ package"_Section_start.html#start_3. "sph/taitwater"_pair_sph_taitwater.html, "sph/taitwater/morris"_pair_sph_taitwater_morris.html, "srp"_pair_srp.html, +"table/rx"_pair_table_rx.html, "tersoff/table (o)"_pair_tersoff.html, "thole"_pair_thole.html, "tip4p/long/soft (o)"_pair_lj_soft.html :tb(c=4,ea=c) diff --git a/doc/src/atom_style.txt b/doc/src/atom_style.txt index 6415542230..95038b74fb 100644 --- a/doc/src/atom_style.txt +++ b/doc/src/atom_style.txt @@ -132,9 +132,13 @@ position, which is represented by the eradius = electron size. For the {peri} style, the particles are spherical and each stores a per-particle mass and volume. -The {dpd} style is for dissipative particle dynamics (DPD) particles -which store the particle internal temperature (dpdTheta), internal -conductive energy (uCond) and internal mechanical energy (uMech). +The {dpd} style is for dissipative particle dynamics (DPD) particles. +Note that it is part of the USER-DPD package, and is not for use with +the "pair_style dpd or dpd/stat"_pair_dpd.html commands, which can +simply use atom_style atomic. Atom_style dpd extends DPD particle +properties with internal temperature (dpdTheta), internal conductive +energy (uCond), internal mechanical energy (uMech), and internal +chemical energy (uChem). The {meso} style is for smoothed particle hydrodynamics (SPH) particles which store a density (rho), energy (e), and heat capacity diff --git a/doc/src/compute_dpd.txt b/doc/src/compute_dpd.txt index d1e1d270fb..fb0493d8e2 100644 --- a/doc/src/compute_dpd.txt +++ b/doc/src/compute_dpd.txt @@ -23,7 +23,7 @@ compute 1 all dpd :pre Define a computation that accumulates the total internal conductive energy (U_cond), the total internal mechanical energy (U_mech), the -total internal energy (U) and the {harmonic} average of the internal +total chemical energy (U_chem) and the {harmonic} average of the internal temperature (dpdTheta) for the entire system of particles. See the "compute dpd/atom"_compute_dpd_atom.html command if you want per-particle internal energies and internal temperatures. @@ -40,7 +40,7 @@ where N is the number of particles in the system [Output info:] This compute calculates a global vector of length 5 (U_cond, U_mech, -U, dpdTheta, N_particles), which can be accessed by indices 1-5. See +U_chem, dpdTheta, N_particles), which can be accessed by indices 1-5. See "this section"_Section_howto.html#howto_15 for an overview of LAMMPS output options. diff --git a/doc/src/compute_dpd_atom.txt b/doc/src/compute_dpd_atom.txt index c4be61b45f..7be083dca4 100644 --- a/doc/src/compute_dpd_atom.txt +++ b/doc/src/compute_dpd_atom.txt @@ -22,23 +22,25 @@ compute 1 all dpd/atom [Description:] Define a computation that accesses the per-particle internal -conductive energy (u_cond), internal mechanical energy (u_mech) and +conductive energy (u_cond), internal mechanical energy (u_mech), +internal chemical energy (u_chem) and internal temperatures (dpdTheta) for each particle in a group. See the "compute dpd"_compute_dpd.html command if you want the total -internal conductive energy, the total internal mechanical energy, and +internal conductive energy, the total internal mechanical energy, the +total chemical energy and average internal temperature of the entire system or group of dpd particles. [Output info:] -This compute calculates a per-particle array with 3 columns (u_cond, -u_mech, dpdTheta), which can be accessed by indices 1-3 by any command +This compute calculates a per-particle array with 4 columns (u_cond, +u_mech, u_chem, dpdTheta), which can be accessed by indices 1-4 by any command that uses per-particle values from a compute as input. See "Section_howto15"_Section_howto.html#howto_15 for an overview of LAMMPS output options. -The per-particle array values will be in energy (u_cond, u_mech) and -temperature (dpdTheta) "units"_units.html. +The per-particle array values will be in energy (u_cond, u_mech, u_chem) +and temperature (dpdTheta) "units"_units.html. [Restrictions:] diff --git a/doc/src/fix_eos_table_rx.txt b/doc/src/fix_eos_table_rx.txt new file mode 100644 index 0000000000..b2a0051889 --- /dev/null +++ b/doc/src/fix_eos_table_rx.txt @@ -0,0 +1,138 @@ +"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c + +:link(lws,http://lammps.sandia.gov) +:link(ld,Manual.html) +:link(lc,Section_commands.html#comm) + +:line + +fix eos/table/rx command :h3 + +[Syntax:] + +fix ID group-ID eos/table/rx style file1 N keyword file2 :pre + +ID, group-ID are documented in "fix"_fix.html command +eos/table/rx = style name of this fix command +style = {linear} = method of interpolation +file1 = filename containing the tabulated equation of state +N = use N values in {linear} tables +keyword = name of table keyword correponding to table file +file2 = filename containing the heats of formation of each species :ul + +[Examples:] + +fix 1 all eos/table/rx linear eos.table 10000 KEYWORD thermo.table :pre + +[Description:] + +Fix {eos/table/rx} applies a tabulated mesoparticle equation +of state to relate the concentration-dependent particle internal +energy (u_i) to the particle internal temperature (dpdTheta_i). + +The concentration-dependent particle internal energy (u_i) is +computed according to the following relation: + +:c,image(Eqs/fix_eos_table_rx.jpg) + +where {m} is the number of species, {c_i,j} is the concentration of +species {j} in particle {i}, {u_j} is the internal energy of species j, +{DeltaH_f,j} is the heat of formation of species {j}, N is the number of +molecules represented by the coarse-grained particle, kb is the +Boltzmann constant, and T is the temperature of the system. + +Fix {eos/table/rx} creates interpolation tables of length {N} from {m} +internal energy values of each species {u_j} listed in a file as a +function of internal temperature. During a simulation, these tables +are used to interpolate internal energy or temperature values as needed. +The interpolation is done with the {linear} style. For the {linear} style, +the internal temperature is used to find 2 surrounding table values from +which an internal energy is computed by linear interpolation. A secant +solver is used to determine the internal temperature from the internal energy. + +The first filename specifies a file containing tabulated internal +temperature and {m} internal energy values for each species {u_j}. +The keyword specifies a section of the file. The format of this +file is described below. + +The second filename specifies a file containing heat of formation +{DeltaH_f,j} for each species. + +:line + +The format of a tabulated file is as follows (without the +parenthesized comments): + +# EOS TABLE (one or more comment or blank lines) :pre + +KEYWORD (keyword is first text on line) +N 500 h2 no2 n2 ... no (N parameter species1 species2 ... speciesN) + (blank) +1 1.00 0.000 ... 0.0000 (index, internal temperature, internal energy of species 1, ..., internal energy of species m) +2 1.02 0.001 ... 0.0002 +... +500 10.0 0.500 ... 1.0000 :pre + +A section begins with a non-blank line whose 1st character is not a +"#"; blank lines or lines starting with "#" can be used as comments +between sections. The first line begins with a keyword which +identifies the section. The line can contain additional text, but the +initial text must match the argument specified in the fix command. + +The next line lists the number of table entries and the species names +that correspond with all the species listed in the reaction equations +through the {fix rx} command. +The parameter "N" is required and its value is the number of table +entries that follow. Let Nfile = "N" in the tabulated file. +What LAMMPS does is a preliminary interpolation by creating splines +using the Nfile tabulated values as nodal points. + +Following a blank line, the next N lines list the tabulated values. +On each line, the 1st value is the index from 1 to N, the 2nd value is +the internal temperature (in temperature units), the 3rd value until +the {m+3} value are the internal energies of the m species (in energy units). + +Note that all internal temperature and internal energy values must +increase from one line to the next. + +Note that one file can contain many sections, each with a tabulated +potential. LAMMPS reads the file section by section until it finds +one that matches the specified keyword. + +:line + +The format of a heat of formation file is as follows (without the +parenthesized comments): + +# HEAT OF FORMATION TABLE (one or more comment or blank lines) :pre + (blank) +h2 0.00 (species name, heat of formation) +no2 0.34 +n2 0.00 +... +no 0.93 :pre + +Note that the species can be listed in any order. The tag that is +used as the species name must correspond with the tags used to define +the reactions with the "fix rx"_fix_rx.html command. + +:line + +[Restrictions:] + +The fix {eos/table/rx} is only available if LAMMPS is built with the +USER-DPD package. + +The equation of state must be a monotonically increasing function. + +An exit error will occur if the internal temperature or internal +energies are not within the table cutoffs. + +[Related commands:] + +"fix rx"_fix_rx.html, +"pair dpd/fdt"_dpd_fdt.html + +[Default:] none + +:line diff --git a/doc/src/fix_rx.txt b/doc/src/fix_rx.txt new file mode 100644 index 0000000000..a32290d366 --- /dev/null +++ b/doc/src/fix_rx.txt @@ -0,0 +1,143 @@ +"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c + +:link(lws,http://lammps.sandia.gov) +:link(ld,Manual.html) +:link(lc,Section_commands.html#comm) + +:line + +fix rx command :h3 + +[Syntax:] + +fix ID group-ID rx file localTemp solver ... :pre + +ID, group-ID are documented in "fix"_fix.html command +rx = style name of this fix command +file = filename containing the reaction kinetic equations and Arrhenius parameters +localTemp = {none,lucy} = no local temperature averaging or local temperature defined through Lucy weighting function +solver = {lammps_rk4} = Explicit 4th order Runge-Kutta method +minSteps = # of steps for rk4 solver :ul + +[Examples:] + +fix 1 all rx kinetics.rx none lammps_rk4 +fix 1 all rx kinetics.rx none lammps_rk4 1 +fix 1 all rx kinetics.rx lucy lammps_rk4 10 :pre + +[Description:] + +Fix {rx} solves the reaction kinetic ODEs for a given reaction set that is +defined within the file associated with this command. + +For a general reaction such that + +:c,image(Eqs/fix_rx_reaction.jpg) + +the reaction rate equation is defined to be of the form + +:c,image(Eqs/fix_rx_reactionRate.jpg) + +In the current implementation, the exponents are defined to be equal to the +stoichiometric coefficients. A given reaction set consisting of {n} reaction +equations will contain a total of {m} species. A set of {m} ordinary +differential equations (ODEs) that describe the change in concentration of a +given species as a function of time are then constructed based on the {n} +reaction rate equations. + +The ODE systems are solved over the full DPD timestep {dt} using a 4th order +Runge-Kutta {rk4} method with a fixed step-size {h}, specified by the +{lammps_rk4} keyword. The number of ODE steps per DPD timestep for the rk4 method +is optionally specified immediately after the rk4 keyword. The ODE step-size is set as +{dt/num_steps}. Smaller step-sizes tend to yield more accurate results but there +is not control on the error. + +:line + +The filename specifies a file that contains the entire set of reaction +kinetic equations and corresponding Arrhenius parameters. The format of +this file is described below. + +There is no restriction on the total number or reaction equations that are +specified. The species names are arbitrary string names that are associated +with the species concentrations. +Each species in a given reaction must be preceded by it's stoichiometric +coefficient. The only delimiters that are recognized between the species are +either a {+} or {=} character. The {=} character corresponds to an +irreversible reaction. After specifying the reaction, the reaction rate +constant is determined through the temperature dependent Arrhenius equation: + +:c,image(Eqs/fix_rx.jpg) + +where {A} is the Arrhenius factor in time units or concentration/time units, +{n} is the unitless exponent of the temperature dependence, and {E_a} is the +activation energy in energy units. The temperature dependence can be removed +by specifying the exponent as zero. + +The internal temperature of the coarse-grained particles can be used in constructing the +reaction rate constants at every DPD timestep by specifying the keyword {none}. +Alternatively, the keyword {lucy} can be specified to compute a local-average particle +internal temperature for use in the reaction rate constant expressions. +The local-average particle internal temperature is defined as: + +:c,image(Eqs/fix_rx_localTemp.jpg) + +where the Lucy function is expressed as: + +:c,image(Eqs/fix_rx_localTemp2.jpg) + +The self-particle interaction is included in the above equation. + +:line + +The format of a tabulated file is as follows (without the parenthesized comments): + +# Rxn equations and parameters (one or more comment or blank lines) :pre +1.0 hcn + 1.0 no2 = 1.0 no + 0.5 n2 + 0.5 h2 + 1.0 co 2.49E+01 0.0 1.34 (rxn equation, A, n, Ea) +1.0 hcn + 1.0 no = 1.0 co + 1.0 n2 + 0.5 h2 2.16E+00 0.0 1.52 +... +1.0 no + 1.0 co = 0.5 n2 + 1.0 co2 1.66E+06 0.0 0.69 :pre + +A section begins with a non-blank line whose 1st character is not a +"#"; blank lines or lines starting with "#" can be used as comments +between sections. + +Following a blank line, the next N lines list the N reaction equations. +Each species within the reaction equation is specified through its +stoichiometric coefficient and a species tag. Reactant species are specified +on the left-hand side of the equation and product species are specified on the +right-hand side of the equation. After specifying the reactant and product +species, the final three arguments of each line represent the Arrhenius +parameter {A}, the temperature exponent {n}, and the activation energy {Ea}. + +Note that the species tags that are defined in the reaction equations are +used by the "fix eos/table/rx"_fix_eos_table_rx.html command to define the +thermodynamic properties of each species. Furthermore, the number of species +molecules (i.e., concentration) can be specified either with the "set"_set.html +command using the "d_" prefix or by reading directly the concentrations from a +data file. For the latter case, the "read_data"_read_data.html command with the +fix keyword should be specified, where the fix-ID will be the "fix rx" ID with a +"_SPECIES" suffix, e.g. + +fix foo all rx reaction.file ... +read_data data.dpd fix foo_SPECIES NULL Species + +:line + +[Restrictions:] + +The fix {rx} is only available if LAMMPS is built with the USER-DPD package. + +The fix {rx} must be used with the "atom_style dpd"_atom_style.html command. + +The fix {rx} can only be used with a constant energy or constant enthalpy DPD simulation. + +[Related commands:] + +"fix eos/table/rx"_fix_eos_table_rx.html, +"fix shardlow"_fix_shardlow.html, +"pair dpd/fdt/energy"_dpd_fdt_energy.html + +[Default:] none + +:line diff --git a/doc/src/pair_exp6_rx.txt b/doc/src/pair_exp6_rx.txt new file mode 100644 index 0000000000..5e65fee84c --- /dev/null +++ b/doc/src/pair_exp6_rx.txt @@ -0,0 +1,114 @@ +"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c + +:link(lws,http://lammps.sandia.gov) +:link(ld,Manual.html) +:link(lc,Section_commands.html#comm) + +:line + +pair_style exp6/rx command :h3 + +[Syntax:] + +pair_style exp6/rx cutoff :pre + +cutoff = global cutoff for DPD interactions (distance units) :ul + +[Examples:] + +pair_style exp6/rx 10.0 +pair_coeff * * exp6.params h2o h2o 1.0 1.0 10.0 +pair_coeff * * exp6.params h2o 1fluid 1.0 1.0 10.0 +pair_coeff * * exp6.params 1fluid 1fluid 1.0 1.0 10.0 :pre + +[Description:] + +Style {exp6/rx} is used in reaction DPD simulations, where the coarse-grained (CG) +particles are composed of {m} species whose reaction rate kinetics are determined +from a set of {n} reaction rate equations through the "fix rx"_fix_rx.html command. +The species of one CG particle can interact with a species in a neighboring CG +particle through a site-site interaction potential model. The {exp6/rx} style +computes an exponential-6 potential given by + +:c,image(Eqs/pair_exp6_rx.jpg) + +where the {epsilon} parameter determines the depth of the potential +minimum located at {Rm}, and {alpha} determines the softness of the repulsion. + +The coefficients must be defined for each species in a given particle type +via the "pair_coeff"_pair_coeff.html command as in the examples above, where +the first argument is the filename that includes the exponential-6 parameters +for each species. The file includes the species tag followed by the {alpha}, +{epsilon} and {Rm} parameters. The format of the file is described below. + +The second and third arguments specify the site-site interaction +potential between two species contained within two different particles. +The species tags must either correspond to the species defined in the reaction +kinetics files specified with the "fix rx"_fix_rx.html command +or they must correspond to the tag "1fluid", signifying interaction +with a product species mixture determined through a one-fluid approximation. +The interaction potential is weighted by the geometric average of the +concentrations of the two species. The coarse-grained potential is +stored before and after the reaction kinetics solver is applied, where the +difference is defined to be the internal chemical energy (uChem). + +The fourth and fifth arguments specify the {Rm} and {epsilon} scaling exponents. + +The final argument specifies the interaction cutoff. + +:line + +The format of a tabulated file is as follows (without the parenthesized comments): + +# exponential-6 parameters for various species (one or more comment or blank lines) :pre +h2o exp6 11.00 0.02 3.50 (species, exp6, alpha, Rm, epsilon) +no2 exp6 13.60 0.01 3.70 +... +co2 exp6 13.00 0.03 3.20 :pre + +A section begins with a non-blank line whose 1st character is not a +"#"; blank lines or lines starting with "#" can be used as comments +between sections. + +Following a blank line, the next N lines list the species and their +corresponding parameters. The first argument is the species tag, +the second argument is the exp6 tag, the 3rd argument is the {alpha} +parameter (energy units), the 4th argument is the {epsilon} parameter +(energy-distance^6 units), and the 5th argument is the {Rm} +parameter (distance units). If a species tag of "1fluid" is listed as a +pair coefficient, a one-fluid approximation is specified where a +concentration-dependent combination of the parameters is computed +through the following equations: + +:c,image(Eqs/pair_exp6_rx_oneFluid.jpg) + +where + +:c,image(Eqs/pair_exp6_rx_oneFluid2.jpg) + +and xa and xb are the mole fractions of a and b, respectively, which +comprise the gas mixture. + +:line + +[Mixing, shift, table, tail correction, restart, rRESPA info]: + +This pair style does not support mixing. Thus, coefficients for all +I,J pairs must be specified explicitly. + +This style does not support the "pair_modify"_pair_modify.html shift option +for the energy of the exp() and 1/r^6 portion of the pair interaction. + +This style does not support the pair_modify tail option for adding long-range +tail corrections to energy and pressure for the A,C terms in the +pair interaction. + +[Restrictions:] + +None + +[Related commands:] + +"pair_coeff"_pair_coeff.html + +[Default:] none diff --git a/doc/src/pair_multi_lucy_rx.txt b/doc/src/pair_multi_lucy_rx.txt new file mode 100644 index 0000000000..f1c33e9711 --- /dev/null +++ b/doc/src/pair_multi_lucy_rx.txt @@ -0,0 +1,207 @@ +"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c + +:link(lws,http://lammps.sandia.gov) +:link(ld,Manual.html) +:link(lc,Section_commands.html#comm) + +:line + +pair_style multi/lucy/rx command :h3 + +[Syntax:] + +pair_style multi/lucy/rx style N keyword ... :pre + +style = {lookup} or {linear} = method of interpolation +N = use N values in {lookup}, {linear} tables :ul + +[Examples:] + +pair_style multi/lucy/rx linear 1000 +pair_coeff * * multibody.table ENTRY1 h2o h2o 7.0 +pair_coeff * * multibody.table ENTRY1 h2o 1fluid 7.0 :pre + +[Description:] + +Style {multi/lucy/rx} is used in reaction DPD simulations, where the coarse-grained +(CG) particles are composed of {m} species whose reaction rate kinetics are determined +from a set of {n} reaction rate equations through the "fix rx"_fix_rx.html command. +The species of one CG particle can interact with a species in a neighboring CG particle +through a site-site interaction potential model. Style {multi/lucy/rx} computes the +site-site density-dependent force following from the many-body form described in +"(Moore)"_#Moore and "(Warren)"_#Warren as + +:c,image(Eqs/pair_multi_lucy.jpg) + +which consists of a density-dependent function, A(rho), and a radial-dependent weight +function, omegaDD(rij). The radial-dependent weight function, omegaDD(rij), is taken +as the Lucy function: + +:c,image(Eqs/pair_multi_lucy2.jpg) + +The density-dependent energy for a given particle is given by: + +:c,image(Eqs/pair_multi_lucy_energy.jpg) + +See the supporting information of "(Brennan)"_#Brennan or the publication by "(Moore)"_#Moore +for more details on the functional form. + +An interpolation table is used to evaluate the density-dependent energy (Integral(A(rho)drho) and force (A(rho)). +Note that the pre-factor to the energy is computed after the interpolation, thus the Integral(A(rho)drho will +have units of energy / length^4. + +The interpolation table is created as a pre-computation by fitting cubic splines to +the file values and interpolating the density-dependent energy and force at each of {N} densities. +During a simulation, the tables are used to interpolate the density-dependent energy and force as +needed for each pair of particles separated by a distance {R}. The interpolation is done in +one of 2 styles: {lookup} and {linear}. + +For the {lookup} style, the density is used to find the nearest table entry, which is the +density-dependent energy and force. + +For the {linear} style, the density is used to find the 2 surrounding table values from +which the density-dependent energy and force are computed by linear interpolation. + +The following coefficients must be defined for each pair of atoms +types via the "pair_coeff"_pair_coeff.html command as in the examples +above. + +filename +keyword +species1 +species2 +cutoff (distance units) :ul + +The filename specifies a file containing the tabulated density-dependent +energy and force. The keyword specifies a section of the file. +The cutoff is an optional coefficient. If not specified, the outer cutoff in the +table itself (see below) will be used to build an interpolation table +that extend to the largest tabulated distance. If specified, only +file values up to the cutoff are used to create the interpolation +table. The format of this file is described below. + +The species tags define the site-site interaction potential between two +species contained within two different particles. +The species tags must either correspond to the species defined in the reaction +kinetics files specified with the "fix rx"_fix_rx.html command +or they must correspond to the tag "1fluid", signifying interaction +with a product species mixture determined through a one-fluid approximation. +The interaction potential is weighted by the geometric average of the +concentrations of the two species. The coarse-grained potential +is stored before and after the reaction kinetics solver is applied, where +the difference is defined to be the internal chemical energy (uChem). + +:line + +The format of a tabulated file is a series of one or more sections, +defined as follows (without the parenthesized comments): + +# Density-dependent function (one or more comment or blank lines) :pre + +DD-FUNCTION (keyword is first text on line) +N 500 R 1.0 10.0 (N, R, RSQ parameters) + (blank) +1 1.0 25.5 102.34 (index, density, energy/r^4, force) +2 1.02 23.4 98.5 +... +500 10.0 0.001 0.003 :pre + +A section begins with a non-blank line whose 1st character is not a +"#"; blank lines or lines starting with "#" can be used as comments +between sections. The first line begins with a keyword which +identifies the section. The line can contain additional text, but the +initial text must match the argument specified in the pair_coeff +command. The next line lists (in any order) one or more parameters +for the table. Each parameter is a keyword followed by one or more +numeric values. + +The parameter "N" is required and its value is the number of table +entries that follow. Note that this may be different than the {N} +specified in the "pair_style multi/lucy/rx"_pair_multi_lucy_rx.html command. Let +Ntable = {N} in the pair_style command, and Nfile = "N" in the +tabulated file. What LAMMPS does is a preliminary interpolation by +creating splines using the Nfile tabulated values as nodal points. It +uses these to interpolate the density-dependent energy and force at Ntable different +points. The resulting tables of length Ntable are then used as +described above, when computing the density-dependent energy and force. +This means that if you want the interpolation tables of +length Ntable to match exactly what is in the tabulated file (with +effectively no preliminary interpolation), you should set Ntable = +Nfile, and use the "RSQ" parameter. This is because the +internal table abscissa is always RSQ (separation distance squared), +for efficient lookup. + +All other parameters are optional. If "R" or "RSQ" does +not appear, then the distances in each line of the table are used +as-is to perform spline interpolation. In this case, the table values +can be spaced in {density} uniformly or however you wish to position table +values in regions of large gradients. + +If used, the parameters "R" or "RSQ" are followed by 2 values {rlo} +and {rhi}. If specified, the density associated with each density-dependent +energy and force value is computed from these 2 values (at high accuracy), rather +than using the (low-accuracy) value listed in each line of the table. +The density values in the table file are ignored in this case. +For "R", distances uniformly spaced between {rlo} and {rhi} are +computed; for "RSQ", squared distances uniformly spaced between +{rlo*rlo} and {rhi*rhi} are computed. + +NOTE: If you use "R" or "RSQ", the tabulated distance values in the +file are effectively ignored, and replaced by new values as described +in the previous paragraph. If the density value in the table is not +very close to the new value (i.e. round-off difference), then you will +be assigning density-dependent energy and force values to a different density, +which is probably not what you want. LAMMPS will warn if this is occurring. + +Following a blank line, the next N lines list the tabulated values. +On each line, the 1st value is the index from 1 to N, the 2nd value is +r (in density units), the 3rd value is the density-dependent function value +(in energy units / length^4), and the 4th is the force (in force units). The +density values must increase from one line to the next. + +Note that one file can contain many sections, each with a tabulated +potential. LAMMPS reads the file section by section until it finds +one that matches the specified keyword. + +:line + +[Mixing, shift, table, tail correction, restart, rRESPA info]: + +This pair style does not support mixing. Thus, coefficients for all +I,J pairs must be specified explicitly. + +The "pair_modify"_pair_modify.html shift, table, and tail options are +not relevant for this pair style. + +This pair style writes the settings for the "pair_style multi/lucy/rx" command +to "binary restart files"_restart.html, so a pair_style command does +not need to specified in an input script that reads a restart file. +However, the coefficient information is not stored in the restart +file, since it is tabulated in the potential files. Thus, pair_coeff +commands do need to be specified in the restart input script. + +This pair style can only be used via the {pair} keyword of the +"run_style respa"_run_style.html command. It does not support the +{inner}, {middle}, {outer} keywords. + +:line + +[Restrictions:] none + +[Related commands:] + +"pair_coeff"_pair_coeff.html + +[Default:] none + +:line + +:link(Warren) +[(Warren)] Warren, Phys Rev E, 68, 066702 (2003). + +:link(Brennan) +[(Brennan)] Brennan, J Chem Phys Lett, 5, 2144-2149 (2014). + +:link(Moore) +[(Moore)] Moore, J Chem Phys, 144, 104501 (2016). + diff --git a/doc/src/pair_table_rx.txt b/doc/src/pair_table_rx.txt new file mode 100644 index 0000000000..b33ef1196d --- /dev/null +++ b/doc/src/pair_table_rx.txt @@ -0,0 +1,231 @@ +"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c + +:link(lws,http://lammps.sandia.gov) +:link(ld,Manual.html) +:link(lc,Section_commands.html#comm) + +:line + +pair_style table/rx command :h3 + +[Syntax:] + +pair_style table style N :pre + +style = {lookup} or {linear} or {spline} or {bitmap} = method of interpolation +N = use N values in {lookup}, {linear}, {spline} tables +N = use 2^N values in {bitmap} tables + +[Examples:] + +pair_style table/rx linear 1000 +pair_style table/rx bitmap 12 +pair_coeff * * rxn.table ENTRY1 h2o h2o 10.0 +pair_coeff * * rxn.table ENTRY1 1fluid 1fluid 10.0 +pair_coeff * 3 rxn.table ENTRY1 h2o no2 10.0 :pre + +[Description:] + +Style {table/rx} is used in reaction DPD simulations,where the coarse-grained (CG) +particles are composed of {m} species whose reaction rate kinetics are determined +from a set of {n} reaction rate equations through the "fix rx"_fix_rx.html command. +The species of one CG particle can interact with a species in a neighboring CG +particle through a site-site interaction potential model. Style {table/rx} creates +interpolation tables of length {N} from pair potential and force values listed in a +file(s) as a function of distance. The files are read by the +"pair_coeff"_pair_coeff.html command. + +The interpolation tables are created by fitting cubic splines to the +file values and interpolating energy and force values at each of {N} +distances. During a simulation, these tables are used to interpolate +energy and force values as needed. The interpolation is done in one +of 4 styles: {lookup}, {linear}, {spline}, or {bitmap}. + +For the {lookup} style, the distance between 2 atoms is used to find +the nearest table entry, which is the energy or force. + +For the {linear} style, the pair distance is used to find 2 +surrounding table values from which an energy or force is computed by +linear interpolation. + +For the {spline} style, a cubic spline coefficients are computed and +stored at each of the {N} values in the table. The pair distance is +used to find the appropriate set of coefficients which are used to +evaluate a cubic polynomial which computes the energy or force. + +For the {bitmap} style, the N means to create interpolation tables +that are 2^N in length.