% This is a template .tex file for you to
% use for your homework solutions.
% Please edit this as needed, but keep
% the format the same so that everyone's
% solutions are uniform in appearance.
% Lines begining with the percent symbol
% are comments and are ignored when you
% produce your document.
% We start with the header, which sets
% up the basic properties of the document.
% set the type of document
\documentclass[12pt]{report}
% load the package from the American Mathematical Society,
% which contain many useful commands and symbols
\usepackage{amsmath}
\usepackage{amssymb}
% load graphics package so that we can import images
%\usepackage{graphicx}
% set page dimensions
\textwidth 6.5in
\textheight 8.5in
\evensidemargin 0.0in
\oddsidemargin 0.0in
\topmargin 0.0in
\headsep 50pt
\headheight 0.0in
\footskip 0.0in
% set line spacing
\renewcommand{\baselinestretch}{1.1}
% set the page style to use custom headings
\pagestyle{headings}
% don't indent paragraphs
\setlength\parindent{0pt}
% put skip 8 points between paragraphs
\parskip 8pt
% make some definitions
% put in your problem number and name
\def\yourprob{1-1}
\def\yourname{Matt Mewes}
% put these in the header
\def\header{{\large\bf Prob.\ \yourprob}\hskip20pt(solution by \yourname)}
\markboth{\header}{\header}
% Now for the body of the file. This contains
% the text and commands to produce the document.
% start of document
\begin{document}
This is a template you should use to
write up your homework assignments.
You can simply edit the {\it .tex}
file, removing this text and replacing
it with your solution.
You also need to edit the
\verb.\def\yourprob. and
\verb.\def\yourname. lines near
the beginning of the {\it .tex} file
so that your name and problem appear.
The {\it .pdf} file that this file produces
is also provided.
Editing \LaTeX\ is very differnt than
using a word processor.
The {\it .tex} file is just a text
file containing the command that \LaTeX\
uses to produce your document.
You then run \LaTeX\ on this file,
which then interprets the commands
and produces a readable document,
normally as a {\it .dvi} file.
This can then be converted to something
a little more common like a {\it .Pu}
or {\it .pdf} file.
There are programs that will serve as
editors and perform all these steps for you.
MacTex is a package containing all the
necessary software you will need to use \LaTeX\
on a Mac.
It contains the editor TexShop that will
help you create your documents.
For Windows, MikTex is a popular option.
Both are completely free.
You should spend some time looking at
and comparing the {\it .tex} and {\it .pdf}
versions of the brief tutorial.
You'll notice that the I like to write
in short lines, and that I generally
start every sentence on a new line.
This makes editing somewhat easier.
\LaTeX\ will join all whitespace
(spaces, newlines, tabs, etc.) to
form a single space.
So I can leave space
and break up text on as
many
lines
as
I
feel
like.
\LaTeX\ will fix the spacing and
make things look nice in the end.
However, leaving a blank line tells \LaTeX\
to start a new paragraph.
Looking at the {\it .tex} version,
you'll see a bunch of words prefixed
by a backslash.
These are commands that tell \LaTeX\ to
something other than interpret the text.
For example, the \verb.\it. command
switches to {\it italics.}
The \verb.\LaTeX. command produces the
fancy \LaTeX.
The big advantage of \LaTeX\ over word processors
is the ease at which it can handle mathematical
expressions.
Mathematical expression are produced by
sandwiching your equation by dollar signs.
For example, the text
\verb.$x = \beta\times\sin\theta$.
produces the equation
$x = \beta\times\sin\theta$.
The commands to produce all the Greek
letters are simply their names prefixed
by the backslash.
To produce a numbered equation,
you switch the the equation environment using
\verb.\begin{equation}.
followed by your equation and a
\verb.\end{eqation}.
to exit the equation environment.
I've put a number of examples at the end
for you to look at.
This should be enough information
for you to get started.
Feel free to ask me questions if
you can't figure out how to produce a
particular kind of mathematical expression.
Google or the senior physics majors might
also be a good source for help.
There are also a number of books that
serve as decent references, though
I don't know of any that are good sources
for learning \LaTeX.
% force a page break here - rarely needed
\pagebreak
{\bf Example equations:}
\begin{equation}
\vec A = M \cdot \vec B
\end{equation}
\begin{equation}
% & implies start new column
% \\ implies start new row
\begin{pmatrix}
A_1 \\
A_2 \\
A_3
\end{pmatrix}
=
\begin{pmatrix}
M_{11} & M_{12} & M_{13} \\
M_{21} & M_{22} & M_{23} \\
M_{31} & M_{32} & M_{33}
\end{pmatrix}
\begin{pmatrix}
B_1 \\
B_2 \\
B_3
\end{pmatrix}
\end{equation}
\begin{equation}
\vec F
= \frac{d\vec p}{dt}
= m \ddot {\vec x}
\end{equation}
\begin{equation}
T = \frac{1}{2} I \omega^2
= \dfrac{1}{2} I \omega^2
= \tfrac{1}{2} I \omega^2
\end{equation}
\begin{equation}
\omega = \frac{2\pi}{T} = \sqrt{\frac{g}{l}}
\end{equation}
\begin{equation}
\vec A = \vec\nabla\times\vec C \ ,
\quad
A_j = \epsilon_{jkl} \nabla_k C_l
= \epsilon_{jkl}\ \frac{\partial C_l}{\partial x_k}
\end{equation}
\begin{equation}
\frac{d\vec A}{ds}
= \lim_{\Delta s \rightarrow 0}
\frac{\Delta\vec A}{\Delta s}
\end{equation}
\begin{equation}
\Delta U = -\int_i^f \vec F\cdot d\vec r
\end{equation}
% end of document
\end{document}
% LocalWords: begining pdf differnt dvi MacTex TexShop MikTex Google