C = CIRCONV(A,B,N) performs the N-point circular convolution of vectors A and B. C is returned as a row vector. A and B must be vectors, but may be of different lengths. N must be a positive, non-zero integer. The results of CIRCONV will match that of CONV if N>=( length(A) + length(B) - 1). This is also the alias-free criterion for the circular convolution.

Z = [ 2 -1 0 -3; -3 2 -1 0; 0 -3 2 -1; -1 0 -3 2]
B = [ 1 -3-2*i 4 -3+2*i].' with N =4

it doesnt work?

16 Sep 2008

Piyush Tarey

helped me...in lab..hehe

16 Sep 2008

Pradeep Purohit

15 Jan 2008

Ory Eger

Works perfectly! Very useful.

27 Nov 2007

a singer

you can do this directly using:
y=ifft(fft(a,n).*fft(b,n),n);
in exactly one line.

01 Oct 2007

saurabh jain

Thanx man

14 Aug 2007

mohd rafi ramli

that is good

15 Nov 2006

luis farinha

Very impoortante for me this script.

31 Aug 2005

Anand Rangarajan

It is handy.

06 Apr 2005

prabin gautam

very needed one

22 Mar 2004

Milos Komarcevic

A very handy function, but I believe the ctranspose ' needs to be changed to transpose .' throughout, otherwise you don't get what you expect when convolving complex vectors.

04 Dec 2003

tom tom

Good job
Wont have to do my homework :)

04 Dec 2002

Andrew Singer

Why not just multiple the DFT's of the time-aliased signals? It would be MUCH faster...

function xo = talias(x,N)
%% function xo=talias(x,N)
%% time alias data vector x to length N for an N-point DFT.
l=length(x);
nrows=ceil(l/N);
x=[x(:)' zeros(1,N*nrows-l)];
xo = sum( reshape(x,N,nrows)' );