1

Consider the following piece of code, which uses the tikz-feynman package:

\usepackage{tikz-feynman, contour}
\tikzfeynmanset{compat=1.1.0}

\begin{document}
\begin{center}
    \begin{tikzpicture}[baseline={(current bounding box.center)}]
    \begin{feynman}
        \diagram [vertical'=a to b] {
            {   [edges={draw=none}]
                a -- b [label=0:\(\mu_{3}\)]
                -- c [label=-180:\(\mu_{4}\)]
                -- d [label=-180:\(\mu_{1}\)]
                -- a [label=0:\(\mu_{2}\)],
            },
            {   [edges={photon}]
                a -- ap [particle=\(p_{2}\)],
                b -- bp [particle=\(p_{3}\)],
                d -- dp [particle=\(p_{1}\)],
                c -- cp [particle=\(p_{4}\)],
            },
        };
        \diagram* {
            (c) -- [fermion] (b)
                -- [fermion] (d)
                -- [fermion] (a)
                -- (c),
        };
    \end{feynman}
    \end{tikzpicture}
    %
    \feynmandiagram[baseline={(current bounding box.center)}, vertical'=a to b,] {
        {   [edges={fermion}]
            a -- b [label=0:\(\mu_{3}\)]
            -- c [label=-180:\(\mu_{4}\)]
            -- d [label=-180:\(\mu_{1}\)]
            -- a [label=0:\(\mu_{2}\)],
        },
        {   [edges={photon}]
            a -- ap [particle=\(p_{2}\)],
            b -- bp [particle=\(p_{3}\)],
            d -- dp [particle=\(p_{1}\)],
            c -- cp [particle=\(p_{4}\)],
        },
    };
    %
    \begin{tikzpicture}[baseline={(current bounding box.center)}]
    \begin{feynman}
        \diagram [vertical'=a to b] {
            {   [edges={draw=none}]
                a -- b [label=0:\(\mu_{3}\)]
                -- c [label=-180:\(\mu_{4}\)]
                -- d [label=-180:\(\mu_{1}\)]
                -- a [label=0:\(\mu_{2}\)],
            },
            {   [edges={photon}]
                a -- ap [particle=\(p_{2}\)],
                b -- bp [particle=\(p_{3}\)],
                d -- dp [particle=\(p_{1}\)],
                c -- cp [particle=\(p_{4}\)],
            },
        };
        \diagram* {
            (a) -- [anti fermion] (b)
                -- [anti fermion] (d)
                -- [anti fermion] (c)
                -- (a),
        };
    \end{feynman}
    \end{tikzpicture}
    \end{center}
\end{document}

This piece of code draws the following figure:

I would like to label each figure. I do not want a caption, but just a label beneath each diagram. The label should say Diagram I, Diagram II, Diagram III.

How do I implement this into my code?

  • First lines on your code are missing. – Ignasi Feb 23 '17 at 15:28
3

I don't get the expected diagram, but it doesn't matter to my answer: Use a tabular.

enter image description here

\documentclass{article}

\usepackage{tikz-feynman, contour}
\tikzfeynmanset{compat=1.1.0}

\begin{document}
\begin{center}
    \begin{tabular}{ccc}
    \begin{tikzpicture}[baseline={(current bounding box.center)}]
    \begin{feynman}
        \diagram [vertical'=a to b] {
            {   [edges={draw=none}]
                a -- b [label=0:\(\mu_{3}\)]
                -- c [label=-180:\(\mu_{4}\)]
                -- d [label=-180:\(\mu_{1}\)]
                -- a [label=0:\(\mu_{2}\)],
            },
            {   [edges={photon}]
                a -- ap [particle=\(p_{2}\)],
                b -- bp [particle=\(p_{3}\)],
                d -- dp [particle=\(p_{1}\)],
                c -- cp [particle=\(p_{4}\)],
            },
        };
        \diagram* {
            (c) -- [fermion] (b)
                -- [fermion] (d)
                -- [fermion] (a)
                -- (c),
        };
    \end{feynman}
    \end{tikzpicture}
    &
    \feynmandiagram[baseline={(current bounding box.center)}, vertical'=a to b,] {
        {   [edges={fermion}]
            a -- b [label=0:\(\mu_{3}\)]
            -- c [label=-180:\(\mu_{4}\)]
            -- d [label=-180:\(\mu_{1}\)]
            -- a [label=0:\(\mu_{2}\)],
        },
        {   [edges={photon}]
            a -- ap [particle=\(p_{2}\)],
            b -- bp [particle=\(p_{3}\)],
            d -- dp [particle=\(p_{1}\)],
            c -- cp [particle=\(p_{4}\)],
        },
    };
    &
    \begin{tikzpicture}[baseline={(current bounding box.center)}]
    \begin{feynman}
        \diagram [vertical'=a to b] {
            {   [edges={draw=none}]
                a -- b [label=0:\(\mu_{3}\)]
                -- c [label=-180:\(\mu_{4}\)]
                -- d [label=-180:\(\mu_{1}\)]
                -- a [label=0:\(\mu_{2}\)],
            },
            {   [edges={photon}]
                a -- ap [particle=\(p_{2}\)],
                b -- bp [particle=\(p_{3}\)],
                d -- dp [particle=\(p_{1}\)],
                c -- cp [particle=\(p_{4}\)],
            },
        };
        \diagram* {
            (a) -- [anti fermion] (b)
                -- [anti fermion] (d)
                -- [anti fermion] (c)
                -- (a),
        };
    \end{feynman}
    \end{tikzpicture}\\
    Diagram I & Diagram II & Diagram III
    \end{tabular}
    \end{center}
\end{document}

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.