I am trying to put 3 equations with "=" signs aligned but also left aligned. I tried the following:
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{flalign*}
RPC &= A+B\tilde{f} +C x &\\
A &= a+\eta &\\
E &= cte &
\end{flalign*}
\end{document}
With this I get the stuff in the left and the "=" signs aligned. However, I also need A (in the second equation) and E (in the third equation) to be aligned to the R (in the first one)
Does anyone know how to get it?
thanks
This approach avoids explicit spacing commands.
\begin{flalign*}
RPC &= A+B\tilde{f} +C x &\\
\omit$A$\hfil&= a+\eta &\\
\omit$E$\hfil&= cte &
\end{flalign*}
This way is a little less TeXish.
\begin{flalign*}
\rlap{$RPC$}\phantom{RPC} &= A+B\tilde{f} +C x &\\
\rlap{$A$ }\phantom{RPC} &= a+\eta &\\
\rlap{$E$ }\phantom{RPC} &= cte &
\end{flalign*}
I have tried all different combinations of &
s and haven't found anything that works quite right. There's probably some better way of doing it, but you could just use \hphantom
to make the A
and E
take roughly the same amount of space as RPC
:
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\begin{flalign*}
RPC & = A+B\tilde{f} +C x \\
A\hphantom{PC} & = a+\eta \\
E\hphantom{PC} & = cte
\end{flalign*}
\end{document}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With