-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathmathjax.html
50 lines (44 loc) · 1.92 KB
/
mathjax.html
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
<!DOCTYPE html>
<html lang="en-us">
<head>
<meta charset="utf-8"/>
<title>jQuery.Feyn with MathJax</title>
<meta name="keywords" content="Feynman diagrams, jQuery, SVG, MathJax"/>
<meta name="description" content="An extension package allows you to draw Feynman diagrams with SVG using the standard jQuery syntax."/>
<meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=0.25,user-scalable=yes"/>
<link rel="icon" type="image/png" href="favicon.png"/>
<script src="js/jquery-2.1.0.min.js"></script>
<script src="js/jquery.feyn-1.0.1.min.js"></script>
<script src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_SVG"></script>
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
jax: ['input/TeX','output/HTML-CSS'],
tex2jax: {
inlineMath: [['$', '$'], ['\\(', '\\)']],
displayMath: [['$$', '$$'], ['\\[', '\\]']],
processEscapes: true
}
});
</script>
<script>
$(document).ready(function() {
$('#container').feyn({
description: 'Four-gluon vertex for QCD',
width: 480,
height: 140,
incoming: {i1: '40,120', i2: '140,120', i3: '40,20', i4: '140,20'},
vertex: {v1: '90,70'},
gluon: {line: 'v1-i1,v1-i2,v1-i3,v1-i4'},
node: {show: 'v', type: 'dot', fill: 'black', radius: 2},
label: {t1: ['15,110', '$c,\\rho$', 30], t2: ['140,110', '$d,\\sigma$', 30],
t3: ['15,10', '$b,\\nu$', 30], t4: ['140,10', '$a,\\mu$', 30],
t5: ['190,15', '$=-ig^2\\big[\\!f^{abe}f^{cde}(\\eta^{\\mu\\rho}\\eta^{\\nu\\sigma}-\\eta^{\\mu\\sigma}\\eta^{\\nu\\rho})\\\\\\qquad+f^{ace}f^{bde}(\\eta^{\\mu\\nu}\\eta^{\\rho\\sigma}-\\eta^{\\mu\\sigma}\\eta^{\\nu\\rho})\\\\\\qquad+f^{ade}f^{bce}(\\eta^{\\mu\\nu}\\eta^{\\rho\\sigma}-\\eta^{\\mu\\rho}\\eta^{\\nu\\sigma})\\big]$', 290, 100]},
mathjax: true
});
});
</script>
</head>
<body>
<div id="container"><!-- Insert Feynman diagram here --></div>
</body>
</html>