# How to make a Minkowski Diagram [closed]

I just started using LaTeX and need some assistance creating a diagram like this. Except I don't need multiple hyperbolas, just one. My trouble is making the hyperbolas using \addplot. I was able to make the simple lines using \draw but I was told \addplot is better so I want to learn it that way too. Can anyone give me a place to start?

• Weclome to TeX Stackexchange! It makes it much easier to help you if you add the code that can be compiled (minimal working example (MWE)) and some more details of what you tried so far and why it failed. – jens_bo May 12 '15 at 7:41
• And in a very general sense, places to start would be the pgfplots manual. Which should help you draw everything but the hyperbolas. If you only need one, which one would it be? Or one in each, the past, future, and the space like areas? – jens_bo May 12 '15 at 7:46

## 1 Answer

You can use the different domains of definition to draw the parts of hyperbolas but it needs a little bit of adjustment to match the vertices (or you can find another parametric form that doesn't have this problem).

I chose 3,4 to be x,y scaling values in hyperbola formula. The details can be found in the very comprehensive pgfplots manual. Note that \draw,\fill and so on are TikZ commands. \addplot comes with the package pgfplots which is built on TikZ. So there is some interplay you need to sort out in your head.

\documentclass{standalone}
\usepackage{pgfplots}
\pgfplotsset{compat=1.12}
\begin{document}
\begin{tikzpicture}
\begin{axis}[no marks,grid]
\addplot {sqrt(3^2*(1+(x/4)^2))};
\addplot {-sqrt(3^2*(1+(x/4)^2))};
\begin{scope}[samples=351]
\addplot+[domain=1.33339:5] {sqrt(3^2*((x/4)^2)-1)};
\addplot+[domain=-5:-1.33333] {sqrt(3^2*((x/4)^2)-1)};
\pgfplotsset{cycle list shift=-2} % To match the color of the second previous cure
\addplot+[domain=1.33339:5] {-sqrt(3^2*((x/4)^2)-1)};
\addplot+[domain=-5:-1.33333] {-sqrt(3^2*((x/4)^2)-1)};
\addplot[thick] {3/4*x};
\addplot[thick] {-3/4*x};
\end{scope}
\end{axis}
\end{tikzpicture}
\end{document}