sltcnd_2_kernel Function

public function sltcnd_2_kernel(exc) result(hel)

Arguments

Type IntentOptional Attributes Name
type(Excite_2_t), intent(in) :: exc

Return Value real(kind=dp)


Contents

Source Code


Source Code

    function sltcnd_2_kernel(exc) result(hel)
        type(Excite_2_t), intent(in) :: exc
        HElement_t(dp) :: hel
        integer :: id(2, 2), ex(2, 2)
        ! Obtain spatial rather than spin indices if required
        ex = exc%val
        id = gtID(ex)

        if (tReltvy .or. ((G1(ex(1, 1))%Ms == G1(ex(2, 1))%Ms) .and. &
                          (G1(ex(1, 2))%Ms == G1(ex(2, 2))%Ms))) then
            hel = get_umat_el(id(1, 1), id(1, 2), id(2, 1), id(2, 2))
        else
            hel = (0)
        end if
        if (tReltvy .or. ((G1(ex(1, 1))%Ms == G1(ex(2, 2))%Ms) .and. &
                          (G1(ex(1, 2))%Ms == G1(Ex(2, 1))%Ms))) then
            hel = hel - get_umat_el(id(1, 1), id(1, 2), id(2, 2), id(2, 1))
        end if
    end function sltcnd_2_kernel