# How to write a convolution and a Fourier transform

I want to write the following equation in LaTeX:

$$x(t) \ast h(t) = y(t) X(f) H(f) = Y(f)$$


I want \ast to denote the convolution. I know there is also the \star command. Does it matter which one I use to represent convolution? Then I want a Fourier-transform symbol, I mean the line with a coloured and an empty circle on either side, to connect the x(t) and X(f), h(t) and H(f), y(t) and Y(f) respectively. Is there a way of doing this ?

• Don't know about the symbols (but you can look them up). I suggest you use the align or align* environment for display formulae with horizontal alignment. The amsmath package provides the environment.
– user10274
Jan 31, 2017 at 18:35
• \ast and \star are quite different symbols. You can just use * for \ast, but I've never seen \star for a convolution. Can you point to some reference for the Fourier transform symbol you mention? Jan 31, 2017 at 18:37

The \circledast symbol from amssymb package is usually used to denote the circular convolution process.

\documentclass{article}
\usepackage{amsmath}
\usepackage{amssymb}
\begin{document}

\begin{align*}
x(t) \circledast h(t) &= y(t) \\
X(f) H(f) &= Y(f)
\end{align*}

\end{document}


For linear convolution, a simple * is more appropriate:

\begin{align*}
x(t)*h(t) &= y(t) \\
X(f) H(f) &= Y(f)
\end{align*}


To draw connections between parts of the equations, TikZ package can be used with its tikzmark library to mark locations to begin and end your lines.

\documentclass{article}
\usepackage{amsmath,amssymb,tikz}
\usetikzlibrary{arrows.meta,tikzmark}
\begin{document}

\begin{align*}
x\tikzmark{x}(t)*h\tikzmark{h}(t) &= y\tikzmark{y}(t) \\[2em]
X(f) \, H(f) &= Y(f)
\end{align*}

\begin{tikzpicture}[overlay,remember picture, > = {Circle[open,blue]}]
\draw [<->] ([yshift=-.7ex]pic cs:x) -- ++(0,-2.2em);
\draw [<->] ([yshift=-.7ex]pic cs:h) -- ++(0,-2.2em);
\draw [<->] ([yshift=-.7ex]pic cs:y) -- ++(0,-2.2em);
\end{tikzpicture}

\end{document}


• i never see this symbol for convolution (my professional life was very tied with use of convolutions ...). where you find it? Jan 31, 2017 at 19:14
• I specifically used the symbol for circular convolution, may be I'll switch back to the linear one Jan 31, 2017 at 19:18
• ok, thank you so much! - I have a couple of questions though: I am not in "math-mode" without , right? Does this somehow influence the layout of the equation? I mean, do the variables look different from variables used in ? Then, can you explain to me, why you are using a * in {align*} and what the & in front of the "=" sign does?
– user123551
Jan 31, 2017 at 19:44
• @Luk - Sure! variables in math-mode will differ from those in text mode, the former is the proper choice. The * in {align*} is to suppress numbering of lines and the & before = is to align the two = signs horizontally in both lines. Jan 31, 2017 at 19:54
• @Luk - I edited to include the connecting lines, I'm not sure, though, about the precise shape you need for the lines. But, the idea will remain the same, regardless of the shape you need. Jan 31, 2017 at 20:00

I just want to add that there is an easier way to get the symbol between the fourier transform pairs by using the trfsigns package.

\usepackage{trfsigns}
$g(x_1,x_2)* h(x_1,x_2)\laplace G(\omega_1,\omega_2)\cdot H(\omega_1,\omega_2)$