ThePEG  1.8.0
MixedParticleData.h
1 // -*- C++ -*-
2 #ifndef THEPEG_MixedParticleData_H
3 #define THEPEG_MixedParticleData_H
4 //
5 // This is the declaration of the MixedParticleData class.
6 //
7 
8 #include "ParticleData.h"
9 #include "MixedParticleData.fh"
10 
11 namespace ThePEG {
12 
51 
52 public:
53 
58  _deltagamma(0.*GeV), _pqmag(1.), _pqphase(0.),
59  _pq(1.,0.), _zmag(0.), _zphase(0.), _z(0.), _x(0.), _y(0.),
60  _prob(make_pair(1.,0.))
61  {}
62 
69  static PDPtr Create(long newId, string newPDGName);
70 
74  static PDPair Create(long newId, string newPDGName, string newAntiPDGName);
76 
77 public:
78 
86  Energy deltaM() const {return _deltam;}
87 
91  Energy deltaGamma() const {return _deltagamma;}
92 
96  Complex pq() const {return _pq;}
97 
101  Complex z() const {return _z;}
102 
106  double x() const {return _x;}
107 
111  double y() const {return _y;}
112 
116  pair<double,double> prob() const {return _prob;}
117 
122  pair<bool,Length> generateLifeTime() const;
123 
127  pair<Complex,Complex> mixingAmplitudes(Length,bool) const;
128 
129 public:
130 
137  void persistentOutput(PersistentOStream & os) const;
138 
144  void persistentInput(PersistentIStream & is, int version);
146 
153  static void Init();
154 
155 protected:
156 
161  MixedParticleData(long newId, string newPDGName);
162 
166  virtual PDPtr pdclone() const;
167 
168 protected:
169 
177  virtual void doinit() throw(InitException);
179 
180 private:
181 
185  void setDeltaM(Energy);
186 
190  void setDeltaGamma(Energy);
191 
195  void setPQMagnitude(double);
196 
200  void setPQPhase(double);
201 
205  void setZMagnitude(double);
206 
210  void setZPhase(double);
211 
212 private:
213 
219 
224  MixedParticleData & operator=(const MixedParticleData &);
225 
226 private:
227 
235  Energy _deltam;
236 
240  Energy _deltagamma;
241 
245  double _pqmag;
246 
250  double _pqphase;
251 
256 
260  double _zmag;
261 
265  double _zphase;
266 
271 
275  double _x;
276 
280  double _y;
281 
285  pair<double,double> _prob;
287 
288 };
289 
290 }
291 
292 #include "ThePEG/Utilities/ClassTraits.h"
293 
294 namespace ThePEG {
295 
300 template <>
301 struct BaseClassTrait<MixedParticleData,1> {
303  typedef ParticleData NthBase;
304 };
305 
308 template <>
309 struct ClassTraits<MixedParticleData>
310  : public ClassTraitsBase<MixedParticleData> {
312  static string className() { return "ThePEG::MixedParticleData"; }
313 };
314 
317 }
318 
319 #endif /* THEPEG_MixedParticleData_H */