# NOT RUN {
a <- c(1, 2, -1, 1)
b <- c(1, 1, 2, 1, 2, 2, 1, 1)
c <- cconv(a, b) # Circular convolution
cref = conv(a, b) # Linear convolution
all.equal(max(c - cref), 0)
cconv(a, b, 6)
# }
Run the code above in your browser using DataLab