Package madgraph :: Package core :: Module helas_objects :: Class HelasWavefunction
[hide private]
[frames] | no frames]

Class HelasWavefunction

source code

            object --+        
                     |        
                  dict --+    
                         |    
base_objects.PhysicsObject --+
                             |
                            HelasWavefunction

HelasWavefunction object, has the information necessary for writing a call to a HELAS wavefunction routine: the PDG number, all relevant particle information, a list of mother wavefunctions, interaction id, all relevant interaction information, fermion flow state, wavefunction number

Nested Classes [hide private]

Inherited from base_objects.PhysicsObject: PhysicsObjectError

Instance Methods [hide private]
 
default_setup(self)
Default values for all properties
source code
new empty dictionary

__init__(self, *arguments)
Allow generating a HelasWavefunction from a Leg
source code
 
filter(self, name, value)
Filter for valid wavefunction property values.
source code
D[k] if k in D, else d
get(self, name)
When calling any property related to the particle, automatically call the corresponding property of the particle.
source code
 
set(self, *arguments)
When setting interaction_id, if model is given (in tuple), set all other interaction properties.
source code
 
get_sorted_keys(self)
Return particle property names as a nicely sorted list.
source code
 
flip_part_antipart(self)
Flip between particle and antiparticle.
source code
 
is_fermion(self) source code
 
is_boson(self) source code
 
is_majorana(self) source code
 
to_array(self)
Generate an array with the information needed to uniquely determine if a wavefunction has been used before: interaction id and mother wavefunction numbers.
source code
 
get_pdg_code(self)
Generate the corresponding pdg_code for an outgoing particle, taking into account fermion flow, for mother wavefunctions
source code
 
get_anti_pdg_code(self)
Generate the corresponding pdg_code for an incoming particle, taking into account fermion flow, for mother wavefunctions
source code
 
set_scalar_coupling_sign(self, model)
Check if we need to add a minus sign due to non-identical bosons in HVS type couplings
source code
 
set_octet_majorana_coupling_sign(self)
For octet Majorana fermions, need an extra minus sign in the FVI (and FSI?) wavefunction in UFO models.
source code
 
set_state_and_particle(self, model)
Set incoming/outgoing state according to mother states and Lorentz structure of the interaction, and set PDG code according to the particles in the interaction
source code
 
check_and_fix_fermion_flow(self, wavefunctions, diagram_wavefunctions, external_wavefunctions, wf_number)
Check for clashing fermion flow (N(incoming) != N(outgoing)) in mothers.
source code
 
check_majorana_and_flip_flow(self, found_majorana, wavefunctions, diagram_wavefunctions, external_wavefunctions, wf_number, force_flip_flow=False, number_to_wavefunctions=[])
Recursive function.
source code
 
get_fermion_order(self)
Recursive function to get a list of fermion numbers corresponding to the order of fermions along fermion lines connected to this wavefunction, in the form [n1,n2,...] for a boson, and [N,[n1,n2,...]] for a fermion line
source code
 
needs_hermitian_conjugate(self)
Returns true if any of the mothers have negative fermionflow
source code
 
get_with_flow(self, name)
Generate the is_part and state needed for writing out wavefunctions, taking into account the fermion flow
source code
 
get_spin_state_number(self)
Returns the number corresponding to the spin state, with a minus sign for incoming fermions
source code
 
find_mother_fermion(self)
Return the fermion mother which is fermion flow connected to this fermion
source code
 
find_outgoing_number(self)
Return the position of the resulting particles in the interactions
source code
 
get_call_key(self)
Generate the (spin, number, C-state) tuple used as key for the helas call dictionaries in HelasModel
source code
 
get_base_vertices(self, wf_dict, vx_list=[], optimization=1)
Recursive method to get a base_objects.VertexList corresponding to this wavefunction and its mothers.
source code
 
get_base_vertex(self, wf_dict, vx_list=[], optimization=1)
Get a base_objects.Vertex corresponding to this wavefunction.
source code
 
get_color_indices(self)
Recursive method to get the color indices corresponding to this wavefunction and its mothers.
source code
 
get_s_and_t_channels(self, ninitial, mother_leg)
Returns two lists of vertices corresponding to the s- and t-channels that can be traced from this wavefunction, ordered from the outermost s-channel and in/down towards the highest number initial state leg.
source code
 
get_conjugate_index(self)
Return the index of the particle that should be conjugated.
source code
 
