Action: DUMPDERIVATIVES
| Module | generic |
|---|---|
| Description | Usage |
| Dump the derivatives with respect to the input parameters for scalar values (generally CVs, functions or biases). | |
| This action outputs data to a file. You can read more about how PLUMED manages output files here |
Details and examples
Dump the derivatives with respect to the input parameters for scalar values (generally CVs, functions or biases).
You can use this command to output the derivatives of a scalar with respect to whatever input parameters are used to calculate that scalar. For example, the following input instructs plumed to write a file called deriv that contains both the analytical and numerical derivatives of the distance between atoms 1 and 2.
distance: DISTANCECalculate the distance/s between pairs of atoms. More details ATOMSthe pair of atom that we are calculating the distance between=1,2 distanceN: DISTANCECalculate the distance/s between pairs of atoms. More details ATOMSthe pair of atom that we are calculating the distance between=1,2 NUMERICAL_DERIVATIVES calculate the derivatives for these quantities numerically DUMPDERIVATIVESDump the derivatives with respect to the input parameters for scalar values (generally CVs, functions or biases). More details ARGthe labels of the values whose derivatives should be output=distance,distanceN STRIDE the frequency with which the derivatives should be output=1 FILEthe name of the file on which to output the derivatives=deriv
This input outputs the derivative of the distance with respect to the atom positions and the cell vectors (virial-like form). It will thus output 15 deriatives for the two quantities output - the derivatives with respect to the x,y and z components of the input atoms and the 9 components of the virial.
By contast the following input will only output 1 derivative; namely, the derivative of the switching function, f, with respect to the input distance, d.
d: DISTANCECalculate the distance/s between pairs of atoms. More details ATOMSthe pair of atom that we are calculating the distance between=1,2 f: LESS_THANUse a switching function to determine how many of the input variables are less than a certain cutoff. More details ARGthe values input to this function=d SWITCHThis keyword is used if you want to employ an alternative to the continuous swiching function defined above={RATIONAL R_0=0.2} DUMPDERIVATIVESDump the derivatives with respect to the input parameters for scalar values (generally CVs, functions or biases). More details ARGthe labels of the values whose derivatives should be output=f STRIDE the frequency with which the derivatives should be output=1 FMT the format with which the derivatives should be output=%8.4f FILEthe name of the file on which to output the derivatives=deriv
You can only use this command to output the derivatives of rank 0 (scalar) values. You cannot use it to output derivatives of vector, matrix of function values.
RESTART, UPDATE_FROM and UPDATE_UNTIL
Notice that the RESTART, UPDATE_FROM and UPDATE_UNTIL keywords keywords
can be used in this action in the same way as they are used for PRINT.
Consequently, if you would like to append derivatives to an existing file called deriv instead of backing that
file up at the start of the calculation and outputting the data from the calculation on a new file called deriv
you would use an input like the one shown below:
distance: DISTANCECalculate the distance/s between pairs of atoms. More details ATOMSthe pair of atom that we are calculating the distance between=1,2 DUMPDERIVATIVESDump the derivatives with respect to the input parameters for scalar values (generally CVs, functions or biases). More details ARGthe labels of the values whose derivatives should be output=distance STRIDE the frequency with which the derivatives should be output=1 FILEthe name of the file on which to output the derivatives=deriv RESTARTallows per-action setting of restart (YES/NO/AUTO)=YES
Similarly, if you want to only output the derivatives during the 400 ps time interval after the first 100 ps of the simulation you would use an input like the one shown below:
distance: DISTANCECalculate the distance/s between pairs of atoms. More details ATOMSthe pair of atom that we are calculating the distance between=1,2 DUMPDERIVATIVESDump the derivatives with respect to the input parameters for scalar values (generally CVs, functions or biases). More details ARGthe labels of the values whose derivatives should be output=distance STRIDE the frequency with which the derivatives should be output=1 FILEthe name of the file on which to output the derivatives=deriv UPDATE_FROMOnly update this action from this time=100 UPDATE_UNTILOnly update this action until this time=500
Input
The arguments that serve as the input for this action are specified using one or more of the keywords in the following table.
| Keyword | Type | Description |
|---|---|---|
| ARG | scalar | the labels of the values whose derivatives should be output |
Full list of keywords
The following table describes the keywords and options that can be used with this action
| Keyword | Type | Default | Description |
|---|---|---|---|
| ARG | input | none | the labels of the values whose derivatives should be output |
| STRIDE | compulsory | 1 | the frequency with which the derivatives should be output |
| FILE | compulsory | none | the name of the file on which to output the derivatives |
| FMT | compulsory | %15.10f | the format with which the derivatives should be output |
| RESTART | optional | not used | allows per-action setting of restart (YES/NO/AUTO) |
| UPDATE_FROM | optional | not used | Only update this action from this time |
| UPDATE_UNTIL | optional | not used | Only update this action until this time |