The content of this document may be incorrect or outdated.
Print this article Edit this article
TeX: Using TeX at ECN
Table of Contents
Using the Software
Fonts
Many programs make fonts they can't find. The first time a font is made before printing or previewing a lot of stuff will be printed on the screen. Character numbers are printed in square brackets as that font character is made, e.g., "[65]" for "a". You should be able to safely ignore the messages. The font should be saved after it is made so it won't need to be remade.
Path
The path tells Unix where to look for programs. After you type a command, Unix looks through the directories in your path to find the program you want to run.
Put /usr/local/bin early in your path by doing the following for the shells listed.
(What is a ``shell'' and what shell am I using?)
Use the following commands for the different shells
- csh (reads .cshrc and then .login file if logged in. Put your command in .cshrc.)
- set path = (/usr/local/bin $path)
- ksh (reads .profile file)
- PATH=/usr/local/bin:$PATH
- sh (reads .profile file)
- PATH=/usr/local/bin:$PATH
export PATH - tcsh (reads .tcshrc, or .cshrc if no .tcshrc, and then reads .login file if logged in. Put your change in .tcshrc if you have one, otherwise in .cshrc.)
- set path = (/usr/local/bin $path)
After you change the appropriate startup files log out and log back in. If you'll be changing your TEXINPUTS environment variable (see next section) you can make those changes now and log out and log back in after that's done.
TEXINPUTS
The TEXINPUTS environment variable tells TeX and LaTeX where to look for \input'ed and \include'ed files. If you don't have a TEXINPUTS, TeX and LaTeX check your current directory, then /opt/tetex/2.0.2/share/texmf/tex and all its subdirectories recursively.
Change your TEXINPUTS environment variable to change the order of or directories searched. TeX and LaTeX go through all directories in TEXINPUTS in order looking for files. Separate the different directories you want searched with a colon (:).
(What is a ``shell'' and what shell am I using?)
For example, use the following commands for the different shells, to first look in your current directory (.), then in a TEXINPUTS subdirectory in your home directory ($HOME/TEXINPUTS), then in /opt/tetex/2.0.2/share/texmf/tex and all its subdirectories recursively (a / following a directory name means looks through all lower subdiretories). All the following commands should be typed on one line (your browser may split them into two or more lines for display.)
- csh (reads .cshrc and then .login file if logged in)
- setenv TEXINPUTS ".:$HOME/TEXINPUTS:/opt/tetex/2.0.2/share/texmf/tex//"
- ksh (reads .profile, there are two commands here, one starts with TEXINPUTS=, the other starts with export)
- TEXINPUTS=".:$HOME/TEXINPUTS:/opt/tetex/2.0.2/share/texmf/tex//"
export TEXINPUTS - sh (reads .profile)
- TEXINPUTS=.:$HOME/TEXINPUTS:/opt/tetex/2.0.2/share/texmf/tex/
- tcsh (reads .tcshrc (or .cshrc if no .tcshrc) and then reads .login file if logged in)
- setenv TEXINPUTS ".:$HOME/TEXINPUTS:/opt/tetex/2.0.2/share/texmf/tex //"
After you change the appropriate startup files log out and log back in.
dvipr
Put dvipr information here.
latex
Be sure to read about fonts, setting your path, and TEXINPUTS above before trying latex.
Type ``latex filename'' to run filename.tex through latex and produce a filename.dvi device-independent file. This .dvi file can be previewed with xdvi or printed with dvipr.
I use tex and latex. I like to have my tex file names end with .tex and latex file names end with .ltx so I can tell them apart easily. I use ``latex filename.ltx'' to run LaTeX.
Grants.govTo convert a filename.tex file into a filename.pdf file suitable for submission to the grants.gov do the following.
An example filename.pdf file
\documentclass{report}
% Use 1" margins.
\usepackage[margin=1truein]{geometry}
% Define \includegraphics{...}.
\usepackage[pdftex]{graphicx}
% Automatically convert .eps to .pdf files for figures.
\usepackage{epstopdf}
\begin{document}
Test grants.gov instructions.
Let's put a figure here.
\begin{figure}[ht]
\centering
\includegraphics{plot}
\caption{This is the figure caption.}
\end{figure}
This is the end.
\end{document}
Instructions for Linux
Run
pdflatex -shell-escape filename
to read filename.tex and make a filename.pdf file.
Do
acroread filename.pdf
and check that
File => Document Properties... => Fonts
lists all fonts as
"Type 1", "Type 1C" or "TrueType"
Purdue Theses
See Doing Purdue Theses and Dissertations Using LaTeX.More LaTeX Information
LaTeX ResourcesLaTeX Frequently Asked Questions
tex
Be sure to read about fonts and setting your path above before trying the following.
Type ``tex filename'' to run filename.tex through tex and produce a filename.dvi device-independent file. This .dvi file can be previewed with xdvi or printed with dvipr.
Revised: June 4, 2007
Created: February 17, 2000
Last Modified:
Dec 19, 2016 11:12 am US/Eastern
Created:
Jun 4, 2007 2:29 pm GMT-4
by
admin
JumpURL: