encode_excit_info_vec Function

private pure function encode_excit_info_vec(typ, inds) result(excit_info_int)

Arguments

Type IntentOptional Attributes Name
type(ExcitationType_t), intent(in) :: typ
integer, intent(in) :: inds(4)

Return Value integer(kind=int64)


Source Code

    pure function encode_excit_info_vec(typ, inds) result(excit_info_int)
        ! function to encode the minimal information of an excit-info
        ! object into a single 64bit integer. used in the PCHB excitation
        ! generation.
        debug_function_name("encode_excit_info_vec")
        type(ExcitationType_t), intent(in) :: typ
        integer, intent(in) :: inds(4)
        integer(int64) :: excit_info_int

#ifdef DEBUG_
        if (typ%val .notin. non_trivial_double_excit_type_arr%val) then
            call stop_all(this_routine, "incorrect typ: "//typ%str)
        end if
#endif

        ASSERT(all(inds > 0) .and. all(inds <= nSpatOrbs))

        excit_info_int = 0_int64

        call encode_excit_info_type(excit_info_int, typ)
        call encode_excit_info_indices(excit_info_int, inds)

    end function encode_excit_info_vec