Recent Posts

Pages: [1] 2 3 ... 10
1
Hello!

Since a while, I've been trying to simulate the bandgap of the much celebrated VO2 monoclinic phase (single crystal) using the LCAO calculator with SGGA+U (Hubbard), with PBES functionals and PseudoDojo (ultra) pseudopotentials. I hope to open its bandgap to ~0.6 eV (experimental value), which maybe quite challenging. I have chosen an antiferromagnetic initial configuration with the antiparallel spins on the Vanadium atoms.

However, I am unable to converge the calculations and they seem to be oscillating. The density matrix report is as follows:
Code
0 E = -265.535 dE =  1.841101e+02 dH =  1.067618e+00
1 E = -278.785 dE =  1.325025e+01 dH =  5.624259e-01
2 E = -193.078 dE =  8.570705e+01 dH =  1.724710e+02
3 E = -122.926 dE =  7.015169e+01 dH =  3.727634e+01
4 E = -268.054 dE =  1.451278e+02 dH =  3.569472e+01
5 E = -274.404 dE =  6.349619e+00 dH =  6.521554e+01
6 E = -320.104 dE =  4.569986e+01 dH =  3.719561e+01
7 E = -391.865 dE =  7.176161e+01 dH =  3.002920e+01
8 E = -394.076 dE =  2.210358e+00 dH =  3.168863e+01
9 E = -394.507 dE =  4.318557e-01 dH =  2.987522e+01
10 E = -387.011 dE =  7.496348e+00 dH =  2.968226e+01
11 E = -389.401 dE =  2.390098e+00 dH =  3.002361e+01
This goes on forever... until it is artificially stopped by the maximum no. of iterations!

As of now, I have tried to increase the density mesh cut-off and decrease history steps, but they yield no difference. Any suggestions to make this converge would be highly appreciated.

The full script is attached for reference:
Code
# -*- coding: utf-8 -*-
# -------------------------------------------------------------
# Bulk Configuration
# -------------------------------------------------------------

# Set up lattice
lattice = SimpleMonoclinic(5.1836*Angstrom, 5.0504022144*Angstrom, 9.0187*Angstrom, 90.58*Degrees)

# Define elements
elements = [Vanadium, Vanadium, Vanadium, Vanadium, Vanadium, Vanadium,
            Vanadium, Vanadium, Oxygen, Oxygen, Oxygen, Oxygen, Oxygen, Oxygen,
            Oxygen, Oxygen, Oxygen, Oxygen, Oxygen, Oxygen, Oxygen, Oxygen,
            Oxygen, Oxygen]

# Define coordinates
fractional_coordinates = [[ 0.110304,  0.631185,  0.869553],
                          [ 0.110304,  0.868815,  0.369553],
                          [ 0.889696,  0.131185,  0.630447],
                          [ 0.889696,  0.368815,  0.130447],
                          [ 0.402394,  0.142849,  0.873272],
                          [ 0.402394,  0.357151,  0.373272],
                          [ 0.597606,  0.642849,  0.626728],
                          [ 0.597606,  0.857151,  0.126728],
                          [ 0.150305,  0.171076,  0.484713],
                          [ 0.150305,  0.328924,  0.984713],
                          [ 0.849695,  0.671076,  0.015287],
                          [ 0.849695,  0.828924,  0.515287],
                          [ 0.35536 ,  0.686591,  0.495905],
                          [ 0.35536 ,  0.813409,  0.995905],
                          [ 0.64464 ,  0.186591,  0.004095],
                          [ 0.64464 ,  0.313409,  0.504095],
                          [ 0.112774,  0.545407,  0.27475 ],
                          [ 0.112774,  0.954593,  0.77475 ],
                          [ 0.887226,  0.045407,  0.22525 ],
                          [ 0.887226,  0.454593,  0.72525 ],
                          [ 0.388671,  0.038549,  0.269627],
                          [ 0.388671,  0.461451,  0.769627],
                          [ 0.611329,  0.538549,  0.230373],
                          [ 0.611329,  0.961451,  0.730373]]

# Set up configuration
bulk_configuration = BulkConfiguration(
    bravais_lattice=lattice,
    elements=elements,
    fractional_coordinates=fractional_coordinates
    )

