-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathquarks2.tex
100 lines (96 loc) · 2.97 KB
/
quarks2.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
\documentclass[tikz]{standalone}
\usepackage{amsmath, xcolor}
\boldmath
\colorlet{Green}{green!70!black}
\colorlet{Magenta}{magenta!90!black}
\colorlet{Yellow}{yellow!75!black}
\newcommand\quark[2]{\color{#1}$#2$}
\newcommand\anti[2]{\color{#1}$\bar{#2}$}
\newcommand\R{\quark{red}}
\newcommand\G{\quark{Green}}
\newcommand\B{\quark{blue}}
\newcommand\C{\anti{cyan}}
\newcommand\M{\anti{Magenta}}
\newcommand\Y{\anti{Yellow}}
\newcommand\K{\quark{black}}
\newcommand\gluon[2]{\footnotesize\begin{tikzpicture}
\node (g) {$\phantom g$};
\begin{scope}
\clip (g.north west) rectangle (g.east);
\node {\color{#1}$g$};
\end{scope}
\begin{scope}
\clip (g.south west) rectangle (g.east);
\node {\color{#2}$g$};
\end{scope}
\end{tikzpicture}}
\newcommand\gluonalt[4]{\footnotesize\begin{tikzpicture}
\node (g) {$\phantom g$};
\begin{scope}
\fill[#1,opacity=0.5] (g.north west) ++(-0.5pt,0.5pt) rectangle (g.center);
\clip (g.center) rectangle (g.north west);
\node {\color{white}$g$};
\end{scope}
\begin{scope}
\clip (g.north east) ++(0pt,1pt) rectangle (g.center);
\node {\color{#2}$g$};
\end{scope}
\begin{scope}
\clip (g.south west) ++(0pt,-1pt) rectangle (g.center);
\node {\color{#3}$g$};
\end{scope}
\begin{scope}
\fill[#4,opacity=0.5] (g.south east) ++(0.5pt,-0.5pt) rectangle (g.center);
\clip (g.center) rectangle (g.south east);
\node {\color{white}$g$};
\end{scope}
\end{tikzpicture}}
\begin{document}
\begin{tikzpicture}[
z={(0cm,1cm)},
y={(1cm,0cm)},
x={(7mm,3mm)},
inner sep=0mm,
gray,
very thin]
\foreach \x/\y/\z/\i in {
-1/-1/-1/1, 0/0/0/1, 0/0/0/-1, 1/1/1/-1}{
\draw (\x,\y,\z) --++(right:\i) --++(up:\i)
--++(left:\i) --++(down:\i);
\draw (\x,\y,\z) --++(right:\i) --++(0,0,\i)
--++(left:\i) --++(0,0,-\i);
\draw (\x,\y,\z) --++(0,0,\i) --++(up:\i)
--++(0,0,-\i) --++(down:\i);}
\draw
(1,1,0) --++(left:2) --++(down:2) --++(right:2) --cycle
(1,0,1) --++(left:2) --++(0,0,-2) --++(right:2) --cycle
(0,1,1) --++(down:2) --++(0,0,-2) --++(up:2) --cycle
;
\draw (0,0,0) node[fill=white] {\,\gluonalt{red}{Green}{Magenta}{cyan}\hspace{1pt}\raisebox{2.2pt}{\K\nu}\hspace{0.5pt}\gluonalt{red}{blue}{Yellow}{cyan}\,};
% \draw (0,0,0) node {\,\,\,\,\K\nu\gluon{red}{cyan}\!\gluon{Green}{Magenta}\!\gluon{blue}{Yellow}};
\begin{scope}[every node/.style={fill=white}]
\draw
(1,0,0) node (red) {\R d}
(0,1,0) node (green) {\G d}
(0,0,1) node (blue) {\B d}
(-1,0,0) node {\C d}
(0,-1,0) node {\M d}
(0,0,-1) node {\Y d}
(-1,-1,-1) node {\K{\bar e}}
(0,-1,-1) node {\R u}
(-1,0,-1) node {\G u}
(-1,-1,0) node {\B u}
(1,1,1) node {\K e}
(0,1,1) node {\C u}
(1,0,1) node {\M u}
(1,1,0) node {\Y u}
(-1,1,0) node {\gluon{Green}{cyan}}
(1,-1,0) node {\gluon{red}{Magenta}}
(1,0,-1) node {\gluon{red}{Yellow}}
(-1,0,1) node {\gluon{blue}{cyan}}
(0,1,-1) node {\gluon{Green}{Yellow}}
(0,-1,1) node {\gluon{blue}{Magenta}}
;
\end{scope}
\end{tikzpicture}
\end{document}