<div dir="ltr"><code>Dear CP2K developers,<br><br>I am sorry to disturb you. I have some questions.<br>Recently I want to analyze whether the total energy is converged with core-shell model in NVE ensemble. I didn't use </code><code><code>extra thermostat for shell.<br>I don't know why the Cons Qty energy = </code></code><code><code><code>md_ener%ekin+md_ener%epot+md_ener%ekin_shell</code> but not including the potential of shell? Is the Cons Qty the total energy? In NVE ensemble, which energy should be constant? </code></code><code><code><code><code><code>ekin+epot+ekin_shell</code></code></code></code>+epot_shell or </code><code><code><code><code><code><code>ekin+epot+ekin_shell?<br><br>Thank you very much~<br><br>Best wishes,<br>Zuoheng<br><br>PS:The whole code of </code></code></code></code></code></code><code><code><code><code><code><code><code>get_econs_nve function is following:<br><br></code></code></code></code></code></code><div style="background-color: rgb(250, 250, 250); border-color: rgb(187, 187, 187); border-style: solid; border-width: 1px; overflow-wrap: break-word;" class="prettyprint"><code class="prettyprint"><div class="subprettyprint"><code><span style="color: #000;" class="styled-by-prettify">SUBROUTINE get_econs_nve</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">md_env</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> md_ener</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> para_env</span><span style="color: #660;" class="styled-by-prettify">)</span><span style="color: #000;" class="styled-by-prettify"><br>      TYPE</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">md_environment_type</span><span style="color: #660;" class="styled-by-prettify">),</span><span style="color: #000;" class="styled-by-prettify"> POINTER                 </span><span style="color: #660;" class="styled-by-prettify">::</span><span style="color: #000;" class="styled-by-prettify"> md_env<br>      TYPE</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">md_ener_type</span><span style="color: #660;" class="styled-by-prettify">),</span><span style="color: #000;" class="styled-by-prettify"> INTENT</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">inout</span><span style="color: #660;" class="styled-by-prettify">)</span><span style="color: #000;" class="styled-by-prettify">                  </span><span style="color: #660;" class="styled-by-prettify">::</span><span style="color: #000;" class="styled-by-prettify"> md_ener<br>      TYPE</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">cp_para_env_type</span><span style="color: #660;" class="styled-by-prettify">),</span><span style="color: #000;" class="styled-by-prettify"> POINTER                    </span><span style="color: #660;" class="styled-by-prettify">::</span><span style="color: #000;" class="styled-by-prettify"> para_env<br><br>      CHARACTER</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">LEN</span><span style="color: #660;" class="styled-by-prettify">=*),</span><span style="color: #000;" class="styled-by-prettify"> PARAMETER </span><span style="color: #660;" class="styled-by-prettify">::</span><span style="color: #000;" class="styled-by-prettify"> routineN </span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify"> </span><span style="color: #080;" class="styled-by-prettify">'get_econs_nve'</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> routineP </span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify"> moduleN</span><span style="color: #800;" class="styled-by-prettify">//':'//routineN</span><span style="color: #000;" class="styled-by-prettify"><br><br>      TYPE</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">force_env_type</span><span style="color: #660;" class="styled-by-prettify">),</span><span style="color: #000;" class="styled-by-prettify"> POINTER                      </span><span style="color: #660;" class="styled-by-prettify">::</span><span style="color: #000;" class="styled-by-prettify"> force_env<br>      TYPE</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">thermostat_type</span><span style="color: #660;" class="styled-by-prettify">),</span><span style="color: #000;" class="styled-by-prettify"> POINTER                     </span><span style="color: #660;" class="styled-by-prettify">::</span><span style="color: #000;" class="styled-by-prettify"> thermostat_coeff</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> thermostat_shell<br><br>      NULLIFY </span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">force_env</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> thermostat_coeff</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> thermostat_shell</span><span style="color: #660;" class="styled-by-prettify">)</span><span style="color: #000;" class="styled-by-prettify"><br><br>      CALL get_md_env</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">md_env</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> force_env</span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify">force_env</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> thermostat_coeff</span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify">thermostat_coeff</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> </span><span style="color: #660;" class="styled-by-prettify">&</span><span style="color: #000;" class="styled-by-prettify"><br>                      thermostat_shell</span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify">thermostat_shell</span><span style="color: #660;" class="styled-by-prettify">)</span><span style="color: #000;" class="styled-by-prettify"><br>      md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">constant </span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify"> md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">ekin</span><span style="color: #660;" class="styled-by-prettify">+</span><span style="color: #000;" class="styled-by-prettify">md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">epot</span><span style="color: #660;" class="styled-by-prettify">+</span><span style="color: #000;" class="styled-by-prettify">md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">ekin_shell<br><br>      CALL get_thermostat_energies</span><span style="color: #660;" class="styled-by-prettify">(</span><span style="color: #000;" class="styled-by-prettify">thermostat_shell</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">thermostat_shell_pot</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> </span><span style="color: #660;" class="styled-by-prettify">&</span><span style="color: #000;" class="styled-by-prettify"><br>                                   md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">thermostat_shell_kin</span><span style="color: #660;" class="styled-by-prettify">,</span><span style="color: #000;" class="styled-by-prettify"> para_env</span><span style="color: #660;" class="styled-by-prettify">)</span><span style="color: #000;" class="styled-by-prettify"><br>      md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">constant </span><span style="color: #660;" class="styled-by-prettify">=</span><span style="color: #000;" class="styled-by-prettify"> md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">constant</span><span style="color: #660;" class="styled-by-prettify">+</span><span style="color: #000;" class="styled-by-prettify">md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">thermostat_shell_kin</span><span style="color: #660;" class="styled-by-prettify">+</span><span style="color: #000;" class="styled-by-prettify">md_ener</span><span style="color: #660;" class="styled-by-prettify">%</span><span style="color: #000;" class="styled-by-prettify">thermostat_shell_pot<br><br>   </span><span style="color: #008;" class="styled-by-prettify">END</span><span style="color: #000;" class="styled-by-prettify"> SUBROUTINE get_econs_nve<br></span></code></div></code></div><br></code><br></div>