is_in_initiator_space Function

public function is_in_initiator_space(ilut, nI) result(initiator_state)

Uses

Arguments

Type IntentOptional Attributes Name
integer(kind=n_int), intent(in) :: ilut(0:NIfTot)
integer, intent(in) :: nI(:)

Return Value logical


Contents

Source Code


Source Code

    function is_in_initiator_space(ilut, nI) result(initiator_state)

        use hash, only: FindWalkerHash

        integer(n_int), intent(in) :: ilut(0:NIfTot)

        integer, intent(in) :: nI(:)
        integer(int64) :: hash_val, pos

        logical :: initiator_state

        hash_val = FindWalkerHash(nI, initiator_space_size_int)

        call initiator_ht%callback_lookup(hash_val, pos, initiator_state, loc_verify)

    contains

        function loc_verify(ind) result(match)
            integer(int64), intent(in) :: ind
            logical :: match
            match = (all(ilut(0:nifd) == initiator_space(0:nifd, ind)))
        end function loc_verify

    end function is_in_initiator_space