What the Convolution Calculator Does
This Convolution Calculator computes the discrete convolution of two finite sequences of numbers. Convolution is a core operation in signal processing, image filtering, probability, and polynomial multiplication. Instead of working through the sums by hand, you enter two sequences and the tool instantly returns the combined output sequence.
How to Use It
There are just two input fields:
- First Sequence — your input signal or first set of numbers, entered as comma-separated values (for example
1, 2, 3). - Second Sequence — your second signal, kernel, or filter, also comma-separated (for example
0, 1, 0.5).
Decimals and negative numbers are accepted. The calculator splits each entry on commas, trims spaces, and converts each item to a number before computing the result.
The Formula Explained
Discrete convolution is defined as:
$$(\text{Seq}_1 * \text{Seq}_2)[i] = \sum_{j=\max(0,\,i-m+1)}^{\min(i,\,n-1)} \text{Seq}_1[j]\cdot \text{Seq}_2[i-j]$$
For two finite sequences of length n and m, the result has exactly n + m − 1 values. Each output value \(y[i]\) is the sum of all products \(x[j] \cdot h[i - j]\) where the indices stay within both sequences. In plain terms, the tool slides one sequence across the other, multiplies overlapping terms, and adds them up at each shift.
Worked Example
Let First Sequence = 1, 2, 3 and Second Sequence = 0, 1, 0.5. Here n = 3 and m = 3, so the result has 3 + 3 − 1 = 5 values:
- \(y[0] = 1\cdot 0 = 0\)
- \(y[1] = 1\cdot 1 + 2\cdot 0 = 1\)
- \(y[2] = 1\cdot 0.5 + 2\cdot 1 + 3\cdot 0 = 2.5\)
- \(y[3] = 2\cdot 0.5 + 3\cdot 1 = 4\)
- \(y[4] = 3\cdot 0.5 = 1.5\)
So the output is 0, 1, 2.5, 4, 1.5.
Frequently Asked Questions
How long is the output sequence? Always the length of the first sequence plus the length of the second sequence minus one (n + m − 1).
Does the order of the two sequences matter? No. Convolution is commutative, so swapping the two inputs gives the same result sequence.
Can I use it for polynomial multiplication? Yes. If you treat each sequence as the coefficients of a polynomial, the convolution output is the coefficients of their product — a handy shortcut for algebra as well as signals.