get_vertex_leg_numbers(self)
Get a list of the number of legs in vertices in this diagram
source code
 
__eq__(self, other)
Overloading the equality operator, to make comparison easy when checking if wavefunction is already written, or when checking for identical processes.
source code
 
__ne__(self, other)
Overloading the nonequality operator, to make comparison easy
source code

Inherited from base_objects.PhysicsObject: __getitem__, __repr__, __str__, is_valid_prop

Inherited from dict: __cmp__, __contains__, __delitem__, __ge__, __getattribute__, __gt__, __iter__, __le__, __len__, __lt__, __new__, __setitem__, __sizeof__, clear, copy, fromkeys, has_key, items, iteritems, iterkeys, itervalues, keys, pop, popitem, setdefault, update, values

Inherited from object: __delattr__, __format__, __reduce__, __reduce_ex__, __setattr__, __subclasshook__

Class Variables [hide private]

Inherited from dict: __hash__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

default_setup(self)

source code 

Default values for all properties

Overrides: base_objects.PhysicsObject.default_setup

__init__(self, *arguments)
(Constructor)

source code 

Allow generating a HelasWavefunction from a Leg

Returns:
new empty dictionary

Overrides: object.__init__

filter(self, name, value)

source code 

Filter for valid wavefunction property values.

Overrides: base_objects.PhysicsObject.filter

get(self, name)

source code 

When calling any property related to the particle, automatically call the corresponding property of the particle.

Returns: D[k] if k in D, else d
Overrides: dict.get

set(self, *arguments)

source code 

When setting interaction_id, if model is given (in tuple), set all other interaction properties. When setting pdg_code, if model is given, set all other particle properties.

Overrides: base_objects.PhysicsObject.set

get_sorted_keys(self)

source code 

Return particle property names as a nicely sorted list.

Overrides: base_objects.PhysicsObject.get_sorted_keys

check_and_fix_fermion_flow(self, wavefunctions, diagram_wavefunctions, external_wavefunctions, wf_number)

source code 

Check for clashing fermion flow (N(incoming) != N(outgoing)) in mothers. This can happen when there is a Majorana particle in the diagram, which can flip the fermion flow. This is detected either by a wavefunctions or an amplitude, with 2 fermion mothers with same state.

In this case, we need to follow the fermion lines of the mother wavefunctions until we find the outermost Majorana fermion. For all fermions along the line up to (but not including) the Majorana fermion, we need to flip incoming <-> outgoing and particle id. For all fermions after the Majorana fermion, we need to flip the fermionflow property (1 <-> -1).

The reason for this is that in the Helas calls, we need to keep track of where the actual fermion flow clash happens (i.e., at the outermost Majorana), as well as having the correct fermion flow for all particles along the fermion line.

This is done by the mothers using HelasWavefunctionList.check_and_fix_fermion_flow, which in turn calls the recursive function check_majorana_and_flip_flow to trace the fermion lines.

check_majorana_and_flip_flow(self, found_majorana, wavefunctions, diagram_wavefunctions, external_wavefunctions, wf_number, force_flip_flow=False, number_to_wavefunctions=[])

source code 
Recursive function. Check for Majorana fermion. If found,
continue down to external leg, then flip all the fermion flows
on the way back up, in the correct way:
Only flip fermionflow after the last Majorana fermion; for
wavefunctions before the last Majorana fermion, instead flip
particle identities and state. Return the new (or old)
wavefunction, and the present wavefunction number.

Arguments:
  found_majorana: boolean
  wavefunctions: HelasWavefunctionList with previously
                 defined wavefunctions
  diagram_wavefunctions: HelasWavefunctionList with the wavefunctions
                 already defined in this diagram
  external_wavefunctions: dictionary from legnumber to external wf
  wf_number: The present wavefunction number

get_s_and_t_channels(self, ninitial, mother_leg)

source code 

Returns two lists of vertices corresponding to the s- and t-channels that can be traced from this wavefunction, ordered from the outermost s-channel and in/down towards the highest number initial state leg. mother_leg corresponds to self but with correct leg number = min(final state mothers).

__eq__(self, other)
(Equality operator)

source code 

Overloading the equality operator, to make comparison easy when checking if wavefunction is already written, or when checking for identical processes. Note that the number for this wavefunction, the pdg code, and the interaction id are irrelevant, while the numbers for the mothers are important.

Overrides: dict.__eq__

__ne__(self, other)

source code 

Overloading the nonequality operator, to make comparison easy

Overrides: dict.__ne__