2

I am trying to draw the diagram below on latex. I am not sure where to begin. I searched a lot but couldn't find any resolution. Here's what I faced:

It was easy to draw the line from left to right. But the rest had no slution. First I tried:

\begin{figure}[h]
        \centering
        \begin{tikzpicture}[baseline=(current bounding box.center)] 
            \begin{feynman}
                \vertex (x);
                \vertex[right=5cm of x] (y);
                \vertex[right=2.5cm of x] (a);
                \diagram*{
                (x) --[fermion] (a),
                (a) --[fermion] (y),
                a --[fermion, out=135, in=45, loop, min distance=5 cm] a,
                };
            \end{feynman}
        \end{tikzpicture}
        \caption{Feynman diagrams for two vertex $\phi^4$ interaction in real scalar field theory.} \label{fig:FD1}
    \end{figure}

But the result was not same. The loop is not elliptical as shown in the figure. It looked like the one in question here.

The next problem was to put color inside the loop. I found some draw options. But then the colored region has circular/square/elliptic shapes, which do not coincide with the loop. I am at a complete loss. Is there any possible solution on this?

FD

1 Answers1

4

The answer to the question that you linked is actually a pretty good starting point for how to draw the ellipse you want. I adapted my answer based on that answer, but I changed circle to ellipse and added a fill color of ellipseFillColor, and I set the text color to backgroundTextColor based on your screenshot. Furthermore, the tikzfeynman/dot at node b got covered by the fill of the ellipse, so I tacked on some TikZ code of my own at the end to ensure it was visible above the filled ellipse. This was my end result:

A Feynman diagram with a fermion traveling to the right, then a loop, then continuing to the right

\documentclass{standalone}
\usepackage[compat=1.1.0]{tikz-feynman}

\begin{document}

\definecolor{backgroundTextColor}{HTML}{8C6D0B} \definecolor{ellipseFillColor}{HTML}{ADDCF0}

\begin{tikzpicture} \color{backgroundTextColor} \makeatletter \begin{feynman} \diagram [horizontal=a to b, layered layout] { a [particle={$(p_n,\mathbf p)$}] -- [fermion] b
-- [fermion] c [particle={$(p_n,\mathbf p)$}] };

% Define a path to the center of the ellipse at point A1, and another point % to the top of the ellipse at point A2 \path (b) --++ (90:0.6) coordinate (A1) --++ (0,0.65) coordinate (A2);

% Next, draw the ellipse at point A, and color the inside \draw[ fill = ellipseFillColor, decoration={ markings, % This following part is borrowed from the tikzfeynman.keys.code.tex “with % reversed arrow” style, but I changed the fill of the arrow to match the % fill color of the line. Otherwise, the arrow would have been blue like % the fill of the ellipse. mark=at position 0.25 with {\node[ transform shape, xshift=0.5mm, rotate=180, fill=backgroundTextColor, inner sep=\tikzfeynman@arrow@size, draw=none, isosceles triangle ] {}; } }, postaction=decorate ] (A1) ellipse (0.4 and 0.6);

% Draw dot at node b \drawfill = backgroundTextColor circle (0.05) node[anchor=north] {$\lambda_1$};

% Place text above ellipse \draw(A2) node[anchor=south] {$(r_n, \mathbf r)$}; \end{feynman} \end{tikzpicture}

\end{document}

gz839918
  • 1,938
  • Thanks a lot for the help. This has solved almost all the issues. This was a very nice and complete answer. There are a couple of minor things I would like to ask as well. First of all, as in my original figure, you can see the vertices has names like (p_n,p). The comma is creating issues. Huge error appearing if I use the comma. The second issue is if I use PDFLatex, things get modified, the fefrmion lines get shortened. Do you think if I use vertices separately to define the a,b points, i can still use this in pdflatex? Lastly, now, if I am trying to write something else, the text has color. – Samapan Bhadury Feb 24 '24 at 14:03
  • 1
    @SamapanBhadury I'm happy this was useful! I've edited my answer to include the changes you want. To address your comment, (1) TikZ uses commas to see what keys are passed into a command, so it's mistaking your math for a new key. Surrounding the math with {} fixes this. (2) You can use pdflatex, but then it'll be up to you to manually make the diagram look pretty. The choice is yours. (3) \color changes the text color everywhere in its scope. Because I used \color within document, the color changed everywhere afterwards. Moving it inside tikzpicture fixes this. – gz839918 Feb 24 '24 at 17:23
  • 1
    Also, out of my own curiosity, what notation are you using? I'm especially interested in the squiggle beneath the letters p and r in your screenshot, and what they mean. I'm no particle physicist, but I'd love to learn more :) – gz839918 Feb 24 '24 at 17:26
  • Ah! it's simple 3-vector. I am not going to use it. Instead of arrow above, I wrote it as a squiggle below as a force of habit. Thanks again. – Samapan Bhadury Feb 25 '24 at 19:54