calcB_vector_int Function

public pure function calcB_vector_int(ilut) result(bVector)

Arguments

Type IntentOptional Attributes Name
integer(kind=n_int), intent(in) :: ilut(0:GugaBits%len_orb)

Return Value integer, (nSpatOrbs)


Contents

Source Code


Source Code

    pure function calcB_vector_int(ilut) result(bVector)
        ! function to calculate the bvector in integer form
        integer(n_int), intent(in) :: ilut(0:GugaBits%len_orb)
        integer :: bVector(nSpatOrbs)

        integer :: i, bValue

        bVector = 0
        bValue = 0

        do i = 1, nSpatOrbs

            if (isOne(ilut, i)) then
                bValue = bValue + 1

            else if (isTwo(ilut, i)) then
                bValue = bValue - 1

            end if

            bVector(i) = bValue

        end do

    end function calcB_vector_int