SymGenExcitIt_SetupSingle Subroutine

subroutine SymGenExcitIt_SetupSingle(iSpn, iFrom, iTo, iExcit, ExcitTypes, Classes, SymProdInd, I, J, K, L, nI, nEl, iMinElec1, tDebugPrint)

Arguments

Type IntentOptional Attributes Name
integer :: iSpn
integer :: iFrom
integer :: iTo
integer :: iExcit
integer :: ExcitTypes(5,*)
type(SymClass) :: Classes(*)
integer :: SymProdInd(2,3,1:*)
integer :: I
integer :: J
integer :: K
integer :: L
integer :: nI(nEl)
integer :: nEl
integer :: iMinElec1
logical :: tDebugPrint

Contents


Source Code

Subroutine SymGenExcitIt_SetupSingle(iSpn, iFrom, iTo, iExcit, ExcitTypes, Classes, SymProdInd, I, J, K, L, nI, nEl, iMinElec1, tDebugPrint)
    use SystemData, only: TSTOREASEXCITATIONS
    use SystemData, only: Symmetry, SymmetrySize, SymmetrySizeB
    use SystemData, only: BasisFN, BasisFNSize, BasisFNSizeB
    use SymData, only: SymLabelCounts, SymStatePairs, SymClass
    use SymData, only: SymLabelList, SymPairProds
    use constants, only: stdout
    IMPLICIT NONE
    INTEGER nEl, nI(nEl)
    INTEGER ExcitTypes(5, *)

    INTEGER I, J, K, L
    TYPE(SymClass) Classes(*)
    INTEGER iExcit
    INTEGER iFrom, iTo, iSpn

    INTEGER SymProdInd(2, 3, 1:*)
    LOGICAL tDebugPrint
    INTEGER iMinElec1

!.. a single
    ISPN = EXCITTYPES(2, IEXCIT) - 2
    IFROM = CLASSES(EXCITTYPES(3, IEXCIT))%SymLab
    ITO = EXCITTYPES(4, IEXCIT)
    L = 0
    K = SYMLABELCOUNTS(2, ITO)
!  J will run along symblabels
    J = 0
!  I will run along the determinant
    I = 0
!  Take into account the we may only be doing a subset of the electrons
    DO WHILE (I < NEL)
        IF (NI(I + 1) >= iMinElec1) EXIT
        I = I + 1
    END DO
!  I now is the index of the first electron allowed in our subset
    IF (tDebugPrint) WRITE(stdout, *) "EXC", IEXCIT, ISPN, IFROM, ITO, SYMPRODIND(2, ISPN, IFROM)
End Subroutine SymGenExcitIt_SetupSingle