MATLAB Function Reference    

Kronecker tensor product



K = kron(X,Y) returns the Kronecker tensor product of X and Y. The result is a large array formed by taking all possible products between the elements of X and those of Y. If X is m-by-n and Y is p-by-q, then kron(X,Y) is m*p-by-n*q.


If X is 2-by-3, then kron(X,Y) is

The matrix representation of the discrete Laplacian operator on a two-dimensional, n-by-n grid is a n^2-by-n^2 sparse matrix. There are at most five nonzero elements in each row or column. The matrix can be generated as the Kronecker product of one-dimensional difference operators with these statements:

Plotting this with the spy function for n = 5 yields:

  keyboard lasterr