Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: convolution on sparse matrix?
Replies: 0  

Advanced Search

Back to Topic List Back to Topic List  
Bruno Luong

Posts: 8,761
Registered: 7/26/08
convolution on sparse matrix?
Posted: Apr 7, 2013 7:37 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Where it is specified that the convolution of sparse matrices is not allowed?

>> conv([1 2 3],[4 5])

ans =

4 13 22 15

>> conv(sparse([1 2 3]),[4 5])
Undefined function 'conv2' for input arguments of type 'double' and attributes 'sparse col real'.

Error in conv (line 39)
c = conv2(a(:),b(:),shape);

Strange thing is this works just fine:

>> convmtx(sparse([1 2 3]), 2)

ans =

(1,1) 1
(1,2) 2
(2,2) 1
(1,3) 3
(2,3) 2
(2,4) 3

Similar question might be asked for FFT, ...

Bruno



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2014. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Drexel University School of Education.