// This file is part of libigl, a simple c++ geometry processing library. // // Copyright (C) 2014 Daniele Panozzo // // This Source Code Form is subject to the terms of the Mozilla Public License // v. 2.0. If a copy of the MPL was not distributed with this file, You can // obtain one at http://mozilla.org/MPL/2.0/. #ifndef IGL_KRONECKERPRODUCT_H #define IGL_KRONECKERPRODUCT_H #include "igl_inline.h" #include #include namespace igl { // Computes the Kronecker product between sparse matrices A and B. // // Inputs: // A #M by #N sparse matrix // B #P by #Q sparse matrix // Returns #M*#P by #N*#Q sparse matrix // template IGL_INLINE Eigen::SparseMatrix kronecker_product( const Eigen::SparseMatrix & A, const Eigen::SparseMatrix & B); } #ifdef IGL_HEADER_ONLY # include "kronecker_product.cpp" #endif #endif