guga_matel Function

public function guga_matel(nI, nJ) result(matel)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: nI(nel)
integer, intent(in) :: nJ(nel)

Return Value real(kind=dp)


Contents

Source Code


Source Code

    function guga_matel(nI, nJ) result(matel)
        integer, intent(in) :: nI(nel), nJ(nel)
        HElement_t(dp) :: matel
        integer(n_int) :: ilutI(0:NIfTot), ilutJ(0:NIfTot)
        type(ExcitationInformation_t) :: excitInfo

        if(all(nI == nJ)) then
            matel = calcDiagMatEleGuga_nI(nI)
        else
            call EncodeBitDet(nI, ilutI)
            call EncodeBitDet(nJ, ilutJ)
            call calc_guga_matrix_element(&
                ilutI, CSF_Info_t(ilutI), ilutJ, CSF_Info_t(ilutJ), &
                excitInfo, matel, .true.)
        end if

    end function guga_matel