MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

serious flaw in KroneckerProduct with SparseArrays?


It appears KroneckerProduct doesn't work properly with SparseArrays which have a nonzero constant. Below, the end result should be "True":

In[349]:= a=SparseArray[{1->0},{2},1]
b=Normal[a];
u=KroneckerProduct[a,a]//Normal
v=KroneckerProduct[b,b]
u==v
Out[349]= SparseArray[<1>,{2},1]
Out[351]= {{0,1},{1,1}}
Out[352]= {{0,0},{0,1}}
Out[353]= False


  • Prev by Date: Extrema of 2D Interpolating function
  • Next by Date: Re: Colors in Histogram
  • Previous by thread: Re: Extrema of 2D Interpolating function
  • Next by thread: Real and Complex Roots on Same Plot