How can I insert two equations on separate lines in TeXShop?

  • Thread starter Thread starter Mantaray
  • Start date Start date
  • Tags Tags
    Line
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
2 replies · 6K views
Mantaray
Messages
17
Reaction score
0
I'm having the following problem in TeXShop - how can I put two equations in two separate lines?
Thus far I have something like:

Code:
\[
 p_y = s \cos \alpha \\ 
 p_x = s \sin \alpha
\]

But I still get the two on the same line..
Help would be very much appreciated
 
Physics news on Phys.org
You need to use one of the multiline environments.
The most basic of which is array (used inside \[\])
The best is probably (as long as you're using the amsmath package)
Code:
\begin{align}
 p_y &= s \cos \alpha \\ 
 p_x &= s \sin \alpha
\end{align}
where the ampersands (&) are alignment markers.
This produces
[tex]\begin{align}<br /> p_y &= s \cos \alpha \\ <br /> p_x &= s \sin \alpha<br /> \end{align}[/tex]

For more details see
http://en.wikibooks.org/wiki/LaTeX/Mathematics
and
http://en.wikibooks.org/wiki/LaTeX/Advanced_Mathematics
 
Last edited: