SciPy
LaplacianNd.toarray
Converts the Laplacian data to a dense array.
The shape is (N, N) where N = np.prod(grid_shape).
(N, N)
N = np.prod(grid_shape)