herwig is hosted by Hepforge, IPPP Durham
Herwig 7.3.0
SU2Helper.h
1// -*- C++ -*-
2//
3// SU2Helper.h is a part of Herwig - A multi-purpose Monte Carlo event generator
4// Copyright (C) 2002-2019 The Herwig Collaboration
5//
6// Herwig is licenced under version 3 of the GPL, see COPYING for details.
7// Please respect the MCnet academic guidelines, see GUIDELINES for details.
8//
9#ifndef HERWIG_SU2Helper_H
10#define HERWIG_SU2Helper_H
11
12#include "ThePEG/PDT/ParticleData.h"
13
14namespace Herwig {
15
16using namespace ThePEG;
17
27struct SU2Helper {
28
34 static bool isInSU2Doublet(tcPDPtr p) {
35 return abs(p->id()) < 9 || (abs(p->id()) >= 11 && abs(p->id()) < 19);
36 }
37
43 static bool isSU2Up(tcPDPtr p) { return abs(p->id())%2==0 && isInSU2Doublet(p); }
44
50 static bool isSU2Down(tcPDPtr p) { return abs(p->id())%2!=0 && isInSU2Doublet(p); }
51
58 static tcPDPtr SU2CC(tcPDPtr p, int familyShift = 0);
59
63 static int family(tcPDPtr p);
64
65};
66
67
68}
69
70#endif // HERWIG_SU2Helper_H
-*- C++ -*-
ThePEG::Ptr< ParticleData >::transient_const_pointer tcPDPtr
Helpers for book keeping in electroweak processes.
Definition: SU2Helper.h:27
static int family(tcPDPtr p)
Return the family.
static tcPDPtr SU2CC(tcPDPtr p, int familyShift=0)
Return the conjugate component in the same weak SU(2) doublet, or a null pointer if the left-(right-)...
static bool isSU2Up(tcPDPtr p)
Return true, if the left-(right-)handed projection of this particle (antiparticle) is the up componen...
Definition: SU2Helper.h:43
static bool isInSU2Doublet(tcPDPtr p)
Return true, if the left-(right-)handed projection of this particle (antiparticle) belongs to a weak ...
Definition: SU2Helper.h:34
static bool isSU2Down(tcPDPtr p)
Return true, if the left-(right-)handed projection of this particle (antiparticle) is the down compon...
Definition: SU2Helper.h:50