forms the convolution of the kernel ker with list.


forms the cyclic convolution in which the k^(th) element of ker is aligned with each element in list.


forms the cyclic convolution whose first element contains list[[1]]ker[[kL]] and whose last element contains list[[-1]]ker[[kR]].


forms the convolution in which list is padded at each end with repetitions of the element p.


forms the convolution in which list is padded at each end with cyclic repetitions of the pi.


forms a generalized convolution in which g is used in place of Times and h in place of Plus.


forms a convolution using elements at level lev in ker and list.


  • With kernel Kr and list as, ListConvolve[ker,list] computes , where the limits of the sum are such that the kernel never overhangs either end of the list.
  • ListConvolve[ker,list] gives a result of length Length[list]-Length[ker]+1.
  • ListConvolve[ker,list] allows no overhangs and is equivalent to ListConvolve[ker,list,{-1,1}].
  • ListConvolve[ker,list,k] is equivalent to ListConvolve[ker,list,{k,k}].
  • The values of kL and kR in ListConvolve[ker,list,{kL,kR}] determine the amount of overhang to allow at each end of list.
  • Common settings for {kL,kR} are:
  • {-1,1}no overhangs (default)
    {-1,-1}maximal overhang at the righthand end
    {1,1}maximal overhang at the lefthand end
    {1,-1}maximal overhangs at both beginning and end
  • With maximal overhang at one end only, the result from ListConvolve is the same length as list.
  • ListConvolve[ker,list,{kL,kR},padlist] effectively lays down repeated copies of padlist, then superimposes one copy of list on them and forms a convolution of the result.
  • Common settings for padlist are:
  • ppad with repetitions of a single element
    {p1,p2,}pad with cyclic repetitions of a sequence of elements
    listpad by treating list as cyclic (default)
    {}do no padding
  • ListConvolve works with multidimensional kernels and lists of data.
  • ListConvolve[ker,list,{{kL 1,kL 2,},{kR 1,kR 2,}}] forms the cyclic convolution whose {1,1,} element contains ker[[kL 1,kL 2,]]list[[1,1,]], and whose {-1,-1,} element contains ker[[kR 1,kR 2,]]list[[-1,-1,]].
  • {kL,kR} is taken to be equivalent to {{kL,kL,},{kR,kR,}}.
  • When a function h is specified to use in place of Plus, explicit nested h expressions are generated with a depth equal to the depth of ker.
  • ListConvolve works with exact numbers and symbolic data as well as approximate numbers.


open all close all

Basic Examples  (4)

Convolve a kernel {x,y} with a list of data:

Click for copyable input

Make a cyclic convolution the same length as the original data:

Click for copyable input

Align element 2 in the kernel with successive elements in the data:

Click for copyable input

Pad with zzz instead of using the data cyclically:

Click for copyable input

Two-dimensional convolution:

Click for copyable input

Scope  (9)

Generalizations & Extensions  (4)

Applications  (9)

Properties & Relations  (7)

Possible Issues  (1)

Introduced in 1999