Beispiel #1
0
# last step of the dynamic
    my.nose_hoover_2(symb, dt, thermo, T, numat)

    ndym += 1

    # COMPUTING THE ENERGY AND THE GAP BETWEEN S0 AND DIFFERENT ENERGETIC LEVELS
    Ek = sum(symb[i].cinetica() for i in range(numat))
    Ep = mol.E_potencial(pot)
    Etot = Ek + Ep
    prom_T = 2.0 * Ek / (3 * numat * my.kb)
    average_T.append(prom_T)
    temperature.write(' %g \n' % prom_T)

    ####Maxwell-Boltzmann distribution
    prob_maxwell = my.maxwell_vel(symb[6], T)
    vel_prom.append(symb[6].vel.x)
    probability.write('%g %g \n' % (prob_maxwell[1], prob_maxwell[0]))

    #Output
    total_energy.write('%g \n' % Etot)
    kinetic.write('%g \n' % Ek)

    vertical1 = st2_energy - st1_energy
    vertical2 = (st3_energy - st1_energy)
    second_Epot = mol.second_state_pot(Grad_st2, Hess_st2, vertical1)
    third_Epot = mol.second_state_pot(Grad_st3, Hess_st3, vertical2)
    gap1 = (second_Epot - Ep) * my.eh_kcal
    gap2 = (third_Epot - Ep) * my.eh_kcal

    ET1_mean.append(gap1)