Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want to typeset several equations with only one equation number vertically centered, and every equation horizontally center.

I know two options. One is aligned environment within equation, which handles equation number nicely, but the default alignment (without any &) is right alignment; and you know, you can't rely on & to force center alignment.

Another is IEEEeqnarray environment, which handles alignment nicely, but the equation numbering of which is somewhat awkward since numbering is processed on a line-to-line basis, as far as I know (if the number of equations is even, or equations take different vertical space, you will be screwed).

Any idea about this? Maybe I missed some functionality of aligned or IEEEeqnarray?

share|improve this question
    
Have you tried gathered? –  Andrew Swann Jan 15 '13 at 18:34
add comment

1 Answer 1

up vote 5 down vote accepted

the package mathtools provides the gathered environment, which behaves like aligned (in that there is only one equation number generated), but otherwise behaves like amsmath's gather (in centering every line separately).

mathtools loads amsmath automatically, and options to amsmath can be passed via specifying those options to mathtools.

share|improve this answer
    
As far as I know, gathered is already in amsmath –  egreg Jan 15 '13 at 18:43
    
Cool, does exactly what I need. Thanks. –  KevinSayHi Jan 15 '13 at 18:52
    
@egreg Yes, it is. Most of time I work in amsart, which means I don't need extra package at all. –  KevinSayHi Jan 15 '13 at 18:53
    
@egreg -- aarrrggghhhh. i really ought to check the documentation before answering. i knew (at least) one of the "ed" forms was missing, and i mis-guessed. (there isn't any multlined in amsmath, but it's there in mathtools.) –  barbara beeton Jan 15 '13 at 19:13
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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