~maddevelopers/mg5amcnlo/2.9.4

« back to all changes in this revision

Viewing changes to aloha/aloha_object.py

pass to v2.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
################################################################################
2
2
#
3
 
# Copyright (c) 2010 The MadGraph Development team and Contributors
 
3
# Copyright (c) 2010 The MadGraph5_aMC@NLO Development team and Contributors
4
4
#
5
 
# This file is a part of the MadGraph 5 project, an application which 
 
5
# This file is a part of the MadGraph5_aMC@NLO project, an application which 
6
6
# automatically generates Feynman diagrams and matrix elements for arbitrary
7
7
# high-energy processes in the Standard Model and beyond.
8
8
#
9
 
# It is subject to the MadGraph license which should accompany this 
 
9
# It is subject to the MadGraph5_aMC@NLO license which should accompany this 
10
10
# distribution.
11
11
#
12
 
# For more information, please visit: http://madgraph.phys.ucl.ac.be
 
12
# For more information, visit madgraph.phys.ucl.ac.be and amcatnlo.web.cern.ch
13
13
#
14
14
################################################################################
15
15
##   Diagram of Class
243
243
    @classmethod
244
244
    def get_unique_name(self, particle):
245
245
        return '_W%s' % particle
 
246
 
 
247
#===============================================================================
 
248
# Param
 
249
#===============================================================================
 
250
class L_Param(aloha_lib.LorentzObject):
 
251
    """ Object for a Model Parameter """
 
252
 
 
253
    
 
254
    def __init__(self, Lname, name):
 
255
        self.varname = name
 
256
        aloha_lib.LorentzObject.__init__(self, name, [], [])
 
257
        
 
258
    def create_representation(self):
 
259
        param = aloha_lib.Variable( self.varname, aloha_lib.ExtVariable)
 
260
 
 
261
        self.representation= aloha_lib.LorentzObjectRepresentation(
 
262
                            param, [], [])
 
263
 
 
264
class Param(aloha_lib.FactoryLorentz):
 
265
    
 
266
    object_class = L_Param
 
267
    
 
268
    @classmethod
 
269
    def get_unique_name(self, name):
 
270
        if name == 'Pi':
 
271
            KERNEL.has_pi = True
 
272
        return 'Param_%s' % name
 
273
 
246
274
#===============================================================================
247
275
# Scalar
248
276
#===============================================================================
946
974
 
947
975
VectorPropagatorMassless= lambda l1, l2, part: complex(0,-1) * Metric(l1, l2)
948
976
 
 
977
 
949
978
Spin3halfPropagatorin =  lambda mu, nu, s1, s2, part: (\
950
979
    -1/3 * (Gamma(mu,s1,-2) + Identity(s1, -2) *  P(mu, part) * Mass(part) * OverMass2(part))* \
951
980
    (PSlash(-2,-3, part) - Identity(-2,-3) * Mass(part)) * \