I exactly followed the Method 2 on
https://cp3.irmp.ucl.ac.be/projects/madgraph/wiki/FormFactors
Basically 3 modifications:
1) Modify vertices.py
========================================================================
V_43 = Vertex(name = 'V_43',
particles = [ P.Nt__tilde__, P.Nt, P.a ],
color = [ '1' ],
lorentz = [ L.FFV0 ],
couplings = {(0,0):C.GC_139})
========================================================================
by changing "L.FFV1" to "L.FFV0" since FFV1 is also used at other places but I just want to modify the vertex V_43.
2) Modify lorentz.py
========================================================================
FFV0 = Lorentz(name = 'FFV0',
spins = [ 2, 2, 3 ],
structure = 'FormFactor(P(-1,3)*P(-1,3)) * Gamma(3,2,1)')
========================================================================
by defining FFV0.
3) create functions.f in model directory
================================================
double complex function FormFactor(t)
double complex t, me, a, d
include input.inc ! include all model parameter
me = 0.000511
a = 111d0 / (Ztgt**(1d0/3d0)) / me
d = 0.164d0 / (Atgt*(2d0/3d0))
FormFactor = (a*a*t / (1d0 + a*a*t) / (1d0 + t/d))**2
return
end
================================================
After doing these, I run MG5 to do simulation and get the error messages:
========================================================================
Error detected in "generate_events "
write debug file /home/gesf/document/Study/Manuscript/Experiments/Beam_Dump/code/MG5_darkphoton/run_01_tag_1_debug.log
If you need help with this issue please contact us on https://answers.launchpad.net/mg5amcnlo
MadGraph5Error : A compilation Error occurs when trying to compile /home/gesf/document/Study/Manuscript/Experiments/Beam_Dump/code/MG5_darkphoton/SubProcesses/P1_emnt_emdpnt.
The compilation fails with the following output message:
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c driver.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c myamp.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c genps.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c unwgt.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c setcuts.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c get_color.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c cuts.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c cluster.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c reweight.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c initcluster.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c addmothers.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c setscales.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c dummy_fct.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c auto_dsig.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c auto_dsig1.f -I../../Source/
gfortran -O -w -fbounds-check -fPIC -ffixed-line-length-132 -w -c matrix1.f -I../../Source/
gfortran -o madevent driver.o myamp.o genps.o unwgt.o setcuts.o get_color.o cuts.o cluster.o reweight.o initcluster.o addmothers.o setscales.o idenparts.o dummy_fct.o auto_dsig.o auto_dsig1.o matrix1.o -L../../lib/ -ldhelas -ldsample -lmodel -lgeneric -lpdf -lcernlib -lbias -lstdc++
/usr/bin/ld: ../../lib//libdhelas.a(FFV0P0_3.o): in function `ffv0p0_3_':
FFV0P0_3.f:(.text+0x9e): undefined reference to `formfactor_'
collect2: error: ld returned 1 exit status
make: *** [makefile:44: madevent] Error 1
Please try to fix this compilations issue and retry.
Help might be found at https://answers.launchpad.net/mg5amcnlo.
If you think that this is a bug, you can report this at https://bugs.launchpad.net/mg5amcnlo
========================================================================
I did notice in this section of Method 2, "AAA" appeared. But I have not idea why it would appear here since it didn't appear in other places of this section.
See if you can give me a quick solution. Thanks.
Best, Shao-Feng