Пример #1
0
def set_cor_func(for_agg, params, ax_len = 10000):

    ax_length = ax_len
    # Needs to have small step for the dynamics to converge
    t_ax_sd = qr.TimeAxis(0.0, ax_length, 1)
    db = SpectralDensityDB()

    # Parameters for spectral density. ODBO, Renger or Silbey
    params = params
    with qr.energy_units('1/cm'):
        sd_low_freq = qr.SpectralDensity(t_ax_sd, params)

    reorg = qr.convert(sd_low_freq.measure_reorganization_energy(), "int", "1/cm")
    print("spectral density reorg -", reorg)

    # Adding the high freq modes
    sd_high_freq = db.get_SpectralDensity(t_ax_sd, "Wendling_JPCB_104_2000_5825")
    ax = sd_low_freq.axis
    sd_high_freq.axis = ax
    sd_tot = sd_low_freq + sd_high_freq

    cf = sd_tot.get_CorrelationFunction(temperature=params['T'], ta=t_ax_sd)
    # Assigning the correlation function to the list of molecules
    for mol in for_agg:
        mol.set_transition_environment((0,1),cf)
Пример #2
0
    def assign_spec_dens(self, sd_type = 'OverdampedBrownian', high_freq = True):

        t_ax_sd = qr.TimeAxis(0.0, 10000, 1)
        db = SpectralDensityDB()

        # Parameters for spectral density. ODBO, Renger or Silbey
        params = {
            "ftype": sd_type,
            "alternative_form": True,
            "reorg": self.reorg,
            "T": self.temp,
            "cortime": self.cor_time
            }
        with qr.energy_units('1/cm'):
            sd_low_freq = qr.SpectralDensity(t_ax_sd, params)

        if high_freq:
            # Adding the high freq modes
            sd_high_freq = db.get_SpectralDensity(t_ax_sd, "Wendling_JPCB_104_2000_5825")
            ax = sd_low_freq.axis
            sd_high_freq.axis = ax
            sd_tot = sd_low_freq + sd_high_freq

            cf = sd_tot.get_CorrelationFunction(temperature=self.temp, ta=t_ax_sd)
            # Assigning the correlation function to the list of molecules
        else:
            cf = sd_low_freq.get_CorrelationFunction(temperature=self.temp, ta=t_ax_sd)

        for mol in self.mol_list:
            mol.set_transition_environment((0,1),cf)
Пример #3
0
db = SpectralDensityDB()

# Parameters for spectral density. ODBO, Renger or Silbey
params = {
    "ftype": "OverdampedBrownian",
    #"ftype": "B777",
    "alternative_form": True,
    "reorg": reorganisation,
    "T": temperature,
    "cortime": cor_time
}
with qr.energy_units('1/cm'):
    sd_low_freq = qr.SpectralDensity(t_ax_sd, params)

# Adding the high freq modes
sd_high_freq = db.get_SpectralDensity(t_ax_sd, "Wendling_JPCB_104_2000_5825")
ax = sd_low_freq.axis
sd_high_freq.axis = ax
sd_tot = sd_low_freq + sd_high_freq

cf = sd_tot.get_CorrelationFunction(temperature=temperature, ta=t_ax_sd)
# Assigning the correlation function to the list of molecules
for mol in for_agg:
    mol.set_transition_environment((0, 1), cf)

if _test_:
    with qr.energy_units("1/cm"):
        sd_tot.plot(show=True, axis=[0, 2000, 0.0, np.max(sd_tot.data)])
    cf.plot(show=True)

#######################################################################
Пример #4
0
#            "reorg": reorganisation,
#            "T":temperature,
#            "cortime":cTime}
#with qr.energy_units("1/cm"):
#    sdLowFreq = qr.SpectralDensity(timeSD, paramsReng)
'''
# Over Damped Brownian Oscillaotr
params = {"ftype":"OverdampedBrownian",
          "T":temperature,
          "reorg":reorganisation,
          "cortime":cTime}
with qr.energy_units('1/cm'):
    sdLowFreq = qr.SpectralDensity(timeSD, params)
'''
# Silbey form of spec dens
sdLowFreq = db.get_SpectralDensity(timeSD, "Renger_JCP_2002")

# Adding the high freq modes
sdWend = db.get_SpectralDensity(timeSD, "Wendling_JPCB_104_2000_5825")
ax = sdLowFreq.axis
sdWend.axis = ax
sdTot = sdLowFreq + sdWend
cf = sdTot.get_CorrelationFunction(temperature=temperature, ta=timeSD)

if _show_:
    with qr.energy_units("1/cm"):
        sdTot.plot(show=True, axis=[0, 2000, 0.0, np.max(sdTot.data)])
    cf.plot(show=True)

#######################################################################
# Creation of the aggregate ring
# -*- coding: utf-8 -*-

import numpy
from quantarhei.models.spectdens import SpectralDensityDB 
#from quantarhei.models.spectdens import CorrelationFunctionDB
from quantarhei import SpectralDensity
from quantarhei import TimeAxis, energy_units

_show_plots_ = True

axis = TimeAxis(0.0, 10000, 1.0)

db = SpectralDensityDB(verbose=True)

sdw = db.get_SpectralDensity(axis, "Wendling_JPCB_104_2000_5825")
#sdw = db.get_SpectralDensity(axis, "Renger_JCP_2002")

params = dict(ftype="OverdampedBrownian", reorg=300.0, cortime=100.0)
with energy_units("1/cm"):
    sdob = SpectralDensity(axis, params)

ax = sdw.axis
sdob.axis = ax

sd_tot = sdob + sdw

with energy_units("1/cm"):
    if _show_plots_:
        sd_tot.plot(axis=[0, 1300, 0.0, numpy.max(sd_tot.data)])

    # here we get correlation function at a given temperature in K
Пример #6
0
# -*- coding: utf-8 -*-

import numpy
from quantarhei.models.spectdens import SpectralDensityDB
#from quantarhei.models.spectdens import CorrelationFunctionDB
from quantarhei import SpectralDensity
from quantarhei import TimeAxis, energy_units

axis = TimeAxis(0.0, 10000, 1.0)

db = SpectralDensityDB(verbose=True)
#sdw = db.get_SpectralDensity(axis, "Wendling_JPCB_104_2000_5825")
sdw = db.get_SpectralDensity(axis, "Renger_JCP_2002")

params = dict(ftype="OverdampedBrownian", reorg=300.0, cortime=100.0)
with energy_units("1/cm"):
    sdob = SpectralDensity(axis, params)

ax = sdw.axis
sdob.axis = ax

sd_tot = sdob + sdw

with energy_units("1/cm"):
    sd_tot.plot(axis=[0, 1300, 0.0, numpy.max(sd_tot.data)])

    cf = sd_tot.get_CorrelationFunction(300.0)

print(db.get_status_string())

cf.plot()