User Tools

Site Tools


howto:cdft

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
howto:cdft [2018/11/02 12:51]
nholmber [Example: Configuration interaction calculations with CDFT (CDFT-CI): The case of $\mathrm{H}_2^+$]
howto:cdft [2018/11/02 13:11] (current)
nholmber [Structure of input file]
Line 434: Line 434:
 In the above example input file, a common file ''​${DFT_FILE}}''​ is used as a template for the [[inp>​FORCE_EVAL/​DFT|DFT]] subsection. The CDFT state specific constraint settings and the wavefunction filename are passed through variables. The electronic coupling is calculated using the default weight function matrix and Löwdin orthogonalization methods. If molecular dynamics were performed with the above input file, the forces would be mixed according to linear mixing scheme $F = \lambda F_1 + (1-\lambda) F_2$, where the states $F_i$ are selected with the keyword [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​FORCE_STATES|FORCE_STATES]] and the mixing parameter $\lambda$ with [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​LAMBDA|LAMBDA]]. No configuration interaction calculation is performed. The [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT|MIXED_CDFT]] section accepts some additional keywords, which have been described in the manual. ​ In the above example input file, a common file ''​${DFT_FILE}}''​ is used as a template for the [[inp>​FORCE_EVAL/​DFT|DFT]] subsection. The CDFT state specific constraint settings and the wavefunction filename are passed through variables. The electronic coupling is calculated using the default weight function matrix and Löwdin orthogonalization methods. If molecular dynamics were performed with the above input file, the forces would be mixed according to linear mixing scheme $F = \lambda F_1 + (1-\lambda) F_2$, where the states $F_i$ are selected with the keyword [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​FORCE_STATES|FORCE_STATES]] and the mixing parameter $\lambda$ with [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​LAMBDA|LAMBDA]]. No configuration interaction calculation is performed. The [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT|MIXED_CDFT]] section accepts some additional keywords, which have been described in the manual. ​
  
-The keyword [[inp>​FORCE_EVAL/​MIXED#​NGROUPS|NGROUPS]] is set to 1, which implies that the two CDFT states are treated sequentially utilizing the full set of $N$ MPI processes for the simulation. The CDFT weight function and its gradients are copied from state to state if the constraints definitions are identical in each CDFT state, because construction of these terms might be expensive in large systems. The keyword [[inp>​FORCE_EVAL/​MIXED#​NGROUPS|NGROUPS]] could also be set to 2 in which case the CDFT weight function and gradients ​would first be built in parallel on $N$ MPI processes, ​and the two CDFT states would then calculated in parallel with $N/2$ MPI processes. This operating mode is limited to two CDFT states with one identically defined total charge density constraint. This operating mode is an advanced feature which might be useful for large scale MD simulations to save computational wallclock time at the expense of higher CPU core usage. The operating mode should only be used in conjuction with [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​DLB|dynamic load balancing]] if possible, and will likely require tweaking the load balancing parameters.+The keyword [[inp>​FORCE_EVAL/​MIXED#​NGROUPS|NGROUPS]] is set to 1, which implies that the two CDFT states are treated sequentially utilizing the full set of $N$ MPI processes for the simulation. The CDFT weight function and its gradients are copied from state to state if the constraints definitions are identical in each CDFT state, because construction of these terms might be expensive in large systems. ​ 
 + 
 +The keyword [[inp>​FORCE_EVAL/​MIXED#​NGROUPS|NGROUPS]] could also be set to 2 or a larger value if using more than 2 CDFT states. In this case, each CDFT state is solved ​in parallel using $N/​N_\mathrm{groups}$ processors. This will likely reduce the wall clock time of your simulation at the expense of more computing resources. However, you should note that the weight function and its gradients are computed separately for each state instead of copied from state to state (if possible). This can be costly for large solvated systems. 
 + 
 +A special run type is available for ''​NGROUPS 2''​ if the keyword [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​PARALLEL_BUILD|PARALLEL_BUILD]] is activated. In this casethe CDFT weight function and gradients ​are first built in parallel on $N$ MPI processes, ​which are subsequently copied onto the two MPI processor groups of size $N/2$ which solve the CDFT states in parallel. This operating mode is limited to two CDFT states with one identically defined total charge density constraint. This operating mode is an advanced feature which might be useful for large scale MD simulations to save computational wallclock time at the expense of higher CPU core usage. The operating mode should only be used in conjuction with [[inp>​FORCE_EVAL/​MIXED/​MIXED_CDFT#​DLB|dynamic load balancing]] if possible, and will likely require tweaking the load balancing parameters.
    
 ==== Example: Electronic coupling of Zn cation dimer ====  ==== Example: Electronic coupling of Zn cation dimer ==== 
howto/cdft.txt · Last modified: 2018/11/02 13:11 by nholmber