# Tikz, Slides, and Dissertations

There has been some recent discussion about tikz and beamer and I wanted to throw my two cents into the mix. What better way then by showing off the slides I used last week to talk about my dissertation? I had a lot of pictures, all of which I made entirely in tikz. Here is the link.

One of the things that I like is that you can embed beamer commands into tikz. For example adding  “/onslide<n>{…}” around tikz code makes that code only appear on slide n. Look at pages 10-13 for an example of this. You could try to do this by using an external program to make each of the pictures seperately, and then just make succesive slides, but my impression is that it would be a real headache. How do you make sure the pictures line up presisely from slide to slide? With tikz this is easy becasue it is just one picture, with different parts showing up at different slides. Another example occurs on pages 24-27. Enjoy!

## 11 thoughts on “Tikz, Slides, and Dissertations”

1. Hi Chris,

I’m just learning to use tikz and beamer and the two recent presentations I’ve seen on here (your’s and Ben’s) are most inspiring. Is there any chance I could take a look at your tex files?

2. Have you ever considered using METAPOST with EMP package?
It appears to be very similar to TikZ in its capabilities
(e.g., in both cases the figures are embedded into the TeX file, you can use Besier splines etc.).
However, METAPOST can solve arbitrary linear systems (e.g., you may say that a point lies on two lines and METAPOST will intersect them and find the point),
whereas TikZ apparently cannot do this.
Also METAPOST is a full-fledged programming language, which makes it easy for me to draw complicated figures.
Also its syntax is much nicer than that of TikZ (e.g., you don’t have to prefix everything with a \, etc.). METAPOST actually looks like a fairly standard programming language.

3. The best source of examples of TikZ is the (already mentioned) texample site: http://www.texample.net/tikz/examples/. The examples are tagged and have well-commented source (six are tagged “beamer”). If anyone has any examples that they think would make good examples then may I suggest that they send them to the maintainer of that site since it makes sense to have a single place to find them all.

I’ve just done a talk in which I used beamer and TikZ. I’m in the habbit of putting these talks on my webpage – click on my name at the top of this comment to go directly to the page of that talk – and although the source for the talk itself is a little complicated so I haven’t posted it then I have put the source code for the pictures. I’ll upload these to the texamples site when I’ve cleaned up the code.

To answer the comment about METAPOST, the main advantage of TikZ is that it is simple to learn for an average LaTeX user. Most diagrams aren’t that complicated and wouldn’t need the full functionality of METAPOST. Anything really complicated can be drawn in an external program (eg gnuplot) and then imported into the document via TikZ (with the advantage over a direct import that as TikZ controls the actual drawing, all the diagrams look consistent).

Also, TikZ can find the intersection of lines, as far as I understand it.

Since when was prefixing everything with a backslash a disadvantage? In perl, all variables are prefixed with a dollar, arrays with ampersands, and hashes with hashes. In php, everything is prefixed with a dollar whether it’s a variable, array, or hash. I actually prefer these to, say, lisp where it’s hard to distinguish between functions, variables, and the rest (of course, a lisp programmer would say that that is the point!).

However, one of the biggest selling points for TikZ, as far as I’m concerned, is that Till Tantau (the author) is one of those open source guys who really understands the need for good documentation. Even if you don’t use his packages, you should read the beamer and TikZ documentation because they are packed with good advice on, respectively, presentations and drawings. Even if you are till in the Dark Ages and use chalk for your talks, read the beamer documentation!

Finally, if you want a programming language for your documents, why not just hack in TeX? I’m getting to the point that my style files are longer than my articles.

4. Allen Knutson says:

There’s an [ERROR] on p41 of the pdf.

5. Bruce Bartlett says:

Hi Chris,

Any chance of seeing the source code for those slides? It must have taken ages of fiddling around with co-ordinates to create those pictures, surely?

6. Bruce Bartlett says:

Hi Chris,

Great slides.

1. Regarding the ability of TQFT’s to distinguish manifolds discussed on pages 5-9, might it be that extended (higher-categorical) TQFT’s have greater distinguishing power than ordinary TQFT’s?

2. The exercise you mention on page 45 (“prove the pair of pants is isomorphic to the twisted pair of pants”) is indeed interesting. I had to perform this calculation in one of the appendices in my thesis, where one has to show that the movie of the pair of pants is equal to the movie producing the braided pair of pants, at least in a certain higher categorical context. I needed this result to prove that if two 2-categories A and B were equivalent, then their braided monoidal categories objects Dim A and Dim B were equivalent. Sounds obvious I know, but turned out to be a doozer for me. I needed to enlist the help of Scott Carter, who I regard as a genius when it comes to “movie moves”, as well as Nick Gurski.

7. Bruce Bartlett says:

What I’m thinking in question 1 above is, say we want to distinguish two 4-manifolds M and M’. Is it possible we could distinguish them by some monster 9-dimensional extended TQFT Z, which would assign some nonequivalent 4-categories Z(M) and Z(M’) to M and M’? I.e. instead of trying to distinguish their invariants (numbers) at the top level, perhaps try to distinguish their algebraic invariants (higher categories) at lower levels?

8. Bruce, I think one can consider TQFT-like structures that aren’t fully dualizable, and therefore don’t necessarily assign numbers to the top level. There are operations (like infinite summation) that aren’t generally possible on the numerical level, but can be done with, e.g., vector spaces, and this may afford more flexibility. I don’t know how much it would help when trying to distinguish compact manifolds, though.

9. @1 and 5,

I am a little reluctant to release the tex code because some of it is very poorly written and so shouldn’t really be used for learning. I wrote the code for some of the diagrams when I was just learning tikz, and now I would do it differently. For example I would use a lot more of the relative coordinates. For example I should have used commands like:

\draw (3, 4) — ++(1,2) — ++(0, -2);

This starts at (3,4) then draws a line to (4, 6), then draws a line to (4, 4). If I change the starting coordinate (3,4) to something else, the whole diagram moves with it.

That’s what I would do now. Instead I just did the diagrams in as fast and quick and dirty a way as I possibly could. Then I used a lot of copy and paste and “scope” commands to move things around.

I need to think more about whether it would be helpful or harmful to let people see my nasty nasty code…

10. Bruce,

So there are a couple things to say. First of all, the results about distinguishing manifolds only apply to “honest” TQFTs which are unitary. By unitary I mean defined over the complex numbers and we have:

$Z(\overline M) = \overline Z(M)$

As I have been lead to believe, most of the interesting “TQFTs” in dimension four fail on both accounts. They may not be unitary and they certainly aren’t defined for all manifolds. There are conditions like $b^2_+ \geq 1$, or some such thing.

That said, these results are also only about the top structure. They certainly don’t rule out your question about using the lower structure to distinguish, say, 4-manifolds. I think it is an exciting thing to contemplate.

11. Bruce Bartlett says:

Ok, interesting, I didn’t know most interesting TQFT’s in 4d might well not be unitary.