How to align a two-lined equation such that the first line left aligns with the surrounding text and the second line right aligns with the surrounding text?
Example (where the pipes denote the left and right edge of the surrounding text):
| |
P(x) =
a + b + c + d + e + f
| |
I fiddled around with flalign
, multline
, and multlined
, but did not get it working the way I want. Prepending a \vphantom
to the second line allows me to right-align the second line of the equation. Appending a \vphantom
to the first line does not left-align the first line (the \vphantom
continues to run in the right margin).
multline
provided by the packageamsmath