1. Not finding help here? Sign up for a free 30min tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

How to write a = b = c = d all aligned

  1. Sep 14, 2009 #1
    1. The problem statement, all variables and given/known data

    Hi, I was just wondering how to write a = b = c = d all aligned - like not in 2 columns

    I have been messing around with & alot and I still can't get it. I know its simple I just am a first time user of Latex so any help would be aprreciated!
     
  2. jcsd
  3. Sep 14, 2009 #2
    Re: Latex

    Hi there,

    The ampersand (&) in LaTeX is used in the math environment to align different lines of the equation. Meaning that, with multiple lines equations, the characters between the ampersand will be align.

    For your question, I don't think I completely understand what is your intention. What do you want to align in this equation??? If you just want to center the equation, you can simply use the $$a = b = c = d$$.

    Cheers
     
  4. Sep 14, 2009 #3
    Re: Latex

    Thanks for you reply. I intended to have lots of equations like:
    a = b = c = d
    f = g = h = i and like for them all to be aligned at the equals signs. Is that possible?
     
  5. Sep 14, 2009 #4
    Re: Latex

    Sure thing,

    You might want to try something like:

    Code (Text):
    \begin{eqnarray*}
    a = b &=& c = d \\
    e = f &=& g = h
    \end{eqnarray*}
    which would align the two lines at the &=&. You can vary to have it align somewhere else, like:

    Code (Text):
    \begin{eqnarray*}
    a = b = &c& = d \\
    e &=& f = g = h
    \end{eqnarray*}
    Hope this helps.

    Cheers
     
  6. Sep 14, 2009 #5
    Re: Latex

    thank you!
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook