Archive for the ‘LaTeX’ Category

Using Hyperref, Graphicx, and Algorithm together

April 21st, 2009 1 comment

In LaTeX, the hyperref package can be challenging to work with. It is well known that the hyperref package must be loaded last, BUT when using the algorithm package as well things get tricky. algorithm must be loaded after hyperref BUT, doing the following error if figures are used at the same time with pdfTeX:

ERROR: pdfTeX warning (ext4): destination with the same identifier (name{figure.1})

The solution is to load the float package (which is normally loaded by other more high-level packages) before hyperref like so:


The other solution is to not use pdfLaTeX, and use regular LaTeX instead.

Categories: LaTeX Tags:

Advanced LaTeX Workshop

March 12th, 2009 4 comments

The “LaTeX Intro Workshop” was such a big hit that I was asked to do an advanced workshop as a follow up.


I will cover these main topics:

  • LaTeX Basics
  • GT Thesis Writing
  • Useful packages
  • BibTeX bibliographies
  • Advanced figure tutorial
  • Beamer slides presentation tutorial
  • Beamer poster tutorial

While there is certainly enough minutia within LaTeX to keep someone busy forever trying to learn it all, I decided to focus on some of the bigger-picture topics that might benefit everyone. After all, there’s always google to answer those little specific questions.

Here are the files for the tutorial that will be covered during the talk:

This zip file holds three different tutorials. The first is a tutorial on creating beautiful figures. The second is on creating slideshows in beamer. The third is a short intro to making posters in beamer.

This tutorial will be performed LIVE on March 26th at 3pm in the Homer Rice Instructional Center in the Georgia Tech Library.

Categories: LaTeX Tags: , , ,

LaTeX Intro Workshop

November 13th, 2008 2 comments

LaTeX (pronounced lah-tech) is a powerful tool for creating beautiful documents. This post covers a workshop I gave recently introducing LaTeX to some curious graduate students. The materials here show some of the features and walk new users through the basics of using LaTeX.

This would make a nice tutorial for others trying to teach LaTeX as well as enterprising students trying to find a quick way to jump in and start using it. The workshop I taught was part of a class put on by the Georgia Tech Library. I will teach a second class on Dec. 1, 2008. Much of the work in creating these examples was done by David Reid and adopted (slightly) by me.

I began the class with this presentation:

LaTeX Introduction Presentation

This covers what LaTeX is, why it’s useful, and walks the class through the setup of the integrated TeX editor use used, TeXnicCenter. This talk also introduces the examples covered during the workshop. Below is a link to the example files used.

LaTeX Workshop Files

I walked the class through each of the files, explaining peculiarities and pointing out the differences between commands, environments, etc. The workshop finished with a quick summary of some of the other uses of LaTeX including making slides and posters. I also provided links to these very useful resources:

David’s Slideshow
The Not So Short Guide to LaTeX2e

I may try to tape-record the next class and post the video here for anyone interested in watching.

Categories: LaTeX Tags: , ,

Preparing Final Submissions for IEEE Journal Articles

August 1st, 2008 9 comments

Once you get through the process of writing your paper, getting it reviewed, making revisions, and finally getting that ACCEPT email in your inbox, the work isn’t done. You must prepare the figures in the paper so that they can be easily used by the IEEE to make a nice, high-quality, correctly laid-out, final print version of the article. This process could be quite complex and time consuming.

This post will cover some tips, tricks, and scripts to get your journal submission ready to go quickly and easily. The big challenges are:

  • Getting all figures into single eps files
  • Creating a list of figure captions

The good news is that both of these are delightfully quick if you’ve been using LaTeX to compose your article. Read on to find out how    Click to continue →

Categories: Academic, LaTeX Tags:

LaTeX Beamer Poster Theme and Template

June 18th, 2008 11 comments

Some background: LaTeX is a typesetting tool used to layout documents. Beamer is a package for LaTeX that helps make nice looking slides and posters. Recently Philippe Dreuw devised a very nice way to make really slick posters using LaTeX and Beamer. These posters are a great way to demonstrate your work at presentations and conferences.

I’ve been making posters this way sine my friend introduced me to them. He and I spent time figuring things out, and I wanted to share! Below you’ll find a simple to use template for making posters as well as examples and some how-to’s that will help you make posters like this one I made for an up-coming conference in Alaska!

LaTeX Poster
[pdf of this poster]

First, you’ll need to install LaTeX and the Beamer class. Next, download the zip file below which has some style files as well as a sample tex file.

   Click to continue →

Categories: LaTeX Tags: , ,

LaTeX Template for Homeworks

April 18th, 2008 1 comment

I’ve taken to writing all of my homework assignments for my (few remaining) classes in LaTeX, the markup language used by many to typeset scientific papers, theses, books, slides, posters, etc.

Why go through all this hassle for homeworks? Using LaTeX for homeworks
allows you to do lots of nice things like:

  • Have your work neatly typeset
  • Impress your professors who might recognize the fonts
  • Include equations easily
  • Put math right in the text
  • Not ever have to mess with MS Word

Being able to include equations is especially nice. When I do math
homeworks I often find it simpler to do derivations in LaTeX rather than
scratching them out on the backs of poorly written papers. If I make a
mistake somewhere, I can quickly change all down-line equations with a
find-replace procedure instead of having to re-write or cross out large blocks
of scribbles.

The template I use is mostly the same for every class. Sometimes I add or
remove things for specific courses to make the professors happy. I’ve posted
that basic template below. Enjoy, and let me know if you if you make any


Categories: LaTeX Tags:

Beamer and Latex With Keynote Theme

February 15th, 2008 49 comments

LaTeX is a typsetting system that allows you to make great-looking documents, and is well-used to make academic papers. I even use it for homeworks and other documents. There are also packages that allow it to make fantastic posters and slide presentations as well. I spent the last few days getting caught up on this, and want to share what I’ve figured out:

  • A sexy Beamer theme that looks like Keynote
  • How to format the footer
  • How to make slide numbers
  • How to remove the navigation symbols
  • How to make movies show up in presentations
  • The best references

I’ll talk about each of these briefly and give links to download a demo presentation and the .tex and .sty files that made it. Here’s a sneak peek of what it looks like!

keynote beamer presentation

   Click to continue →

Categories: LaTeX Tags: , ,

\newcommand with arguments in LaTeX

January 7th, 2008 2 comments

If you’re using LaTeX to write a document (article, thesis, grocery list, etc.), you can define your own custom commands to save you time and make your code look cleaner. At the beginning of your document include the line


Now, if you type “\newtag” in your LaTeX code, it will be automatically substituted with “whatever_you_want” when the LaTeX is compiled! This is great, but you can do even more. Changing the syntax slightly, you can pass arguments to these macros so that they become little functions. For instance if you want a quicker way to make things bold, include


Now, if you type “\bt{x}”, you’ll get “\textbf{x}” which will be interpreted as x. In this syntax, the number in []’s is the number of arguments the macro should expect, and it is referenced as #1. You can also do this with multiple arguments like this


When you call this you’d type \vfrac{a}{b} to make a fraction a/b. There will be a set of {} for each argument. In this command I also used the \ensuremath{} command. This command allows you to put ‘math’ commands into regular text or in equations, and is a big help when writing papers!

I hope this information helps you. Thanks to these guys for posting the info I finally found when I needed to find out.

Categories: LaTeX Tags:

Matlab TeXniques

January 29th, 2007 1 comment

Those of you who don’t know or don’t care what Matlab is… today’s post isn’t for you. Just skip it.

Now that the cool kids have left, us geeks can be alone: So, in my lab at GT we primarily use Matlab, so I’m trying to rekindle that romance after a torrid affair with C++ at Siemens. Unarguably, one of the best things about Matlab is how easy it is to visualize things. However, one little tidbit has always bugged me. There is always that damn big fat gray border around all of your figures. This is only mildly annoying while programming… but when it comes time to save figures out for a paper or a report annoying becomes infuriating. You have to scale and crop and zoom and you can’t script it well at all. (Not being able to script things is one of my pet peeves.)

But fear not dear friends… I have found the solution: exportfig. This is a great script for Matlab that lets you A) use tight borders for the figure, B) change the colors cleverly to black and white or grayscale, C) save the figure directly as a .eps file for easy integration with LaTeX! Here’s a nice page that explains how to use the library: Exporting Figures for Publication: Part 2.

One question that I haven’t been able to solve is how to eliminate that gray border in day-to-day usage. I pretty much never want it. If anybody has any suggestions, send them my way!

And, since I have the attention of all you Matlab-ers out there, I just got R2006a (this is the newest version). This baby rocks. It has a cool feature that allows you to execute code in little blocks called ‘cells.’ This is exactly how I debug and prototype, so it saves me a lot of highlighting and pressing [F9]. Check it out if you have the means to.

Categories: LaTeX, Matlab Tags: , ,