# Example in which $$…$$ gets wrong spacing

The use of $...$ vs. $$...$$ is discussed in Why is $...$ preferable to $$...$$? and What are the differences between , , align, equation and displaymath?. It seems like \[... has benefits in some uncommon uses cases (leqno and \qedhere), but the main reason to use it is, according to most answerers, spacing issues. However, in the answers I only see examples of how $...$ leads to worse spacing without amsmath. Could someone provide a minimal example of an incorrect spacing produced by ...$$, which is fixed by switching to $...$ and amsmath? If you wish, you can start by modifying the following M(non-)WE (which, as it is, shows no difference between the two variants, at least on my machine with Texlive 2015). The rules are \smashed, so they should take up no space, and they are there only to show that the spacing above and below the equation is exactly the same (idea taken from jfbu's answers to the two above-cited questions). \documentclass{article} \usepackage{amsmath} \begin{document} Wrong spacing:\hrulefill\par$$
\vartheta=2\pi\smash{\rule[-4ex]{.4pt}{9.5ex}}