5

I'm having trouble producing a graph of the Lorentz constant, defined by

\frac{1}{\sqrt{1 - v^2/c^2}$

as a function of $v$. (Here, $c$ = $3 * 10^8$).

I tried many examples, but I usually get "dimensions too large." Any help is appreciated. I want the plot to show the vertical asymptote as v^2 approaches c^2.

  • 2
    Please don't use dollar signs, i.e. $$...$$ to show math expressions. Instead, use ```. We are not in Math.SE :P. – manooooh Sep 4 '18 at 4:20
  • 5
    Just a physics note: Indeed, as @marmot noticed, it doens't really make sense to call it the Lorentz 'contant' - usually it is called the Lorentz factor, or the gamma factor (as it is most often written as a lowercase gamma). – Bobson Dugnutt Sep 4 '18 at 7:37
12

Well, if this was a constant, it would not really be worth plotting, would it? I use natural units in which $\hbar=c=1$. To show that units do not matter, I am labeling the x-axis v/c.

\documentclass[tikz,margin=3.14mm]{standalone}
\usepackage{pgfplots}
\pgfplotsset{compat=1.16}
\begin{document}
\begin{tikzpicture}[declare function={Lorentz(\x,\c)=1/sqrt(1-(\x/\c)*(\x/\c));}]
\begin{axis}[ymax=pi,ylabel={$\gamma$},xlabel={$v/c$}]
 \addplot[blue,domain=0:1,samples=100] {Lorentz(x,1)};
\end{axis}
\end{tikzpicture}
\end{document}

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.