Pseudorapidity on a 2D coordinate axis. For the coordinate system of the CMS detecter at the LHC, please see this post.




This is the simplest method with a for-loop in two variables: θ and η:
\documentclass[border=3pt,tikz]{standalone}\tikzset{>=latex} % for LaTeX arrow head\begin{document}\begin{tikzpicture}[scale=3]\foreach \t/\e in {90/0,60/0.55,45/0.88,30/1.32,10/2.43,0/+\infty}{\pgfkeys{/pgf/number format/precision=2}\draw[->,thick] % eta lines(0,0) -- (\t:1.2) node[anchor=180+\t,black] {$\eta=\e$}node[black,pos=0.72,fill=white,scale=0.8,inner sep=2] {$\theta=\t^\circ$};}\end{tikzpicture}\end{document}
In the following method, η is calculated and rounded to two significant digits on the fly, with the exception for θ = 0:
\documentclass[border=3pt,tikz]{standalone}\tikzset{>=latex} % for LaTeX arrow head\begin{document}\begin{tikzpicture}[scale=3]\foreach \t in {90,60,45,30,10,0}{\ifnum \t = 0\def\e{+\infty} % infinity symbol\else\pgfmathparse{-ln(tan(\t/2))} % pseudorapidity\pgfmathroundtozerofill{\pgfmathresult} % round with trailing zeroes\pgfmathsetmacro\e{\t==90?0:\pgfmathresult} % no trailing zeroes for theta = 90\fi\draw[->,thick] % eta lines(0,0) -- (\t:1.2) node[anchor=180+\t,black] {$\eta=\e$}node[black,pos=0.72,fill=white,scale=0.8,inner sep=2] {$\theta=\t^\circ$};}\end{tikzpicture}\end{document}
Full code to edit and compile if you like:
Click to download: axis2D_pseudorapidity.tex • axis2D_pseudorapidity.pdf% Author: Izaak Neutelings (June 2017)% Updated: December 2022\documentclass[border=3pt,tikz]{standalone}\usepackage[outline]{contour} % glow around text\tikzset{>=latex} % for LaTeX arrow head\usetikzlibrary{angles,quotes} % for pic (angle labels)\usetikzlibrary{arrows.meta} % for arrow head size\usetikzlibrary{bending} % for bending arrow head\contourlength{1.5pt}% TIKZ STYLES\tikzstyle{eta line}=[->,black!60!red,thick,line cap=round]\tikzstyle{theta node}=[black,pos=0.7,fill=white,scale=0.8,inner sep=1.5pt,rounded corners=3pt]\tikzstyle{mysmallarrow}=[-{Latex[length=3,width=2.5]},draw=black,line width=0.6,angle radius=45,angle eccentricity=1.1]\begin{document}% PSEUDORAPIDITY with manual for-loop over theta, eta\begin{tikzpicture}[scale=3]\message{^^JPseudorapidity simple}\def\R{1.2} % radius/length of lines\node[scale=1,below left=1] at (0,\R) {$y$}; % y axis\node[scale=1,below left=1] at (\R,0) {$z$}; % z axis\foreach \t/\e in {90/0,60/0.55,45/0.88,30/1.32,10/2.43,0/+\infty}{ % loop over theta/eta\pgfkeys{/pgf/number format/precision=2}\draw[eta line] % eta lines(0,0) -- (\t:\R) node[anchor=180+\t,black] {$\eta=\e$}node[theta node] {$\theta=\t^\circ$};}%\draw[black!60!red,thick] (0,0.1*\R) |- (0.1*\R,0) ; % overlap in corner\end{tikzpicture}% PSEUDORAPIDITY with automatic calculation of eta\begin{tikzpicture}[scale=3]\message{^^JPseudorapidity with automatic calculation of eta}\pgfkeys{/pgf/number format/precision=2} % two decimals\def\R{1.2} % radius/length of lines\node[scale=1,below left=1] at (0,\R) {$y$}; % y axis
Open in Overleaf: axis2D_pseudorapidity.tex