This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| latex:feynman_equation_file [2017/07/25 01:09] – created iwn | latex:feynman_equation_file [2023/02/04 15:46] (current) – iwn | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | This file show how you can typset a text with Feynman diagrams in equations. | + | This file show how you can typset a text with Feynman diagrams in equations. See [[latex: |
| - | {{ latex: | + | {{ latex:feynman: |
| <code latex feynman_equations.tex> | <code latex feynman_equations.tex> | ||
| + | % !TEX program = pdflatexmk | ||
| + | % !TEX parameter = -shell-escape | ||
| % Author: Izaak Neutelings (July 2017) | % Author: Izaak Neutelings (July 2017) | ||
| - | + | \documentclass[a4paper,12pt]{article} | |
| - | \documentclass[10pt,a4paper]{article} | + | |
| \usepackage[margin=2.4cm]{geometry} % margins | \usepackage[margin=2.4cm]{geometry} % margins | ||
| \usepackage{amsmath} | \usepackage{amsmath} | ||
| \usepackage{graphicx} | \usepackage{graphicx} | ||
| - | \usepackage{feynmp} | + | \usepackage{feynmp-auto} |
| - | + | ||
| - | % macro to compile Feynman graphs without extra scripts | + | |
| - | \DeclareGraphicsRule{*}{mps}{*}{} | + | |
| - | \makeatletter | + | |
| - | \def\endfmffile{ | + | |
| - | \fmfcmd{\p@rcent\space the end.^^J end.^^J endinput; | + | |
| - | \if@fmfio | + | |
| - | \immediate\closeout\@outfmf | + | |
| - | \fi | + | |
| - | %\ifnum\pdfshellescape=\@ne | + | |
| - | \ifnum\pdfshellescape> | + | |
| - | \immediate\write18{mpost \thefmffile} | + | |
| - | \fi} | + | |
| - | \makeatother | + | |
| \begin{document} | \begin{document} | ||
| - | |||
| - | |||
| \section{Typesetting equations with Feynman diagrams} | \section{Typesetting equations with Feynman diagrams} | ||
| - | This is an equation | + | This is an equation |
| \begin{equation}\label{eq: | \begin{equation}\label{eq: | ||
| \begin{fmffile}{higgs_mass_correction} | \begin{fmffile}{higgs_mass_correction} | ||
| Line 52: | Line 37: | ||
| % SUSY | % SUSY | ||
| - | One solution to Eq.~\eqref{eq: | + | To avoid finetuning in Eq.~\eqref{eq: |
| \begin{equation}\label{eq: | \begin{equation}\label{eq: | ||
| \begin{fmffile}{higgs_mass_correction_SUSY} | \begin{fmffile}{higgs_mass_correction_SUSY} | ||
| Line 83: | Line 68: | ||
| % VLQ | % VLQ | ||
| - | Yet another solution are vector-like quarks (VLQs): \vspace{5mm} | + | Yet another solution |
| \begin{equation}\label{eq: | \begin{equation}\label{eq: | ||
| \begin{fmffile}{higgs_mass_correction_VLQ} | \begin{fmffile}{higgs_mass_correction_VLQ} | ||
| Line 124: | Line 109: | ||
| \end{equation} | \end{equation} | ||
| - | Notice that in the code, the stop $\widetilde{\text{t}}$ and VLQ top partner T labels were stick out, so an extra \verb|\vspace{5mm}| was needed above the equation.\\ | + | Notice that in the code, \verb|\,| was used to add extra space between |
| - | Also note that the \verb|align| might not compile. Instead, use the \verb|aligned| | + | Because |
| - | \begin{equation}\label{eq: | + | |
| + | Equations with \verb|feymp| diagrams | ||
| + | \begin{equation} | ||
| \begin{aligned} | \begin{aligned} | ||
| \Delta m_H^2 \,\, &= | \Delta m_H^2 \,\, &= | ||
| Line 142: | Line 129: | ||
| \end{fmfgraph*}} | \end{fmfgraph*}} | ||
| \,\, + \,\,\ldots | \,\, + \,\,\ldots | ||
| - | \end{fmffile}\\ | + | \end{fmffile}\\ |
| & | & | ||
| \end{aligned} | \end{aligned} | ||
| \end{equation} | \end{equation} | ||
| + | Another tip: use \verb|\\[10pt]| instead of just \verb|\\| at the end of a line in the \verb|aligned| environment to add extra vertical white space between two lines of equations. | ||
| \end{document} | \end{document} | ||
| </ | </ | ||