# -------------------------------------------------------------
# Calculator
# -------------------------------------------------------------
#----------------------------------------
# Basis Set
#----------------------------------------
oxygen_1s = HydrogenOrbital(
    principal_quantum_number=1,
    angular_momentum=0,
    radial_cutoff_radius=3.89375*Angstrom,
    confinement_start_radius=3.115*Angstrom,
    charge=0.75,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_2p = ConfinedOrbital(
    principal_quantum_number=2,
    angular_momentum=1,
    radial_cutoff_radius=4.1953125*Angstrom,
    confinement_start_radius=3.35625*Angstrom,
    additional_charge=0,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_2p_0 = HydrogenOrbital(
    principal_quantum_number=2,
    angular_momentum=1,
    radial_cutoff_radius=4.1205078125*Angstrom,
    confinement_start_radius=3.29640625*Angstrom,
    charge=1.8,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_2s = ConfinedOrbital(
    principal_quantum_number=2,
    angular_momentum=0,
    radial_cutoff_radius=3.1171875*Angstrom,
    confinement_start_radius=2.49375*Angstrom,
    additional_charge=0,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_3d = HydrogenOrbital(
    principal_quantum_number=3,
    angular_momentum=2,
    radial_cutoff_radius=2.8125*Angstrom,
    confinement_start_radius=2.25*Angstrom,
    charge=7.6,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_3d_0 = HydrogenOrbital(
    principal_quantum_number=3,
    angular_momentum=2,
    radial_cutoff_radius=3.287109375*Angstrom,
    confinement_start_radius=2.6296875*Angstrom,
    charge=5.6,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_3p = HydrogenOrbital(
    principal_quantum_number=3,
    angular_momentum=1,
    radial_cutoff_radius=3.071875*Angstrom,
    confinement_start_radius=2.4575*Angstrom,
    charge=6.2,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_3s = HydrogenOrbital(
    principal_quantum_number=3,
    angular_momentum=0,
    radial_cutoff_radius=3.55625*Angstrom,
    confinement_start_radius=2.845*Angstrom,
    charge=6.4,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_4f = HydrogenOrbital(
    principal_quantum_number=4,
    angular_momentum=3,
    radial_cutoff_radius=2.78125*Angstrom,
    confinement_start_radius=2.225*Angstrom,
    charge=11.6,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

oxygen_5g = HydrogenOrbital(
    principal_quantum_number=5,
    angular_momentum=4,
    radial_cutoff_radius=2.57421875*Angstrom,
    confinement_start_radius=2.059375*Angstrom,
    charge=17.6,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

OxygenBasis = BasisSet(
    element=PeriodicTable.Oxygen,
    orbitals=[oxygen_2s, oxygen_2p, oxygen_2p_0, oxygen_3d, oxygen_3s, oxygen_4f, oxygen_3p, oxygen_3d_0, oxygen_5g, oxygen_1s],
    occupations=[3.5, 3.5, 2.0, -0.5, -0.5, -2.0, 0.0, 0.0, 0.0, 0.0],
    hubbard_u=[0.0, 0.95, 0.95, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]*eV,
    dft_half_parameters=Automatic,
    filling_method=SphericalSymmetric,
    onsite_spin_orbit_split=[0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]*eV,
    pseudopotential=NormConservingPseudoPotential("normconserving/pseudodojo/gga/stringent/08_O.upf", local_potential_cutoff_threshold=1e-06*Hartree, local_potential_cutoff_radius=6.0*Bohr),
    )

vanadium_1s = HydrogenOrbital(
    principal_quantum_number=1,
    angular_momentum=0,
    radial_cutoff_radius=3.653125*Angstrom,
    confinement_start_radius=2.9225*Angstrom,
    charge=0.6,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_3d = ConfinedOrbital(
    principal_quantum_number=3,
    angular_momentum=2,
    radial_cutoff_radius=3.46875*Angstrom,
    confinement_start_radius=2.775*Angstrom,
    additional_charge=0,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_3d_0 = HydrogenOrbital(
    principal_quantum_number=3,
    angular_momentum=2,
    radial_cutoff_radius=4.348828125*Angstrom,
    confinement_start_radius=3.4790625*Angstrom,
    charge=3,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_3d_1 = HydrogenOrbital(
    principal_quantum_number=3,
    angular_momentum=2,
    radial_cutoff_radius=2.94140625*Angstrom,
    confinement_start_radius=2.353125*Angstrom,
    charge=5.4,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_3p = ConfinedOrbital(
    principal_quantum_number=3,
    angular_momentum=1,
    radial_cutoff_radius=2.8359375*Angstrom,
    confinement_start_radius=2.26875*Angstrom,
    additional_charge=0,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_3s = ConfinedOrbital(
    principal_quantum_number=3,
    angular_momentum=0,
    radial_cutoff_radius=2.6171875*Angstrom,
    confinement_start_radius=2.09375*Angstrom,
    additional_charge=0,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4d = HydrogenOrbital(
    principal_quantum_number=4,
    angular_momentum=2,
    radial_cutoff_radius=4.412109375*Angstrom,
    confinement_start_radius=3.5296875*Angstrom,
    charge=7,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4f = HydrogenOrbital(
    principal_quantum_number=4,
    angular_momentum=3,
    radial_cutoff_radius=3.8875*Angstrom,
    confinement_start_radius=3.11*Angstrom,
    charge=9,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4f_0 = HydrogenOrbital(
    principal_quantum_number=4,
    angular_momentum=3,
    radial_cutoff_radius=2.3515625*Angstrom,
    confinement_start_radius=1.88125*Angstrom,
    charge=11.2,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4p = ConfinedOrbital(
    principal_quantum_number=4,
    angular_momentum=1,
    radial_cutoff_radius=2.545703125*Angstrom,
    confinement_start_radius=2.0365625*Angstrom,
    additional_charge=2,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4p_0 = HydrogenOrbital(
    principal_quantum_number=4,
    angular_momentum=1,
    radial_cutoff_radius=4.79296875*Angstrom,
    confinement_start_radius=3.834375*Angstrom,
    charge=5.6,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4s = ConfinedOrbital(
    principal_quantum_number=4,
    angular_momentum=0,
    radial_cutoff_radius=3.615625*Angstrom,
    confinement_start_radius=2.8925*Angstrom,
    additional_charge=0,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_4s_0 = ConfinedOrbital(
    principal_quantum_number=4,
    angular_momentum=0,
    radial_cutoff_radius=2.305078125*Angstrom,
    confinement_start_radius=1.8440625*Angstrom,
    additional_charge=2,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_5f = HydrogenOrbital(
    principal_quantum_number=5,
    angular_momentum=3,
    radial_cutoff_radius=3.48046875*Angstrom,
    confinement_start_radius=2.784375*Angstrom,
    charge=11.2,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_5g = HydrogenOrbital(
    principal_quantum_number=5,
    angular_momentum=4,
    radial_cutoff_radius=2.73828125*Angstrom,
    confinement_start_radius=2.190625*Angstrom,
    charge=12.8,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

vanadium_5g_0 = HydrogenOrbital(
    principal_quantum_number=5,
    angular_momentum=4,
    radial_cutoff_radius=2.70703125*Angstrom,
    confinement_start_radius=2.165625*Angstrom,
    charge=14,
    confinement_strength=12.5*Hartree,
    confinement_power=2,
    radial_step_size=0.001*Bohr,
    )

VanadiumBasis = BasisSet(
    element=PeriodicTable.Vanadium,
    orbitals=[vanadium_3s, vanadium_3p, vanadium_4s, vanadium_3d, vanadium_4f, vanadium_3d_0, vanadium_4p, vanadium_5g, vanadium_4s_0, vanadium_3d_1, vanadium_5f, vanadium_4d, vanadium_4f_0, vanadium_4p_0, vanadium_5g_0, vanadium_1s],
    occupations=[2.0, 5.5, 5.0, 4.0, -3.5, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0],
    hubbard_u=[0.0, 0.0, 0.0, 5.2, 0.0, 5.2, 0.0, 0.0, 0.0, 5.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]*eV,
    dft_half_parameters=Automatic,
    filling_method=SphericalSymmetric,
    onsite_spin_orbit_split=[0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0]*eV,
    pseudopotential=NormConservingPseudoPotential("normconserving/pseudodojo/gga/standard/23_V.upf", local_potential_cutoff_threshold=1e-06*Hartree, local_potential_cutoff_radius=6.0*Bohr),
    )

basis_set = [
    OxygenBasis,
    VanadiumBasis,
    ]

#----------------------------------------
# Exchange-Correlation
#----------------------------------------
exchange_correlation = SGGAU.PBES

k_point_sampling = KpointDensity(
    density_a=4.0*Angstrom,
    )
numerical_accuracy_parameters = NumericalAccuracyParameters(
    density_mesh_cutoff=200.0*Hartree,
    k_point_sampling=k_point_sampling,
    )

iteration_control_parameters = IterationControlParameters(
    number_of_history_steps=15,
    )

calculator = LCAOCalculator(
    basis_set=basis_set,
    exchange_correlation=exchange_correlation,
    numerical_accuracy_parameters=numerical_accuracy_parameters,
    iteration_control_parameters=iteration_control_parameters,
    )

bulk_configuration.setCalculator(calculator)

# -------------------------------------------------------------
# Initial State
# -------------------------------------------------------------
scaled_spins = [
    1.0,
    1.0,
    1.0,
    1.0,
    -1.0,
    -1.0,
    -1.0,
    -1.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
    0.0,
]
initial_spin = InitialSpin(scaled_spins=scaled_spins)

bulk_configuration.setCalculator(
    calculator,
    initial_spin=initial_spin,
)
bulk_configuration.update()
nlsave('E:/Praful/20240503/VO2 Monoclinic script LCAO test.hdf5', bulk_configuration)
nlprint(bulk_configuration)

# -------------------------------------------------------------
# Bandstructure
# -------------------------------------------------------------
bandstructure = Bandstructure(
    configuration=bulk_configuration,
    route=['G', 'Y', 'C', 'Z', 'E', 'A', 'G', 'B', 'D', 'Z', 'G'],
    points_per_segment=20,
    bands_above_fermi_level=30,
    method=Full,
    )
nlsave('E:/Praful/20240503/VO2 Monoclinic script LCAO test.hdf5', bandstructure)


Kind regards,
Praful

2
General Questions and Answers / Re: Orbital coefficients
« Last post by Anders Blom on May 13, 2024, 20:17 »
It just need to have converged the molecular calculation. You can project on individual atoms (the example shows projection on N, H, H, H through the numbers 0,1,2,3.) or a collection of atoms by giving more than one index in the list.
3
General Questions and Answers / Re: Orbital coefficients
« Last post by lohy on May 13, 2024, 08:38 »
Wonderful thank you!  - you had a great idea 10 years ago  :)

Just to be sure, the script "only" needs the configuration and the energy state of the molecule I am interested in? and then I can choose which atoms I want to project on? where you have e.g. 0, can I then have a list or do I need to have a line for each atom in the molecule?
4
How to get/plot the loss function for the training/testing set of the moment tensor potential, i.e., variation in the error with respect to the number of epochs.
5
General Questions and Answers / Re: Random Swap of Elements
« Last post by Anders Blom on May 10, 2024, 00:17 »
Python coding...
You can easily access the elements in a structure with configuration.elements(), that gives a list of the elements, you can then use the random.random() function to pick indices in a relevant way, replace an element and then put it back into the configuration with the secret method configuration._changeAtoms(elements=new_elements).

Or you can just remake the configuration from it's old parts:
new_configuration = BulkConfiguration(old_configuration.bravaisLattice(), new_elements, old_configuration.cartesianCoordinates())
6
General Questions and Answers / Re: Orbital coefficients
« Last post by Anders Blom on May 9, 2024, 21:42 »
Lucky for you I actually wrote a script to do this about 10 years ago, but nobody seemed to need the functionality so we never made it a feature in the software.

The usage is pretty obvious; the return is a list (one entry per eigenstate) of arrays, which contain the "contributions" (projections) onto the angular momenta s, p, d, and f.

I tested with NH3 from the example in the manual (https://docs.quantumatk.com/manual/Types/ElectronDensity/ElectronDensity.html) and the run this slightly clumsy code

Code: python
from PartialNorm import getPartialNorms
molecule = nlread("nh3.hdf5", MoleculeConfiguration)[0]
# HOMO state is 3
ix = 3
partial_norms = getPartialNorms(molecule, projection_atoms=[0])
print(partial_norms[ix])
partial_norms = getPartialNorms(molecule, projection_atoms=[1])
print(partial_norms[ix])
partial_norms = getPartialNorms(molecule, projection_atoms=[2])
print(partial_norms[ix])
partial_norms = getPartialNorms(molecule, projection_atoms=[3])
print(partial_norms[ix])

We can then see that the HOMO level derives almost 90% from Nitrogen (mostly p-states), but if we change to ix=4 we note that LUMO has a lot more H contributions (and the LUMO state is, as expected, dominated by s-states). Hopefully this is helpful for the analysis of your molecule too.

This function can be used for a lot of other cool things, like mapping out where s and p states dominate in the band structure of GaAs (RGB color scale mapped from spd contributions) as in the attached picture!
7
Yes the same trick should work
8
Yeah that should be enough. Are these DOS lines at very low energy or around the Fermi level? Really hard to provide any help without the actual input and output...
9
General Questions and Answers / Re: Unit trouble dipole moments
« Last post by Anders Blom on May 9, 2024, 20:30 »
I don't think there should be any confusion about units? It prints
X Y Z of dipole: [ 7.50489746e-07 -5.50684384e-05  6.86097535e-01] Bohr**4*e
to the file, and if you had printed the magnitude as you perhaps intended (you write m1 to the file) it would have shown
0.686097536725 Bohr**4*e

(The numbers are not your numbers as I don't have your molecule, I just use NH3 as an example)

Oh, I see you still use the old wrong script from the manual. You need to remove * length_unit**3 from the line defining dV
10
Hello,

I am having the same issue with V-2023.12 with the builder tool on Windows. Restore Layout also does not work... is there a similar work around?

Thanks!
Pages: [1] 2 3 ... 10