# Full-line kerning in LaTeX math mode

I have a certain mathematical formula that is long enough that LaTeX breaks it into two lines, with a mere two characters wrapping to the second line. I would like to force LaTeX to display this as a single line of standard width, by condensing (negative kerning) all spaces uniformly. Enclosing the whole formula in {} is not the desired solution; this typesets as a single over-width line, rather than a line condensed to fit properly. Is there any method that will work?

In response to David Carlisle's comment, the context is indeed inline math, but as an \item in an itemize environment, so the inline math constitutes a full line of text by itself. Notably, this means that if you force the overfull hbox typesetting using {}, the formula becomes a new line below the itemize bullet, whereas I want it to fit in the space to the right of the bullet.

• Welcome to TeX.SX! Did you try adding \usepackage{microtype}? – egreg Oct 21 '18 at 21:10
• you don't give any example which makes it hard to answer. It appears that you are using inline math? normally such a large expression would be set as display mat (which may already be enough to make it less wide) – David Carlisle Oct 21 '18 at 21:30
• you can reduce \thicmuskip and \medmuskip to reduce math space, but without any example code hard to give any specific advice – David Carlisle Oct 21 '18 at 22:34
• Is there a convenient way to implement reductions in \thicmuskip and \medmuskip to apply to just one math environment rather than the whole document? – Joseph Lurie Oct 22 '18 at 0:35
• they are local settings so any normal tex grouping will restrict the scope. {...} or \begin{something}...\end{something} or if grouping isn't appropriate just set them before the equation and set them back afterwards – David Carlisle Oct 22 '18 at 10:52

No test file was provided. but this shows a couple of possibilities.

\documentclass{article}

\def\tst{\sum_0^\infty x^i = 1 + x + x^2 + x^3  + x^4 + \cdots   = \sum_0^\infty x^i = 1 + x + x^2 + x^3 + x^4 + \cdots   = z}
\begin{document}

\begin{itemize}
\item X\dotfill X
\item $\tst$   % wraps
\item ${\tst}$ % overfull
\item $\displaystyle \tst$ % fits
$\tst$  % fits