> How do I break a long equation so that LaTeX displays it into a couple
> of lines?
Try the amsmath package. Running
texdoc amsldoc
from a command prompt should bring up the documentation on any TeX system.
--
Morten
Could s.o. provide sample code?
> I tried the multline tag, but I have 2 problems with it:
> 1. it always breaks equations; isn't it better if they break only if
> necessary?
So you want LaTeX to do it automatically? That's not what you said
initially. In that case you will have to go for the `breqn' package.
> 2. I could not make it produce an equation number and I'm splitting
> without alignment;
>
> Could s.o. provide sample code?
Huh? Last time I checked, the manual had plenty of examples.
--
Morten
The following expression is too long to fit on a single line and should
be split: $<an expression comes here>$.
It depends on what you have there. Stuff like $A+B=C$ will break with no
problems using the default settings but other constructs might not. You
can tell LaTeX to allow a break with \allowbreak.
--
Morten
The following expression is too long and should be split: $a + b +
\allowbreak \left( c + d + f + b + c + d + f \right) = c$.
Using \left...\right creates an unbreakble object so when trying to find a
break point here, TeX could probably not use the place where your
\allowbreak is (which doesn't have that great an effect coming right after
a +). If you need the delimiters above to scale you might want to use
\bigl etc. as these don't have the effect of freezing the inner expression.
--
Morten
a + b + c + d + f + b + c + d + f = c?
>AT> Well, should I use ( and ) or \left( and \right) for expression such as
>AT> a + b + c + d + f + b + c + d + f = c?
Just ( and ). \left( and \right) are for those cases when there are tall
parts inside.
--
Piet van Oostrum <pi...@cs.uu.nl>
URL: http://www.cs.uu.nl/~piet [PGP 8DAE142BE17999C4]
Private email: pi...@vanoostrum.org
> Well, should I use ( and ) or \left( and \right) for expression such as
>
> a + b + c + d + f + b + c + d + f = c?
You should almost never use \left ...\right for inline mathematics. If you
have something hat is so large as to require the automatic scaling then it
will probably not look very good as inline material. The line spacing will
be pretty bad.
--
Morten
> I'd rather use \left... \right... for promotion/demotion purposes.
Then you'll just have to learn to live with it.
--
Morten
\[
a = n + n + n + n + n + n + n + n + n + n + n + n + n + n + n + n + n +
n + n + n + n + n + n + n + n + n + n + n + n
\]
What else could I try?
Of course not, this is not inline math. If you want to break display math
(that's what you have here), you must either use breqn to do it
automatically or use the amsmath facilities to do it manually.
--
Morten