Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Underfull \hbox (badness 10000) warning

669 views
Skip to first unread message

Anuj

unread,
Nov 30, 2002, 10:50:08 PM11/30/02
to
The code compiles and the document looks great though I get the message 1
bad box(es) on the following code:

\begin{equation}
P(\mathbf{D} \leq q) \geq \frac{c_u}{c_o+c_u}
\end{equation}

Sorry for the elementary questions. Just trying to slowly pick up this
fascinating piece of software.

Thanks in advance.

David Kastrup

unread,
Nov 30, 2002, 10:48:20 PM11/30/02
to
"Anuj" <fri...@internet.com> writes:

> The code compiles and the document looks great though I get the message 1
> bad box(es) on the following code:
>
> \begin{equation}
> P(\mathbf{D} \leq q) \geq \frac{c_u}{c_o+c_u}
> \end{equation}

No, you don't. The above does not produce this message. A typical
culprit, however, would be the attempt to end lines in paragraph mode
with \\, probably the most misunderstood control sequence of LaTeX
altogether.

--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
UKTUG FAQ: <URL:http://www.tex.ac.uk/cgi-bin/texfaq2html>

Anuj

unread,
Dec 1, 2002, 12:37:48 AM12/1/02
to
Thanks, David. But what exactly does that mean? I'm starting a new paragraph
with \\. I know that \\ produces a newline but I wanted to flush left the
new paragraph and I thought this would be a quick and dirty solution.

"David Kastrup" <David....@t-online.de> wrote in message
news:x5y97ap...@lola.goethe.zz...

David Kastrup

unread,
Dec 1, 2002, 12:58:29 AM12/1/02
to

Please don't toppost above an unedited fullquote. It makes it hard
to follow the conversation and is impolite to readers. I have
rearranged.

"Anuj" <fri...@internet.com> writes:

> "David Kastrup" <David....@t-online.de> wrote in message
> news:x5y97ap...@lola.goethe.zz...

[underfull hbox]


> > No, you don't. The above does not produce this message. A typical
> > culprit, however, would be the attempt to end lines in paragraph mode
> > with \\, probably the most misunderstood control sequence of LaTeX
> > altogether.

> Thanks, David. But what exactly does that mean? I'm starting a new
> paragraph with \\.

No, you don't. If you don't know what \\ means, look it up. \\ does
_not_ end a paragraph. It forces a line break in the _running_
paragraph. This means no paragraph separation, and no indents, and
nothing else normally connection with paragraph ends. This also means
that TeX needs to right justify the line at that location. It will
only work when TeX has assembled enough material to be able to stretch
the preceding paragraph material until the line ends flush right. In
most cases, TeX will stretch the line to the maximum ugliness it dares
yet perpetrate, then give up with the above error message.

> I know that \\ produces a newline but I wanted to flush left the new
> paragraph and I thought this would be a quick and dirty solution.

It also flush rights the "old" (actually the same) paragraph, and
does no paragraph separation.

If you want an unindented paragraph, start it with \noindent. But it
is usually a mistake to be starting a new paragraph after (or before)
a display, anyway, since it fouls up the usual distances LaTeX sets
around displays. Omit that empty line before/after the display or at
least disarm the empty lines by writing a single % sign in them.

Anuj

unread,
Dec 1, 2002, 1:26:59 AM12/1/02
to

Thank you. I managed to figure it out. I used the \setlength{\parindent} and
the ]\noindent. I have just one more question and I'll quit nagging.

I've gone through the Not So Short Introduction and haven't been able to
find an answer. How do I change the vertical spacing before and after a
section heading? Do I use \setlength{\parskip}?

Thank you.

David Kastrup

unread,
Dec 1, 2002, 4:15:26 PM12/1/02
to
"Anuj" <fri...@internet.com> writes:

> > > "David Kastrup" <David....@t-online.de> wrote in message
> > > news:x5y97ap...@lola.goethe.zz...
> > [underfull hbox]
>

> > If you want an unindented paragraph, start it with \noindent. But it
> > is usually a mistake to be starting a new paragraph after (or before)
> > a display, anyway, since it fouls up the usual distances LaTeX sets
> > around displays. Omit that empty line before/after the display or at
> > least disarm the empty lines by writing a single % sign in them.
> >
>
> Thank you. I managed to figure it out. I used the
> \setlength{\parindent} and the ]\noindent.

This sounds quite like you chose to ignore the advice.

> I have just one more question and I'll quit nagging.
>
> I've gone through the Not So Short Introduction and haven't been able to
> find an answer. How do I change the vertical spacing before and after a
> section heading? Do I use \setlength{\parskip}?

Meddling with the section header parameters can be done using
titlesec.sty if I am not mistaken. Again, you should try to
understand what you are doing if you choose that path.

Donald Arseneau

unread,
Dec 2, 2002, 2:02:06 AM12/2/02
to
David Kastrup <David....@t-online.de> writes:

> It [\\] forces a line break in the _running_ paragraph. ...


> that TeX needs to right justify the line at that location.

David, I think you might have to look up \\ :-). The intent of
\\ is to fill with whitespace and produce a linebreak. Maybe you
are thinking of \linebreak rather than \\ (or \newline).

> > I know that \\ produces a newline but I wanted to flush left the new
> > paragraph and I thought this would be a quick and dirty solution.

It is the correct solution, and when used for that, it works
great.

The usual mistake is *ending* a paragraph with \\

As I did just above -- with a blank line or \par following after \\.
People do this to increase the paragraph separation, when they
should instead set \parskip. The underfull box arises because
the paragraph-fill space (\parfillskip) is discarded when a totally
empty line occurs.

If you *begin* a paragraph with \\ (\\ after a blank line) LaTeX
complains explicitly.

Donald Arseneau as...@triumf.ca

0 new messages