sharc-md / sharc

The SHARC molecular dynamics (MD) program suite is an ab initio MD software package developed to study the excited-state dynamics of molecules.
https://www.sharc-md.org
GNU General Public License v3.0
59 stars 31 forks source link

Clarification on SHARC-LVC Dynamics Preparation and gradcorrect #127

Closed lukhman9020 closed 14 hours ago

lukhman9020 commented 2 days ago

Dear Sir,

I am currently working with SHARC 3.0 and have encountered a couple of issues regarding the preparation of input files and setting up dynamics simulations. Firstly, when preparing the initconds.excited file using the $SHARC/excite.py script, I followed the tutorial and provided the MCH representation.

image

However, when setting up dynamics simulations using the $SHARC/setup_traj.py script, the dynamics settings are represented as diagonal representation.

image

I am confused about the reason for this discrepancy between the MCH representation and the diagonal representation in the dynamics setup. In your paper titled "Highly efficient surface hopping dynamics using a linear vibronic coupling model," it is mentioned that SHARC dynamics are usually represented in a diagonal representation. Could you please explain why we provide the MCH representation while preparing the initconds.excited file?

Secondly, during the setup of trajectories for simulation using the $SHARC/setup_traj.py script, there is an option to choose GradCorrect as follows: " For SHARC dynamics, the evaluation of the mixed gradients necessitates to be corrected from MCH gradients

Please choose the gradient correction scheme you want to use 1 mixed gradients are calculated as linear combination of MCH gradients only 2 mixed gradients are calculated by correction of MCH gradients with non-adiabatic coupling vector 3 mixed gradients are calculated by rescaling of the MCH gradients according to time derivatives in diagonal and MCH representations GradCorrect: [1] " When I choose option 1, my calculation runs properly. However, when I choose option 2, my calculation stops with the following error: "STOP 1 Unknown keyword ngh to 'gradcorrect'!" Could you please help me resolve this issue?

Looking forward to your guidance.

Best regards, LUKHMANUL HAKEEM K.

maisebastian commented 2 days ago

Dear lukhman9020, regarding your first question: the issue of chosing the initial state is most detailedly discussed in https://dx.doi.org/10.1039/C9SC03671G. There, we show that, the shorter an excitation laser pulse is, the less can the electron spin change over the duration of the excitation pulse. In excite.py's procedure, we assume an implicit delta pulse (infinitely short). Hence, the initial electronic wave function of the SHARC trajectories should have the same spin multiplicity as the state from which you have excited. Given that the ground state is a pure multiplicity (which is usually the case), one can obtain this by choosing the MCH representation for the excitation process. Once you start the trajectory, the chosen initial MCH state is then translated to the most closely matching diagonal state, and the initial coefficients are transformed into the diagonal basis.

For your second issue, that was a bug in setup_traj.py, which writes gradcorrect ngh to the input files, even though the option should be gradcorrect ngt. This bug was already fixed in the sharc3preview branch (https://github.com/sharc-md/sharc/commit/a86a95c35cbfef413d495836b867f8aa6ee5b995). Now I have pulled it into the main branch. I suggest that you download setup_traj.py from this branch and replace your previous file.

Best, Sebastian

lukhman9020 commented 2 days ago

Dear lukhman9020, regarding your first question: the issue of chosing the initial state is most detailedly discussed in https://dx.doi.org/10.1039/C9SC03671G. There, we show that, the shorter an excitation laser pulse is, the less can the electron spin change over the duration of the excitation pulse. In excite.py's procedure, we assume an implicit delta pulse (infinitely short). Hence, the initial electronic wave function of the SHARC trajectories should have the same spin multiplicity as the state from which you have excited. Given that the ground state is a pure multiplicity (which is usually the case), one can obtain this by choosing the MCH representation for the excitation process. Once you start the trajectory, the chosen initial MCH state is then translated to the most closely matching diagonal state, and the initial coefficients are transformed into the diagonal basis.

For your second issue, that was a bug in setup_traj.py, which writes gradcorrect ngh to the input files, even though the option should be gradcorrect ngt. This bug was already fixed in the sharc3preview branch (a86a95c). Now I have pulled it into the main branch. I suggest that you download setup_traj.py from this branch and replace your previous file.

Best, Sebastian

Dear Sir, OK, Thank you for your reply.

Best regards, LUKHMANUL HAKEEM K.