0

If I want to achieve something like the following:

enter image description here

where the text before the equaions is left-justified, how can I do that? So far I've been using stuff like

\llap{ Which gives us \hspace{3cm}} f;g;h = fg;h = fgh = f;gh

where I have to tweak the amount of hspace each time. I'm often, but not always, doing this inside the gather environment.

I suppose I could make an array with lcc columns, and put some \hfill in the left column, but how do I tell it to center the line on the middle column?

Eric Auld
  • 1,223
  • The \hspace{3cm}within \rlap does nothing. Try an flalign environment, with the text in the first column, and the math alignment in the middle column. But why don't you simply use \(short)intertext? – Bernard Nov 14 '16 at 02:11
  • often in a situation like this, \intertext is used (or \shortintertext from mathtools). of course, that puts the text on a separate line. – barbara beeton Nov 14 '16 at 02:12
  • @Bernard Sorry, I met \llap. Is there a way not to put the text on a separate line? – Eric Auld Nov 14 '16 at 02:13
  • \llap should be used only at the right margin. – Bernard Nov 14 '16 at 02:39
  • @Bernard Why not? – Eric Auld Nov 14 '16 at 03:05
  • @Eric Auld: I mean it shouldn't be used at the left margin, unless you want to write in the left margin. For the same reason\rlap shouldn't be used at the right margin – it creates a left-aligned box of width 0pt, so that its contents is written in the right margin. – Bernard Nov 14 '16 at 09:34

1 Answers1

1

Here is a solution with flalign*:

\documentclass{article}
\usepackage[showframe]{geometry} %
\usepackage{mathtools}

\begin{document}

\begin{flalign*}
&  & f; gh &  = f\,gh  &  &\llap{from side  $ (0,1,3) $} \\
&  & f; g &  = gh &  &\llap{from side  $ (0,1,2) $} \\
&\rlap{Which gives us}  & f; g; h = f\,g; h &  = f\,gh  =  f; gh \\
&\rlap{And inverting  $ f $  gives us}  &    g; h &  = gh &  & 
\end{flalign*}    

\end{document} 

enter image description here

Bernard
  • 271,350