Template Function Pennylane::Util::kronProd¶
Defined in File Util.hpp
Function Documentation¶
-
template<typename T>
auto Pennylane::Util::kronProd(const std::vector<T> &diagA, const std::vector<T> &diagB) -> std::vector<T>¶ Kronecker product of two diagonal matrices. Only diagonal elements are stored.
- Template Parameters
T – Data type.
- Parameters
diagA – A vector containing the values of a diagonal matrix.
diagB – A vector containing the values of a diagonal matrix.
- Returns
kronAB A vector containing the diagonal values of the Kronecker product.
api/function_Util_8hpp_1ad3440e74967fb3b191dbbd2eb95af1b6
Download Python script
Download Notebook
View on GitHub