3

I've got a special problem with writing in math mode. In general there is absolutely no problem with, e.g., writing something like

$x+x+x++x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x+x$

will produce the required line break, whereas something like

The subset $\Xi\subseteq C^{1,\alpha\times C^{0,\alpha}$ is closed with
respect to the $C^{1,\beta}\times C^{0,\beta}$-Topology

will write the part C^{0,\beta}$-Topology of the text over the end of the line. Here it's important, that this part stands close to the end of a line. In addition, I have to mention, that an \mbox{} command will occur writing further along the end of the line.

So is there someone who knows that problem, respectively how to solve it? It's important because a manual line break yields a white space at the end of the line and this is strongly undesired.

10
  • Does ${C^{1,\beta}\times C^{0,\beta}}$\penalty10000 -\hskip0pt Topology produce better line breaking? Jul 31, 2016 at 12:47
  • With a long piece of mathematics that has no natural line break there is no automated solution. You could display the formula in an equation* environment, or reword the surrounding text so that the characters come in the middle of a line. Jul 31, 2016 at 12:48
  • 1
    - disables line break in words that contain them, but you can manually add discretionary hyphens with \-, for instance $C^{1,\beta}\times C^{0,\beta}$-Topol\-ogy.
    – Manuel
    Jul 31, 2016 at 13:03
  • Dividing the word is similarly undesired. E.g., there is a situation in my text, where the "C" of $C^[1,\bet...$ marks the last sign of the line, so for TeX it should be easy to take it in the new line and rearrange the previous part of the text to fill the whole line. The fact, that this only happens when \times is uses stresses, that there should be a workaround.
    – MeLoco
    Jul 31, 2016 at 15:46
  • you can force a line break without leaving the line short with \newline (\linebreak and \\ leave the line short) Jul 31, 2016 at 16:47

1 Answer 1

2

The question is not clear but I assume that you get the 4th case, with the linebreak after \times

enter image description here

You can use \nobreak with the mathematics to stop the break there, if the break before -topology is not wanted you can force a linebreak with \linbreak (rather than \\) this does not leave the line short but instead over-stretches the line but is I think the output that you want here.

\documentclass{article}

\begin{document}

\noindent X\dotfill X

The subset $\Xi\subseteq C^{1,\alpha}\times C^{0,\alpha}$ is closed with
respect to the $C^{1,\beta}\times C^{0,\beta}$-Topology


xxThe subset $\Xi\subseteq C^{1,\alpha}\times C^{0,\alpha}$ is closed with
respect to the $C^{1,\beta}\times C^{0,\beta}$-Topology

xxxxxThe subset $\Xi\subseteq C^{1,\alpha}\times C^{0,\alpha}$ is closed with
respect to the $C^{1,\beta}\times C^{0,\beta}$-Topology

xxxxxxxxThe subset $\Xi\subseteq C^{1,\alpha}\times C^{0,\alpha}$ is closed with
respect to the $C^{1,\beta}\times C^{0,\beta}$-Topology


xxxxxxxxThe subset $\Xi\subseteq C^{1,\alpha}\times C^{0,\alpha}$ is closed with
respect to the $C^{1,\beta}\times\nobreak C^{0,\beta}$-Topology


xxxxxxxxThe subset $\Xi\subseteq C^{1,\alpha}\times C^{0,\alpha}$ is closed with
respect to the\linebreak $C^{1,\beta}\times  C^{0,\beta}$-Topology
\end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.