Discrete convolution is a way to combine two finite sequences to produce a third sequence that shows how one sequence “filters” or modifies the other. In signal processing, this is called discrete-time convolution of sequences. If you think of one sequence as an input signal and the other as a filter or system response, their convolution gives the output signal.
On this page, the calculator performs the manual convolution steps for you. You enter two finite-length sequences (lists of numbers), and it returns their convolution sequence along with the numerical values for each index.
We will use standard bracket notation for sequences. Let:
a[n] be the first sequence (Sequence A).b[n] be the second sequence (Sequence B).y[n] be their convolution: y[n] = (a * b)[n].The discrete convolution of two sequences is defined by
In words: to compute y[n], you sum the products a[k] · b[n − k] over all indices k where both a[k] and b[n − k] are defined. Because the calculator treats your inputs as finite sequences that are zero outside their entered indices, the sum is effectively taken only over the overlapping part of the two sequences.
If Sequence A has length N and Sequence B has length M, the convolution result always has length
length(y) = N + M − 1.
The calculator is designed for quick, small-scale convolutions that you might otherwise do by hand. You can use it for digital signal processing homework, probability mass function convolutions, or checking manual calculations.
1, 2, 3.4, 5.y[n] with length N + M − 1 will appear below the form.Order matters: in general a * b and b * a are equal numerically for finite sequences, but in many applications (such as interpreting time indices, shifts, or causal systems) you will want to treat one sequence as the input and the other as the impulse response. Use the A and B fields consistently with how you interpret your problem.
The calculator expects inputs that follow these simple rules:
1, -2.5, 3).-1.5).y[n] therefore starts at n = 0 and ends at n = N + M − 2.Consider the example where
a[n] = [1, 2, 3] (Sequence A)b[n] = [4, 5] (Sequence B)Here, N = 3 and M = 2, so the result will have length 3 + 2 − 1 = 4. We compute y[n] = (a * b)[n] for n = 0, 1, 2, 3:
a[0] and b[0] overlap.
y[0] = a[0] · b[0] = 1 · 4 = 4a[0], a[1] and b[1], b[0].
y[1] = a[0] · b[1] + a[1] · b[0] = 1 · 5 + 2 · 4 = 5 + 8 = 13a[1], a[2] and b[1], b[0].
y[2] = a[1] · b[1] + a[2] · b[0] = 2 · 5 + 3 · 4 = 10 + 12 = 22a[2] and b[1] overlap.
y[3] = a[2] · b[1] = 3 · 5 = 15The final convolution result is
y[n] = [4, 13, 22, 15].
This is exactly what the calculator will display if you enter 1, 2, 3 for Sequence A and 4, 5 for Sequence B.
Discrete convolution appears in many areas. Here are two of the most common ways you might use this calculator.
In DSP, convolution models the response of a linear time-invariant (LTI) system to an input signal:
a[n] is a finite-length input signal or sequence.b[n] is the system’s impulse response (filter coefficients).y[n] is the system output.For example, a simple three-point moving average filter has impulse response b[n] = [1/3, 1/3, 1/3]. Convolving this with a noisy signal smooths sudden variations.
In probability, convolution combines probability mass functions (PMFs). If a[n] and b[n] are PMFs of independent discrete random variables, their convolution gives the PMF of their sum. For instance, you can represent the distribution of two dice, coins, or other discrete outcomes as sequences and use the calculator to obtain the distribution of the sum.
| Aspect | Signal Processing View | Probability View |
|---|---|---|
| Sequences | a[n] is an input signal, b[n] is an impulse response or filter. |
a[n] and b[n] are probability mass functions (PMFs). |
Interpretation of y[n] |
Output signal of an LTI system at time index n. |
Probability that the sum of two random variables equals value corresponding to index n. |
| Typical values | Any real numbers, including negatives and decimals. | Non-negative numbers that sum to 1 (if normalized PMFs are used). |
| What convolution models | How a system filters or shapes an input sequence. | How independent random variables add together. |
| When to use this calculator | To check hand calculations for small FIR filters or study discrete-time convolution of sequences. | To compute distributions of sums for small discrete random variables. |
This tool focuses on clarity and educational use, and it makes several assumptions:
Within these assumptions, the calculator gives reliable results for manual convolution steps, homework checks, and small exploratory problems.
Discrete convolution works with sequences indexed by integers (for example, n = 0, 1, 2, ...) and uses sums. Continuous convolution works with functions of a real variable (for example, t) and uses integrals instead of sums. The calculator on this page handles only discrete convolution of finite-length sequences.
If Sequence A has length N and Sequence B has length M, the convolution result has length N + M − 1. The first element corresponds to index n = 0, and the last element corresponds to n = N + M − 2.
The internal indexing starts at 0 for the first value you enter. To represent shifts or negative indices, you can insert leading zeros. For example, to model a sequence that is zero up to index 3 and then equals 1, you could enter 0, 0, 0, 1. This approach lets you mimic time shifts even though the displayed indices start at 0.
Use this calculator when you need fast, accurate discrete-time convolution of finite-length signals or sequences without doing every manual step yourself. It is helpful for learning, checking homework, designing or analyzing small filters, and exploring the convolution of discrete probability distributions.