Changeset View
Changeset View
Standalone View
Standalone View
src/LauKMatrixProdSVP.cc
Show All 27 Lines | |||||
#include "LauKMatrixProdSVP.hh" | #include "LauKMatrixProdSVP.hh" | ||||
#include "LauKMatrixPropagator.hh" | #include "LauKMatrixPropagator.hh" | ||||
#include <iostream> | #include <iostream> | ||||
ClassImp(LauKMatrixProdSVP) | ClassImp(LauKMatrixProdSVP) | ||||
LauKMatrixProdSVP::LauKMatrixProdSVP(const TString& SVPName, Int_t channelIndex, Int_t resPairAmpInt, | LauKMatrixProdSVP::LauKMatrixProdSVP( const TString& SVPName, Int_t channelIndex, Int_t resPairAmpInt, | ||||
LauKMatrixPropagator* propagator, const LauDaughters* daughters, | LauKMatrixPropagator* propagator, const LauDaughters* daughters, | ||||
Bool_t useProdAdler) : | Bool_t useProdAdler) : | ||||
LauAbsResonance(SVPName, resPairAmpInt, daughters), | LauAbsResonance( SVPName, resPairAmpInt, daughters, propagator->getL(propagator->getIndex()) ), | ||||
thePropagator_(propagator), | thePropagator_(propagator), | ||||
channelIndex_(channelIndex - 1), // channelIndex goes from 1 to nChannels. | channelIndex_(channelIndex - 1), // channelIndex goes from 1 to nChannels. | ||||
useProdAdler_(useProdAdler) | useProdAdler_(useProdAdler) | ||||
{ | { | ||||
// Constructor | // Constructor | ||||
if (useProdAdler_) { | if (useProdAdler_) { | ||||
std::cout<<"Creating K matrix production SVP "<<SVPName<<" with channelIndex = " | std::cout <<"Creating K matrix production SVP "<<SVPName<<" with channelIndex = " | ||||
<<channelIndex<<" with s-dependent production Adler zero term"<<std::endl; | <<channelIndex<<" with s-dependent production Adler zero term"<<std::endl; | ||||
} else { | } else { | ||||
std::cout<<"Creating K matrix production SVP "<<SVPName<<" with channelIndex = " | std::cout <<"Creating K matrix production SVP "<<SVPName<<" with channelIndex = " | ||||
<<channelIndex<<" with production Adler zero factor = 1"<<std::endl; | <<channelIndex<<" with production Adler zero factor = 1"<<std::endl; | ||||
} | } | ||||
} | } | ||||
LauKMatrixProdSVP::~LauKMatrixProdSVP() | LauKMatrixProdSVP::~LauKMatrixProdSVP() | ||||
{ | { | ||||
// Destructor | // Destructor | ||||
} | } | ||||
LauComplex LauKMatrixProdSVP::resAmp(Double_t mass, Double_t spinTerm) | LauComplex LauKMatrixProdSVP::resAmp(const Double_t mass, const Double_t spinTerm) | ||||
{ | |||||
std::cerr << "ERROR in LauKMatrixProdSVP::resAmp : This method shouldn't get called." << std::endl; | |||||
std::cerr << " Returning zero amplitude for mass = " << mass << " and spinTerm = " << spinTerm << "." << std::endl; | |||||
return LauComplex(0.0, 0.0); | |||||
} | |||||
LauComplex LauKMatrixProdSVP::amplitude(const LauKinematics* kinematics) | |||||
{ | { | ||||
// Calculate the amplitude for the K-matrix production pole. | // Calculate the amplitude for the K-matrix production pole. | ||||
// First, make sure the K-matrix propagator is up-to-date for | // First, make sure the K-matrix propagator is up-to-date for | ||||
// the given centre-of-mass squared value ("s") from the kinematics. | // the given centre-of-mass squared value ("s") from the kinematics. | ||||
LauComplex amp(0.0, 0.0); | LauComplex amp(0.0, 0.0); | ||||
if (thePropagator_ == 0) { | if (thePropagator_ == 0) { | ||||
std::cerr << "ERROR in LauKMatrixProdSVP::amplitude : The propagator is null" << std::endl; | std::cerr << "ERROR in LauKMatrixProdSVP::amplitude : The propagator is null" << std::endl; | ||||
return amp; | return amp; | ||||
} | } | ||||
thePropagator_->updatePropagator(kinematics); | // Get barrier factors ('resonance' factor is already accounted for internally via propagator 'Gamma' matrix) | ||||
Double_t fFactorB(1.0); | |||||
const Int_t resSpin = this->getSpin(); | |||||
const Double_t pstar = this->getPstar(); | |||||
if ( resSpin > 0 ) { | |||||
const LauBlattWeisskopfFactor* parBWFactor = this->getParBWFactor(); | |||||
if ( parBWFactor != nullptr ) { | |||||
switch ( parBWFactor->getRestFrame() ) { | |||||
case LauBlattWeisskopfFactor::ResonanceFrame: | |||||
fFactorB = parBWFactor->calcFormFactor(this->getP()); | |||||
break; | |||||
case LauBlattWeisskopfFactor::ParentFrame: | |||||
fFactorB = parBWFactor->calcFormFactor(pstar); | |||||
break; | |||||
case LauBlattWeisskopfFactor::Covariant: | |||||
{ | |||||
Double_t covFactor = this->getCovFactor(); | |||||
if ( resSpin > 2 ) { | |||||
covFactor = TMath::Power( covFactor, 1.0/resSpin ); | |||||
} else if ( resSpin == 2 ) { | |||||
covFactor = TMath::Sqrt( covFactor ); | |||||
} | |||||
fFactorB = parBWFactor->calcFormFactor(pstar*covFactor); | |||||
break; | |||||
} | |||||
} | |||||
} | |||||
} | |||||
thePropagator_->updatePropagator(mass*mass); | |||||
Double_t SVPTerm = thePropagator_->getProdSVPTerm(); | Double_t SVPTerm = thePropagator_->getProdSVPTerm(); | ||||
amp = thePropagator_->getPropTerm(channelIndex_); | amp = thePropagator_->getPropTerm(channelIndex_); | ||||
// Include Adler zero factor if requested | // Include Adler zero factor if requested | ||||
Double_t adlerZero(1.0); | Double_t adlerZero(1.0); | ||||
if (useProdAdler_) {adlerZero = thePropagator_->getAdlerZero();} | if (useProdAdler_) {adlerZero = thePropagator_->getAdlerZero();} | ||||
amp.rescale(SVPTerm*adlerZero); | amp.rescale(SVPTerm*adlerZero); | ||||
// Scale by the spin term | |||||
Double_t scale = spinTerm; | |||||
// Include Blatt-Weisskopf barrier factor for parent | |||||
scale *= fFactorB; | |||||
amp.rescale(scale); | |||||
return amp; | return amp; | ||||
} | } | ||||
const std::vector<LauParameter*>& LauKMatrixProdSVP::getFloatingParameters() | const std::vector<LauParameter*>& LauKMatrixProdSVP::getFloatingParameters() | ||||
{ | { | ||||
this->clearFloatingParameters(); | this->clearFloatingParameters(); | ||||
Int_t nChannels = thePropagator_->getNChannels(); | Int_t nChannels = thePropagator_->getNChannels(); | ||||
for (int jChannel = 0 ; jChannel < nChannels ; jChannel++) | for (int jChannel = 0 ; jChannel < nChannels ; jChannel++) | ||||
{ | { | ||||
LauParameter& par_f_ = thePropagator_->getScatteringParameter(channelIndex_, jChannel); | LauParameter& par_f_ = thePropagator_->getScatteringParameter(channelIndex_, jChannel); | ||||
if ( !par_f_.fixed() ) | if ( !par_f_.fixed() ) | ||||
{ | { | ||||
this->addFloatingParameter( &par_f_ ); | this->addFloatingParameter( &par_f_ ); | ||||
} | } | ||||
} | } | ||||
LauParameter& par_mSq0_ = thePropagator_->getmSq0(); | LauParameter& par_mSq0_ = thePropagator_->getmSq0(); | ||||
if ( !par_mSq0_.fixed() ) | if ( !par_mSq0_.fixed() ) | ||||
{ | { | ||||
this->addFloatingParameter( &par_mSq0_ ); | this->addFloatingParameter( &par_mSq0_ ); | ||||
} | } | ||||
Show All 20 Lines | const std::vector<LauParameter*>& LauKMatrixProdSVP::getFloatingParameters() | ||||
if ( !par_sA0_.fixed() ) | if ( !par_sA0_.fixed() ) | ||||
{ | { | ||||
this->addFloatingParameter( &par_sA0_ ); | this->addFloatingParameter( &par_sA0_ ); | ||||
} | } | ||||
return this->getParameters(); | return this->getParameters(); | ||||
} | } | ||||
No newline at end of file | No newline at end of file |