laura is hosted by Hepforge, IPPP Durham
Laura++  v3r5
A maximum likelihood fitting package for performing Dalitz-plot analysis.
LauPolNR.cc
Go to the documentation of this file.
1 
2 /*
3 Copyright 2014 University of Warwick
4 
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8 
9  http://www.apache.org/licenses/LICENSE-2.0
10 
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16 */
17 
18 /*
19 Laura++ package authors:
20 John Back
21 Paul Harrison
22 Thomas Latham
23 */
24 
29 #include <iostream>
30 
31 #include "TMath.h"
32 
33 #include "LauPolNR.hh"
34 #include "LauDaughters.hh"
35 
37 
38 
39 LauPolNR::LauPolNR(LauResonanceInfo* resInfo, const Int_t resPairAmpInt, const LauDaughters* daughters) :
40  LauAbsResonance(resInfo, resPairAmpInt, daughters),
41  omega_(0.0),
42  order_(0)
43 {
44 }
45 
47 {
48 }
49 
51 {
52  const LauDaughters* daughters = this->getDaughters();
53  Int_t resPairAmpInt = this->getPairInt();
54  if ( daughters->gotSymmetricalDP() && resPairAmpInt != 3 ) {
55  std::cerr << "WARNING in LauPolNR::initialise : Dalitz plot is symmetric - this lineshape is not appropriate." << std::endl;
56  }
57 
58  // Make the spin term purely the Legendre polynomial of the cos(helicity angle)
60 
61  Double_t omega = 0.5*(daughters->getMassParent()+(1.0/3.0)*(daughters->getMassDaug1()+daughters->getMassDaug2()+daughters->getMassDaug3()));
62  this->setOmega( omega );
63 
64  TString name = this->getResonanceName();
65  if (name.EndsWith("0",TString::kExact)){
66  order_ = 0;
67  }
68  else if (name.EndsWith("1",TString::kExact)){
69  order_ = 1;
70  }
71  else if (name.EndsWith("2",TString::kExact)){
72  order_ = 2;
73  }
74  else if (name.EndsWith("3",TString::kExact)){
75  order_ = 3;
76  }
77  else{
78  std::cerr << "ERROR in LauPolNR::initialise : Resonance order unknown (known orders : 0, 1, 2 and 3)" << std::endl;
79  std::cerr << " : Defaulting to 0." << std::endl;
80  }
81 }
82 
83 LauComplex LauPolNR::resAmp(Double_t mass, Double_t spinTerm)
84 {
85  Double_t magnitude( spinTerm );
86 
87  Double_t massDiff = mass - omega_;
88  for ( UInt_t i(0); i < order_; ++i ) {
89  magnitude *= massDiff;
90  }
91 
92  LauComplex resAmplitude(magnitude, 0.0);
93 
94  return resAmplitude;
95 }
96 
virtual void initialise()
Initialise the model.
Definition: LauPolNR.cc:50
Double_t getMassParent() const
Get mass of the parent particle.
Double_t omega_
The offset parameter.
Definition: LauPolNR.hh:98
const TString & getResonanceName() const
Get the name of the resonance.
ClassImp(LauAbsCoeffSet)
Class for defining the properties of a resonant particle.
const TString & name() const
The parameter name.
Class that defines the particular 3-body decay under study.
Definition: LauDaughters.hh:47
File containing declaration of LauDaughters class.
const LauDaughters * getDaughters() const
Access the daughters object.
Double_t getMassDaug2() const
Get mass of second daughter particle.
Int_t getPairInt() const
Get the integer to identify which DP axis the resonance belongs to.
virtual void setOmega(const Double_t omega)
Set the parameter omega, the offset parameter.
Definition: LauPolNR.hh:74
Bool_t gotSymmetricalDP() const
Is Dalitz plot symmetric, i.e. 2 identical particles.
Definition: LauDaughters.hh:80
Class for defining the terms of Babar nonresonant model.
Definition: LauPolNR.hh:47
Abstract class for defining type for resonance amplitude models (Breit-Wigner, Flatte etc...
Double_t getMassDaug1() const
Get mass of first daughter particle.
UInt_t order_
The order in the mass.
Definition: LauPolNR.hh:101
Class for defining a complex number.
Definition: LauComplex.hh:61
void setSpinType(const LauSpinType spinType)
Set the spin formalism to be used.
File containing declaration of LauPolNR class.
virtual LauComplex resAmp(Double_t mass, Double_t spinTerm)
Complex resonant amplitude.
Definition: LauPolNR.cc:83
Double_t getMassDaug3() const
Get mass of third daughter particle.
virtual ~LauPolNR()
Destructor.
Definition: LauPolNR.cc:46