Author Topic: THE LDDOS AT 1.6 V (Molecular Device Reference) script Error  (Read 2040 times)

0 Members and 1 Guest are viewing this topic.

Offline Parveen

  • Heavy QuantumATK user
  • ***
  • Posts: 26
  • Country: in
  • Reputation: 0
    • View Profile
i was trying to run this script already given in molecular device reference at http://quantumwise.com/documents/tutorials/latest/MolecularDevice/index.html/chap.iv.html#sect1.iv.lddos

the script is under headline of THE LDDOS AT 1.6V

configuration = nlread('au_dtb_au.nc', DeviceConfiguration)[8]

# make list of energies to be used for ldos
energies = numpy.linspace(-3,3,31)

# calculate ldos for each energy in the list
for e in energies:
    local_device_density_of_states = LocalDeviceDensityOfStates(
        configuration=configuration,
        energy=e*eV,
        kpoints=MonkhorstPackGrid(3,3),
        contributions=All,
        energy_zero_parameter=AverageFermiLevel,
        infinitesimal=1e-06*eV,
        self_energy_calculator=RecursionSelfEnergy(),
        spin=Spin.Sum,
        )
    nlsave(r'lddos16.nc', local_device_density_of_states)

when i run this script with the help of job manager, it return me a log file with error

Traceback (most recent call last):
  File "/tmp/2438853653008193.py", line 20, in <module>
    spin=Spin.Sum,
TypeError: __init__() got an unexpected keyword argument 'spin'


please suggest me what shall i modify.
Thank you

Offline Jess Wellendorff

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 933
  • Country: dk
  • Reputation: 29
    • View Profile
Re: THE LDDOS AT 1.6 V (Molecular Device Reference) script Error
« Reply #1 on: November 2, 2015, 13:55 »
Simply remove the line saying "spin=Spin.Sum," which is no-longer a valid argument to the LocalDeviceDensityOfStates analysis object.

Offline Parveen

  • Heavy QuantumATK user
  • ***
  • Posts: 26
  • Country: in
  • Reputation: 0
    • View Profile
Re: THE LDDOS AT 1.6 V (Molecular Device Reference) script Error
« Reply #2 on: November 2, 2015, 14:05 »
Thank you Jess for your valuable suggestion.

i got a think over it and i go to script generator and modify it accordingly by placing 1.6V to left electrode and 0V to right electrode in the new calculator and then sent it to editor and modify it accordingly too. And now i am running it with the help of job manager.

will this modification give me authentic results?

Offline Jess Wellendorff

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 933
  • Country: dk
  • Reputation: 29
    • View Profile
Re: THE LDDOS AT 1.6 V (Molecular Device Reference) script Error
« Reply #3 on: November 2, 2015, 14:08 »
I am not sure. It can sometimes be hard to get SCF-convergence with non-zero bias if starting from scratch. That's why we usually recommend to start from a converged zero-bias calculation when doing finite-bias calculations. But maybe it will work out for you :)