36 use,
intrinsic :: iso_fortran_env
80 integer :: ldos_nenergies = -1
81 real(real64),
allocatable :: ldos_energies(:)
83 integer(int64) :: method
92 subroutine dos_init(this, namespace, st, kpoints)
93 type(dos_t),
intent(out) :: this
94 type(namespace_t),
intent(in) :: namespace
95 type(states_elec_t),
intent(in) :: st
96 type(kpoints_t),
intent(in) :: kpoints
98 real(real64) :: evalmin, evalmax, eextend
106 npath = kpoints%nkpt_in_path()
107 if (st%nik > npath)
then
108 evalmin = minval(st%eigenval(1:st%nst, 1:(st%nik-npath)))
109 evalmax = maxval(st%eigenval(1:st%nst, 1:(st%nik-npath)))
111 evalmin = minval(st%eigenval(1:st%nst, 1:st%nik))
112 evalmax = maxval(st%eigenval(1:st%nst, 1:st%nik))
115 eextend = (evalmax - evalmin) /
m_four
132 call parse_variable(namespace,
'DOSMethod', option__dosmethod__smear, this%method)
186 call parse_variable(namespace,
'DOSEnergyPoints', 500, this%epoints)
195 call parse_variable(namespace,
'DOSGamma', 0.008_real64, this%gamma)
201 this%de = (this%emax - this%emin) / (this%epoints - 1)
213 safe_allocate(this%ldos_energies(1:this%ldos_nenergies))
214 do ie = 1, this%ldos_nenergies
219 this%ldos_nenergies = -1
227 type(
dos_t),
intent(inout) :: this
231 safe_deallocate_a(this%ldos_energies)
232 this%ldos_nenergies = -1
239 subroutine dos_write_dos(this, dir, st, box, ions, mesh, hm, namespace)
240 type(
dos_t),
intent(in) :: this
241 character(len=*),
intent(in) :: dir
243 class(
box_t),
intent(in) :: box
244 type(
ions_t),
target,
intent(in) :: ions
245 class(
mesh_t),
intent(in) :: mesh
249 integer :: ie, ik, ist, is, ns, maxdos, nvertices
250 integer,
allocatable :: iunit(:)
251 real(real64) :: energy
252 real(real64),
allocatable :: tdos(:)
253 real(real64),
allocatable :: dos(:,:,:)
254 character(len=64) :: filename
260 real(real64) :: e_simplex(20)
261 real(real64),
allocatable :: energies(:), dos_simplex_batch(:,:), dos_thread(:,:)
267 if (st%d%nspin == 2) ns = 2
270 smear%method = this%smear_func
273 if (st%system_grp%is_root())
then
275 safe_allocate(dos(1:this%epoints, 1:st%nst, 0:ns-1))
277 safe_allocate(iunit(0:ns-1))
284 write(filename,
'(a,i5.5,a,i1.1,a)')
'dos-', ist,
'-', is+1,
'.dat'
286 write(filename,
'(a,i5.5,a)')
'dos-', ist,
'.dat'
288 iunit(is) =
io_open(trim(dir)//
'/'//trim(filename), namespace, action=
'write')
293 select case (this%method)
294 case (option__dosmethod__smear)
295 do ie = 1, this%epoints
296 energy = this%emin + (ie - 1) * this%de
298 do ik = 1, st%nik, ns
300 dos(ie, ist, is) = dos(ie, ist, is) + st%kweights(ik+is) / this%gamma * &
306 case (option__dosmethod__tetrahedra, option__dosmethod__tetrahedra_opt)
307 assert(
associated(hm%kpoints%reduced%simplex))
308 simplex => hm%kpoints%reduced%simplex
309 nvertices = simplex%rdim + 1
310 assert(nvertices <= 4)
312 safe_allocate(energies(1:this%epoints))
313 do ie = 1, this%epoints
314 energies(ie) = this%emin + (ie - 1) * this%de
317 safe_allocate(dos_simplex_batch(1:nvertices, 1:this%epoints))
318 safe_allocate(dos_thread(1:this%epoints, 0:ns-1))
321 do ii = 1, simplex%n_simplices
323 do ll = 1, simplex%sdim
324 ik = simplex%simplices(ii, ll)
325 ik = ns * (ik - 1) + 1
326 e_simplex(ll) = st%eigenval(ist, ik+is)
329 call simplex_dos(simplex%rdim, e_simplex(1:simplex%sdim), energies, dos_simplex_batch)
331 do ie = 1, this%epoints
332 dos_thread(ie, is) = dos_thread(ie, is) + sum(dos_simplex_batch(1:nvertices, ie)) / simplex%n_points
338 dos(:, ist, :) = dos(:, ist, :) + dos_thread
340 safe_deallocate_a(dos_thread)
341 safe_deallocate_a(dos_simplex_batch)
343 safe_deallocate_a(energies)
350 do ie = 1, this%epoints
351 energy = this%emin + (ie - 1) * this%de
364 safe_allocate(tdos(1))
369 write(filename,
'(a,i1.1,a)')
'total-dos-', is+1,
'.dat'
370 iunit(is) =
io_open(trim(dir)//
'/'//trim(filename), namespace, action=
'write')
372 write(iunit(is),
'(3a)')
'# energy [', trim(
units_abbrev(
units_out%energy)),
'], total DOS (spin-resolved)'
374 do ie = 1, this%epoints
375 energy = this%emin + (ie - 1) * this%de
378 tdos(1) = tdos(1) + dos(ie, ist, is)
390 iunit(0) =
io_open(trim(dir)//
'/'//
'total-dos.dat', namespace, action=
'write')
394 do ie = 1, this%epoints
395 energy = this%emin + (ie - 1) * this%de
399 tdos(1) = tdos(1) + dos(ie, ist, is)
409 safe_deallocate_a(tdos)
413 iunit(0) =
io_open(trim(dir)//
'/'//
'total-dos-efermi.dat', namespace, action=
'write')
415 '] in a format compatible with total-dos.dat'
418 maxdos = st%smear%el_per_state * st%nst
429 safe_deallocate_a(iunit)
430 safe_deallocate_a(dos)
437 subroutine dos_write_pdos(this, dir, st, box, ions, mesh, hm, namespace)
438 type(
dos_t),
intent(in) :: this
439 character(len=*),
intent(in) :: dir
441 class(
box_t),
intent(in) :: box
442 type(
ions_t),
target,
intent(in) :: ions
443 class(
mesh_t),
intent(in) :: mesh
447 integer :: ie, ik, ist, is, ns, ib, ind, nvertices
449 real(real64) :: energy, threshold
450 character(len=64) :: filename, format_str
453 integer :: ii, ll, mm, nn, work, norb, work2
454 integer :: ia, iorb, idim
455 real(real64),
allocatable :: ddot(:,:,:)
456 complex(real64),
allocatable :: zdot(:,:,:)
457 real(real64),
allocatable :: weight(:,:,:)
463 real(real64) :: e_simplex(20), a_simplex(4)
464 real(real64),
allocatable :: energies(:), dos_simplex_batch(:,:), pdos(:,:), pdos_thread(:,:)
470 if (st%d%nspin == 2) ns = 2
473 smear%method = this%smear_func
477 call parse_variable(namespace,
'AOThreshold', 0.01_real64, threshold)
480 do ia = 1, ions%natoms
487 os%spec => ions%atom(ia)%species
491 do iorb = 1, os%spec%get_niwfs()
492 call os%spec%get_iwf_ilm(iorb, 1, ii, ll, mm)
493 call os%spec%get_iwf_n(iorb, 1, nn)
499 option__aotruncation__ao_full, threshold)
505 os%use_submesh = .false.
506 os%allocated_on_mesh = .
true.
507 os%spec => ions%atom(ia)%species
509 do work = 1, os%norbs
513 ions%atom(ia)%species, mesh, os%sphere, os%ii, os%ll, os%jj, &
514 os, work, os%radius, os%ndim, use_mesh=.not.os%use_submesh, &
515 normalize = normalize)
518 ions%atom(ia)%species, mesh, os%sphere, os%ii, os%ll, os%jj, &
519 os, work, os%radius, os%ndim, &
520 use_mesh = .not. hm%phase%is_allocated() .and. .not. os%use_submesh, &
521 normalize = normalize)
525 if (hm%phase%is_allocated())
then
527 safe_allocate(os%phase(1:os%sphere%np, st%d%kpt%start:st%d%kpt%end))
530 if (.not. os%use_submesh)
then
531 safe_allocate(os%eorb_mesh(1:mesh%np, 1:os%norbs, 1:os%ndim, st%d%kpt%start:st%d%kpt%end))
534 safe_allocate(os%eorb_submesh(1:os%sphere%np, 1:os%ndim, 1:os%norbs, st%d%kpt%start:st%d%kpt%end))
535 os%eorb_submesh(:,:,:,:) =
m_zero
539 os%ldorbs_eorb = max(
pad_pow2(os%sphere%np), 1)
540 if(.not. os%use_submesh) os%ldorbs_eorb = max(
pad_pow2(os%sphere%mesh%np), 1)
542 safe_allocate(os%buff_eorb(st%d%kpt%start:st%d%kpt%end))
543 do ik= st%d%kpt%start, st%d%kpt%end
549 vec_pot = hm%hm_base%uniform_vector_potential, &
550 vec_pot_var = hm%hm_base%vector_potential)
559 if (st%system_grp%is_root())
then
561 write(filename,
'(a, i4.4, a1, a, i1.1, a1,a)')
'pdos-at', ia,
'-', trim(os%spec%get_label()), &
564 write(filename,
'(a, i4.4, a1, a, a1,a)')
'pdos-at', ia,
'-', trim(os%spec%get_label()), &
568 iunit =
io_open(trim(dir)//
'/'//trim(filename), namespace, action=
'write')
571 '], projected DOS (total and orbital resolved)'
575 safe_allocate(ddot(1:st%d%dim, 1:os%norbs, 1:st%block_size))
577 safe_allocate(zdot(1:st%d%dim, 1:os%norbs, 1:st%block_size))
580 safe_allocate(weight(1:os%norbs,1:st%nik,1:st%nst))
581 weight(1:os%norbs,1:st%nik,1:st%nst) =
m_zero
583 do ik = st%d%kpt%start, st%d%kpt%end
584 do ib = st%group%block_start, st%group%block_end
586 if (hm%phase%is_allocated())
then
588 call st%group%psib(ib, ik)%copy_to(epsib)
589 call hm%phase%apply_to(mesh, mesh%np, .false., epsib, src = st%group%psib(ib, ik))
591 epsib => st%group%psib(ib, ik)
596 do ist = 1, st%group%psib(ib, ik)%nst
597 ind = st%group%psib(ib, ik)%ist(ist)
598 do iorb = 1, os%norbs
599 do idim = 1, st%d%dim
600 weight(iorb, ik, ind) = weight(iorb, ik, ind) + st%kweights(ik) * abs(ddot(idim, iorb, ist))**2
606 do ist = 1, st%group%psib(ib, ik)%nst
607 ind = st%group%psib(ib, ik)%ist(ist)
608 do iorb = 1, os%norbs
609 do idim = 1, st%d%dim
610 weight(iorb, ik, ind) = weight(iorb, ik, ind) + st%kweights(ik) * abs(zdot(idim, iorb, ist))**2
616 if (hm%phase%is_allocated())
then
617 call epsib%end(copy=.false.)
618 safe_deallocate_p(epsib)
624 if (st%parallel_in_states .or. st%d%kpt%parallel)
then
628 safe_deallocate_a(ddot)
629 safe_deallocate_a(zdot)
631 if (st%system_grp%is_root())
then
632 write(format_str,
'(a,i5,a)')
'(', os%norbs+2,
'es25.16E3)'
633 safe_allocate(pdos(1:os%norbs, 1:this%epoints))
635 select case (this%method)
636 case (option__dosmethod__smear)
637 do iorb = 1, os%norbs
640 do ie = 1, this%epoints
641 energy = this%emin + (ie - 1) * this%de
642 pdos(iorb, ie) = pdos(iorb, ie) + weight(iorb,ik,ist) / this%gamma * &
648 case (option__dosmethod__tetrahedra, option__dosmethod__tetrahedra_opt)
649 assert(
associated(hm%kpoints%reduced%simplex))
650 simplex => hm%kpoints%reduced%simplex
651 nvertices = simplex%rdim + 1
652 assert(nvertices <= 4)
653 safe_allocate(energies(1:this%epoints))
654 do ie = 1, this%epoints
655 energies(ie) = this%emin + (ie - 1) * this%de
659 safe_allocate(dos_simplex_batch(1:nvertices, 1:this%epoints))
660 safe_allocate(pdos_thread(1:os%norbs, 1:this%epoints))
664 do ii = 1, simplex%n_simplices
666 do ll = 1, simplex%sdim
667 ik = simplex%simplices(ii, ll)
668 ik = ns * (ik - 1) + 1
669 e_simplex(ll) = st%eigenval(ist, ik+is)
671 call simplex_dos(simplex%rdim, e_simplex(1:simplex%sdim), energies, dos_simplex_batch)
672 do iorb = 1, os%norbs
674 ik = simplex%simplices(ii, ll)
675 ik = ns * (ik - 1) + 1
677 a_simplex(ll) = weight(iorb, ik+is, ist) / st%kweights(ik+is)
682 do ie = 1, this%epoints
683 pdos_thread(iorb, ie) = pdos_thread(iorb, ie) + &
684 sum(a_simplex(1:nvertices) * dos_simplex_batch(1:nvertices, ie)) / simplex%n_points
692 pdos(:,:) = pdos(:,:) + pdos_thread(:,:)
694 safe_deallocate_a(pdos_thread)
695 safe_deallocate_a(dos_simplex_batch)
698 safe_deallocate_a(energies)
702 do ie = 1, this%epoints
703 energy = this%emin + (ie - 1) * this%de
708 safe_deallocate_a(pdos)
713 safe_deallocate_a(weight)
725 type(
dos_t),
intent(in) :: this
726 character(len=*),
intent(in) :: dir
728 type(
ions_t),
target,
intent(in) :: ions
732 integer :: ie, ik, val, cond, is, ns, ll, ii, nvertices
733 integer,
allocatable :: iunit(:)
734 real(real64) :: energy
735 real(real64) :: tjdos(1), e_simplex(20), occ_simplex(4)
736 real(real64),
allocatable :: jdos(:,:), energies(:), dos_simplex(:,:)
737 character(len=64) :: filename
746 if (st%d%nspin == 2) ns = 2
749 smear%method = this%smear_func
752 if (st%system_grp%is_root())
then
754 safe_allocate(jdos(1:this%epoints, 0:ns-1))
755 safe_allocate(iunit(0:ns-1))
758 select case (this%method)
759 case (option__dosmethod__smear)
762 do cond = val, st%nst
763 do ik = 1, st%nik, ns
766 if(st%occ(cond, ik+is) >
m_epsilon) cycle
767 do ie = 1, this%epoints
768 energy = (ie - 1) * this%de
770 jdos(ie, is) = jdos(ie, is) + st%kweights(ik+is) / this%gamma * &
771 smear_delta_function(smear, (energy - (st%eigenval(cond, ik+is)-st%eigenval(val, ik+is)))/this%gamma)
777 case (option__dosmethod__tetrahedra, option__dosmethod__tetrahedra_opt)
778 assert(
associated(hm%kpoints%reduced%simplex))
779 simplex => hm%kpoints%reduced%simplex
780 nvertices = simplex%rdim + 1
781 assert(nvertices <= 4)
783 safe_allocate(energies(1:this%epoints))
784 do ie = 1, this%epoints
785 energies(ie) = (ie - 1) * this%de
789 safe_allocate(dos_simplex(1:nvertices, 1:this%epoints))
793 do ii = 1, simplex%n_simplices
794 if (cond < val) cycle
796 do ll = 1, simplex%sdim
797 ik = simplex%simplices(ii, ll)
798 ik = ns * (ik - 1) + 1
799 e_simplex(ll) = st%eigenval(cond, ik+is) - st%eigenval(val, ik+is)
803 ik = simplex%simplices(ii, ll)
804 ik = ns * (ik - 1) + 1
806 occ_simplex(ll) =
m_one
813 if (all(transfer(occ_simplex(1:nvertices), [0_int64]) == 0_int64)) cycle
815 call simplex_dos(simplex%rdim, e_simplex(1:simplex%sdim), energies, dos_simplex)
816 do ie = 1, this%epoints
817 jdos(ie, is) = jdos(ie, is) + sum(occ_simplex(1:nvertices) * dos_simplex(1:nvertices, ie)) / &
825 safe_deallocate_a(dos_simplex)
827 safe_deallocate_a(energies)
834 if (st%d%nspin > 1)
then
836 write(filename,
'(a,i1.1,a)')
'total-jdos-', is+1,
'.dat'
837 iunit(is) =
io_open(trim(dir)//
'/'//trim(filename), namespace, action=
'write')
839 write(iunit(is),
'(3a)')
'# energy [', trim(
units_abbrev(
units_out%energy)),
'], total JDOS (spin-resolved)'
841 do ie = 1, this%epoints
842 energy = (ie - 1) * this%de
853 iunit(0) =
io_open(trim(dir)//
'/'//
'total-jdos.dat', namespace, action=
'write')
857 do ie = 1, this%epoints
858 energy = (ie - 1) * this%de
861 tjdos(1) = tjdos(1) + jdos(ie, is)
871 safe_deallocate_a(iunit)
872 safe_deallocate_a(jdos)
880 subroutine dos_write_ldos(this, dir, st, ions, gr, hm, how, namespace)
881 type(
dos_t),
intent(in) :: this
882 character(len=*),
intent(in) :: dir
884 type(
ions_t),
target,
intent(in) :: ions
885 type(
grid_t),
intent(in) :: gr
887 integer(int64),
intent(in) :: how
890 integer :: ie, ik, ist, is, ns, ip, ifull, ierr, ii, ll, nvertices, ikpoint
891 integer :: iop, iiop, nops, nops_max
892 character(len=MAX_PATH_LEN) :: fname, name
893 logical :: has_local_corner
894 real(real64) :: weight, e_simplex(20)
895 real(real64),
allocatable :: ldos(:,:,:), dpsi(:,:), abs_psi2(:), abs_psi2_symm(:), ldos_weights(:,:,:)
896 real(real64),
allocatable :: dos_simplex(:,:)
897 complex(real64),
allocatable :: zpsi(:,:)
905 if (this%ldos_nenergies < 1)
then
906 message(1) =
"LDOSEnergies must be defined for Output=ldos"
912 if (st%d%nspin == 2) ns = 2
915 smear%method = this%smear_func
921 safe_allocate(ldos(1:gr%np, 1:this%ldos_nenergies, 1:ns))
924 safe_allocate(abs_psi2(1:gr%np))
926 safe_allocate(dpsi(1:gr%np, 1:st%d%dim))
928 safe_allocate(zpsi(1:gr%np, 1:st%d%dim))
931 select case (this%method)
932 case (option__dosmethod__smear)
934 safe_allocate(ldos_weights(1:this%ldos_nenergies, st%d%kpt%start:st%d%kpt%end, 1:nops_max))
935 case (option__dosmethod__tetrahedra, option__dosmethod__tetrahedra_opt)
936 assert(
associated(hm%kpoints%full%simplex))
937 simplex => hm%kpoints%full%simplex
938 nvertices = simplex%rdim + 1
939 assert(nvertices <= 4)
941 do ifull = 1, hm%kpoints%full%npoints
942 nops_max = max(nops_max, hm%kpoints%get_full_symmetry_op_index(ifull))
944 safe_allocate(ldos_weights(1:this%ldos_nenergies, st%d%kpt%start:st%d%kpt%end, 1:nops_max))
945 safe_allocate(abs_psi2_symm(1:gr%np))
950 do ist = st%st_start, st%st_end
951 ldos_weights(:, :, :) =
m_zero
953 select case (this%method)
954 case (option__dosmethod__smear)
955 do ik = st%d%kpt%start, st%d%kpt%end
956 do ie = 1, this%ldos_nenergies
957 ldos_weights(ie, ik, 1) = st%kweights(ik) / this%gamma * &
961 case (option__dosmethod__tetrahedra, option__dosmethod__tetrahedra_opt)
965 safe_allocate(dos_simplex(1:nvertices, 1:this%ldos_nenergies))
967 do ii = 1, simplex%n_simplices
969 has_local_corner = .false.
970 do ll = 1, simplex%sdim
971 ik = hm%kpoints%get_equiv(simplex%simplices(ii, ll))
972 ik = ns * (ik - 1) + 1 + is
973 e_simplex(ll) = st%eigenval(ist, ik)
974 if (ik >= st%d%kpt%start .and. ik <= st%d%kpt%end) has_local_corner = .
true.
976 if (.not. has_local_corner) cycle
978 call simplex_dos(simplex%rdim, e_simplex(1:simplex%sdim), this%ldos_energies, &
979 dos_simplex(1:nvertices, 1:this%ldos_nenergies))
980 do ie = 1, this%ldos_nenergies
982 ifull = simplex%simplices(ii, ll)
983 iiop = hm%kpoints%get_full_symmetry_op_index(ifull)
984 ik = hm%kpoints%get_equiv(ifull)
985 ik = ns * (ik - 1) + 1 + is
986 if (ik >= st%d%kpt%start .and. ik <= st%d%kpt%end)
then
987 ldos_weights(ie, ik, iiop) = ldos_weights(ie, ik, iiop) + dos_simplex(ll, ie) / simplex%n_points
994 safe_deallocate_a(dos_simplex)
1001 do ik = st%d%kpt%start, st%d%kpt%end
1002 is = st%d%get_spin_index(ik)
1007 abs_psi2(ip) = dpsi(ip, 1)**2
1008 if (st%d%dim > 1)
then
1009 abs_psi2(ip) = abs_psi2(ip) + dpsi(ip, 2)**2
1012 if (st%d%dim > 1)
then
1014 abs_psi2(ip) = abs_psi2(ip) + dpsi(ip, 2)**2
1020 abs_psi2(ip) = real(conjg(zpsi(ip, 1)) * zpsi(ip, 1), real64)
1021 if (st%d%dim > 1)
then
1022 abs_psi2(ip) = abs_psi2(ip) + real(conjg(zpsi(ip, 2)) * zpsi(ip, 2), real64)
1025 if (st%d%dim > 1)
then
1031 select case (this%method)
1032 case (option__dosmethod__smear)
1033 do ie = 1, this%ldos_nenergies
1034 weight = ldos_weights(ie, ik, 1)
1035 call lalg_axpy(gr%np, weight, abs_psi2, ldos(:, ie, is))
1037 case (option__dosmethod__tetrahedra, option__dosmethod__tetrahedra_opt)
1038 ikpoint = st%d%get_kpoint_index(ik)
1043 do ie = 1, this%ldos_nenergies
1044 weight = ldos_weights(ie, ik, iiop)
1045 call lalg_axpy(gr%np, weight, abs_psi2_symm, ldos(:, ie, is))
1054 safe_deallocate_a(ldos_weights)
1055 safe_deallocate_a(dpsi)
1056 safe_deallocate_a(zpsi)
1057 safe_deallocate_a(abs_psi2)
1058 safe_deallocate_a(abs_psi2_symm)
1060 if (st%parallel_in_states .or. st%d%kpt%parallel)
then
1065 do ie = 1, this%ldos_nenergies
1066 write(name,
'(a,i5.5)')
'ldos_en-', ie
1069 if (hm%kpoints%use_symmetries .and. &
1070 .not. (this%method == option__dosmethod__tetrahedra .or. this%method == option__dosmethod__tetrahedra_opt))
then
1074 ldos(:, ie, is), fn_unit, ierr, pos=ions%pos, atoms=ions%atom, grp = st%dom_st_kpt_mpi_grp)
1078 safe_deallocate_a(ldos)
constant times a vector plus a vector
pure logical function, public accel_is_enabled()
integer, parameter, public accel_mem_read_only
subroutine, public zget_atomic_orbital(namespace, space, latt, pos, species, mesh, sm, ii, ll, jj, os, orbind, radius, d_dim, use_mesh, normalize, index_shift)
This routine returns the atomic orbital basis – provided by the pseudopotential structure in geo.
character(len=1), dimension(0:3), parameter, public l_notation
real(real64) function, public atomic_orbital_get_radius(species, mesh, iorb, ispin, truncation, threshold)
subroutine, public dget_atomic_orbital(namespace, space, latt, pos, species, mesh, sm, ii, ll, jj, os, orbind, radius, d_dim, use_mesh, normalize, index_shift)
This routine returns the atomic orbital basis – provided by the pseudopotential structure in geo.
Module that handles computing and output of various density of states.
subroutine, public dos_write_pdos(this, dir, st, box, ions, mesh, hm, namespace)
Computes and output the projected DOS (PDOS)
subroutine dos_end(this)
Finalizer for the dos_t object.
subroutine, public dos_write_dos(this, dir, st, box, ions, mesh, hm, namespace)
Computes and output the DOS and the projected DOS (PDOS)
subroutine, public dos_write_jdos(this, dir, st, ions, hm, namespace)
Computes and output the joint DOS (JDOS)
subroutine, public dos_init(this, namespace, st, kpoints)
Initializes the dot_t object.
subroutine, public dos_write_ldos(this, dir, st, ions, gr, hm, how, namespace)
Computes and output the local DOS (LDOS)
integer, parameter, public spin_polarized
real(real64), parameter, public m_zero
real(real64), parameter, public m_four
real(real64), parameter, public m_epsilon
real(real64), parameter, public m_one
This module implements the underlying real-space grid.
subroutine, public dgrid_symmetrize_single(gr, iop, field, symm_field)
subroutine, public dgrid_symmetrize_scalar_field(gr, field, suppress_warning)
subroutine, public dio_function_output(how, dir, fname, namespace, space, mesh, ff, unit, ierr, pos, atoms, grp, root)
Top-level IO routine for functions defined on the mesh.
subroutine, public io_close(iunit, grp)
integer function, public io_open(file, namespace, action, status, form, position, die, recl, grp)
integer pure function, public kpoints_get_num_symmetry_ops(this, ik)
integer pure function, public kpoints_get_symmetry_ops(this, ik, index)
This module is intended to contain "only mathematical" functions and procedures.
integer pure function, public pad_pow2(size)
create array size, which is padded to powers of 2
This module defines the meshes, which are used in Octopus.
subroutine, public messages_obsolete_variable(namespace, name, rep)
character(len=256), dimension(max_lines), public message
to be output by fatal, warning
subroutine, public messages_fatal(no_lines, only_root_writes, namespace)
subroutine, public messages_info(no_lines, iunit, debug_only, stress, all_nodes, namespace)
type(namespace_t), public global_namespace
subroutine, public orbitalset_init(this)
subroutine, public orbitalset_end(this)
subroutine, public dorbitalset_transfer_to_device(os, kpt, use_mesh)
Allocate and transfer the orbitals to the device.
subroutine, public orbitalset_update_phase(os, dim, kpt, kpoints, spin_polarized, vec_pot, vec_pot_var, kpt_max)
Build the phase correction to the global phase in case the orbital crosses the border of the simulato...
subroutine, public dorbitalset_get_coeff_batch(os, ndim, psib, dot, reduce)
subroutine, public zorbitalset_get_coeff_batch(os, ndim, psib, dot, reduce)
subroutine, public zorbitalset_transfer_to_device(os, kpt, use_mesh)
Allocate and transfer the orbitals to the device.
integer function, public orbitalset_utils_count(species, iselect)
Count the number of orbital sets we have for a given atom.
this module contains the low-level part of the output system
character(len=max_path_len) function, public get_filename_with_spin(output, nspin, spin_index)
Returns the filame as output, or output-spX is spin polarized.
integer function, public parse_block(namespace, name, blk, check_varinfo_)
subroutine, public profiling_out(label)
Increment out counter and sum up difference between entry and exit time.
subroutine, public profiling_in(label, exclude)
Increment in counter and save entry time.
real(real64) function, public smear_delta_function(this, xx)
integer, parameter, public smear_lorentzian
pure logical function, public states_are_real(st)
type(type_t), parameter, public type_cmplx
brief This module defines the class unit_t which is used by the unit_systems_oct_m module.
character(len=20) pure function, public units_abbrev(this)
This module defines the unit system, used for input and output.
type(unit_system_t), public units_out
type(unit_system_t), public units_inp
the units systems for reading and writing
type(unit_t), public unit_one
some special units required for particular quantities
class to tell whether a point is inside or outside
Description of the grid, containing information on derivatives, stencil, and symmetries.
Describes mesh distribution to nodes.
The states_elec_t class contains all electronic wave functions.
batches of electronic states