FeynMF
The package FeynMF provides a way to draw complex Feynman diagrams in LaTeX. However, it is sometimes necessary to have more line and vertex styles available. Therefore an extension of Thorsten Ohl's FeynMF package is available under
http://github.com/philikon/feynmf
or
https://github.com/Expander/feynmf
which provides an additional vertex style \fmfct
to
draw counter term diagrams and two new line
styles gaugino
and gluino
to draw
propagators used in Supersymmetry.
Some examples
Diagram | LaTeX source code |
---|---|
\begin{fmffile}{fmftempl} \fmfset{wiggly_len}{6mm} \begin{fmfgraph}(30,30) \fmfleft{l} \fmf{photon}{l,i} \fmf{fermion}{f1,i,f2} \fmfright{f1,f2} \fmfct{i} \end{fmfgraph} \end{fmffile} |
|
\begin{fmffile}{fmftempl} \fmfset{wiggly_len}{6mm} \begin{fmfgraph}(30,30) \fmfleft{l} \fmf{gaugino}{l,r} \fmfright{r} \end{fmfgraph} \end{fmffile} |
|
\begin{fmffile}{fmftempl} \fmfset{wiggly_len}{6mm} \begin{fmfgraph}(30,30) \fmfleft{l} \fmf{gluino}{l,r} \fmfright{r} \end{fmfgraph} \end{fmffile} |
Basic usage
To compile the above examples with LaTeX, MetaPost
is needed. At first create a document template.tex
,
which for example could look like
\documentclass{article} \usepackage{feynmp} \unitlength=1mm \begin{document} \begin{fmffile}{fmftempl} \fmfset{wiggly_len}{6mm} \begin{fmfgraph}(30,30) \fmfleft{l} \fmf{photon}{l,i} \fmf{fermion}{f1,i,f2} \fmfright{f1,f2} \fmfct{i} \end{fmfgraph} \begin{fmfgraph}(30,30) \fmfleft{l} \fmf{gaugino}{l,r} \fmfright{r} \end{fmfgraph} \begin{fmfgraph}(30,30) \fmfleft{l} \fmf{gluino}{l,r} \fmfright{r} \end{fmfgraph} \end{fmffile} \end{document}
Make sure that the files feynmp.sty and feynmp.mp are in the directory of execution. Running the commands
$ latex template.tex $ mpost fmftempl.mp $ latex template.tex $ dvipdfm template.dvi
yields a PDF output file template.pdf
that contains
the diagrams.
A complete example using FeynMP and pdfLaTeX
It is possible to use FeynMP with pdfLaTeX/ pdfTeX by adding the following header line to your document:
\usepackage{graphicx} \DeclareGraphicsRule{*}{mps}{*}{}
A full example, which creates some Feynman diagrams with the above mentioned new features (using FeynMP and pdfLaTeX) can be downloaded here:
feynmp-pdflatex.tar.gz (19 KB)
To compile the example, execute the following commands
$ tar xf feynmp-pdflatex.tar.gz $ cd feynmp-pdflatex/ $ make $ make