Circular convolution with single element array showing error

6 vues (au cours des 30 derniers jours)
Deepa Abraham
Deepa Abraham le 22 Jan 2019
Commenté : Deepa Abraham le 22 Jan 2019
Hi ,
When I try to do circular convolution of two vectors,it shows error when one of the vectors is single element.
How do I rectify the problem? The error message is shown below:
>> s=[1];
>> q=[1 2];
>> res=cconv(s,q)
Error
Error using .* Matrix dimensions must agree.
Error in cconv (line 46)
c = ifft(fft(datawrap(a,N),N).*fft(datawrap(b,N),N));
  4 commentaires
KSSV
KSSV le 22 Jan 2019
Try transposing ...
Deepa Abraham
Deepa Abraham le 22 Jan 2019
Yes,
Thanks, Now no issues

Connectez-vous pour commenter.

Réponses (0)

Catégories

En savoir plus sur Data Distribution Plots dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by