Page Menu
Home
HEPForge
Search
Configure Global Search
Log In
Files
F19282614
D52.1759147036.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
8 KB
Referenced Files
None
Subscribers
None
D52.1759147036.diff
View Options
diff --git a/doc/ReleaseNotes.md b/doc/ReleaseNotes.md
--- a/doc/ReleaseNotes.md
+++ b/doc/ReleaseNotes.md
@@ -1,6 +1,10 @@
# Laura++ release notes
-4th February 2020 Dan Johnson
+5th March 2021 Dan Johnson
+* Alterations to allow Blatt-Weisskopf factor for parent to be created in a model with only a K-matrix
+ - see https://phab.hepforge.org/D52
+
+4th February 2021 Dan Johnson
* Extend the K-matrix implementation to handle non-zero spin
- see https://phab.hepforge.org/T135
diff --git a/inc/LauBlattWeisskopfFactor.hh b/inc/LauBlattWeisskopfFactor.hh
--- a/inc/LauBlattWeisskopfFactor.hh
+++ b/inc/LauBlattWeisskopfFactor.hh
@@ -36,15 +36,16 @@
#define LAU_BLATTWEISSKOPFFACTOR
#include "Rtypes.h"
+#include "TString.h"
class LauParameter;
class LauResonanceInfo;
-class LauBlattWeisskopfFactor {
+class LauBlattWeisskopfFactor final {
public:
- //! Define the allowed types of barrier factors
+ //! Define the allowed types of barrier factors
enum BarrierType {
BWBarrier, /*!< Blatt-Weisskopf barrier factor (for use when momentum terms not used in angular term) */
BWPrimeBarrier, /*!< Blatt-Weisskopf barrier factor (for use when momentum terms are used in angular term) - the default */
@@ -83,8 +84,8 @@
//! Constructor
LauBlattWeisskopfFactor( const LauResonanceInfo& resInfo, const Double_t resRadius, const BarrierType barrierType, const RestFrame restFrame, const BlattWeisskopfCategory category );
- //! Destructor
- virtual ~LauBlattWeisskopfFactor();
+ //! Constructor
+ LauBlattWeisskopfFactor( const Int_t spin, const Double_t resRadius, const BarrierType barrierType, const RestFrame restFrame, const BlattWeisskopfCategory category );
//! Method to create a new factor with cloned radius parameter
/*!
@@ -110,10 +111,6 @@
*/
Double_t calcFormFactor( const Double_t p ) const;
- protected:
- //! Set the name of the radius parameter
- TString setRadiusName( const LauResonanceInfo& resInfo, const BlattWeisskopfCategory category );
-
private:
//! Copy constructor
LauBlattWeisskopfFactor( const LauBlattWeisskopfFactor& other, const UInt_t newSpin, const BarrierType newBarrierType );
@@ -121,6 +118,15 @@
//! Copy assignment operator (not implemented)
LauBlattWeisskopfFactor& operator=( const LauBlattWeisskopfFactor& other );
+ //! Set the name of the radius parameter
+ TString setRadiusName( const LauResonanceInfo& resInfo, const BlattWeisskopfCategory category );
+
+ //! Set the name of the radius parameter
+ TString setRadiusName( const BlattWeisskopfCategory category );
+
+ //! Set the name of the radius parameter
+ TString setRadiusName( const TString& categoryName );
+
//! Resonance spin
const UInt_t spin_;
diff --git a/src/LauBlattWeisskopfFactor.cc b/src/LauBlattWeisskopfFactor.cc
--- a/src/LauBlattWeisskopfFactor.cc
+++ b/src/LauBlattWeisskopfFactor.cc
@@ -58,8 +58,14 @@
std::cout << "INFO in LauBlattWeisskopfFactor constructor : creating radius parameter for category \"" << categoryName << "\", with initial value " << resRadius << std::endl;
}
-LauBlattWeisskopfFactor::~LauBlattWeisskopfFactor()
+LauBlattWeisskopfFactor::LauBlattWeisskopfFactor( const Int_t spin, const Double_t resRadius, const BarrierType barrierType, const RestFrame restFrame, const BlattWeisskopfCategory category ) :
+ spin_(spin),
+ radius_(new LauParameter("NEED_A_GOOD_NAME",resRadius,0.0,10.0,kTRUE)),
+ barrierType_(barrierType),
+ restFrame_(restFrame)
{
+ TString categoryName = this->setRadiusName( category );
+ std::cout << "INFO in LauBlattWeisskopfFactor constructor : creating radius parameter for category \"" << categoryName << "\", with initial value " << resRadius << std::endl;
}
LauBlattWeisskopfFactor::LauBlattWeisskopfFactor( const LauBlattWeisskopfFactor& other, const UInt_t newSpin, const BarrierType newBarrierType ) :
@@ -72,61 +78,61 @@
TString LauBlattWeisskopfFactor::setRadiusName( const LauResonanceInfo& resInfo, const BlattWeisskopfCategory category )
{
- TString name = "BarrierRadius_";
- TString categoryName;
+ switch (category) {
+ case Indep :
+ return this->setRadiusName( resInfo.getSanitisedName() );
+ default :
+ return this->setRadiusName( category );
+ }
+}
+TString LauBlattWeisskopfFactor::setRadiusName( const BlattWeisskopfCategory category )
+{
switch (category) {
- case Parent :
- categoryName = "Parent";
- break;
+ case Default :
+ return this->setRadiusName("Unknown");
case Indep :
- categoryName = resInfo.getSanitisedName();
- break;
+ // We shouldn't ever end up here
+ return this->setRadiusName("Unknown");
+ case Parent :
+ return this->setRadiusName("Parent");
case Light :
- categoryName = "Light";
- break;
+ return this->setRadiusName("Light");
case Kstar :
- categoryName = "Kstar";
- break;
+ return this->setRadiusName("Kstar");
case Charm :
- categoryName = "Charm";
- break;
+ return this->setRadiusName("Charm");
case StrangeCharm :
- categoryName = "StrangeCharm";
- break;
+ return this->setRadiusName("StrangeCharm");
case Charmonium :
- categoryName = "Charmonium";
- break;
+ return this->setRadiusName("Charmonium");
case Beauty :
- categoryName = "Beauty";
- break;
+ return this->setRadiusName("Beauty");
case StrangeBeauty :
- categoryName = "StrangeBeauty";
- break;
+ return this->setRadiusName("StrangeBeauty");
case CharmBeauty :
- categoryName = "CharmBeauty";
- break;
+ return this->setRadiusName("CharmBeauty");
case Custom1 :
- categoryName = "Custom1";
- break;
+ return this->setRadiusName("Custom1");
case Custom2 :
- categoryName = "Custom2";
- break;
+ return this->setRadiusName("Custom2");
case Custom3 :
- categoryName = "Custom3";
- break;
+ return this->setRadiusName("Custom3");
case Custom4 :
- categoryName = "Custom4";
- break;
- default :
- categoryName = "Unknown";
- break;
+ return this->setRadiusName("Custom4");
}
+ // We should never get here but gcc seems to think we can
+ return this->setRadiusName("Unknown");
+}
+
+TString LauBlattWeisskopfFactor::setRadiusName( const TString& categoryName )
+{
+ TString name = "BarrierRadius_";
+ name.Append(categoryName);
- name.Append(categoryName);
- radius_->name(name);
+ radius_->name(name);
- return categoryName;
+ return categoryName;
}
LauBlattWeisskopfFactor* LauBlattWeisskopfFactor::createClone( const UInt_t newSpin, const BarrierType newBarrierType )
diff --git a/src/LauResonanceMaker.cc b/src/LauResonanceMaker.cc
--- a/src/LauResonanceMaker.cc
+++ b/src/LauResonanceMaker.cc
@@ -632,19 +632,38 @@
// Look up the category in the category information map
BWFactorCategoryMap::iterator factor_iter = bwFactors_.find( LauBlattWeisskopfFactor::Parent );
- if ( factor_iter != bwFactors_.end() ) {
+ if ( factor_iter == bwFactors_.end() ) {
+ // If the category is currently undefined we need to create it
+ bwFactor = new LauBlattWeisskopfFactor( resSpin, 4.0, bwBarrierType_, bwRestFrame_, LauBlattWeisskopfFactor::Parent );
+ std::cerr<<"WARNING in LauResonanceMaker::getParentBWFactor : Default radius 4.0 set for Blatt-Weisskopf factor category: Parent"<<std::endl;
+
+ BlattWeisskopfCategoryInfo& categoryInfo = bwFactors_[LauBlattWeisskopfFactor::Parent];
+ categoryInfo.bwFactor_ = bwFactor;
+ categoryInfo.defaultRadius_ = bwFactor->getRadiusParameter()->value();
+ categoryInfo.radiusFixed_ = kTRUE;
+ } else {
// If it exists, we can check if the factor object has been created
BlattWeisskopfCategoryInfo& categoryInfo = factor_iter->second;
if ( categoryInfo.bwFactor_ != 0 ) {
// If so, simply clone it
bwFactor = categoryInfo.bwFactor_->createClone( resSpin, barrierType );
+ } else {
+ // Otherwise we need to create it, using the default value if it has been set
+ if ( categoryInfo.defaultRadius_ >= 0.0 ) {
+ bwFactor = new LauBlattWeisskopfFactor( resSpin, categoryInfo.defaultRadius_, bwBarrierType_, bwRestFrame_, LauBlattWeisskopfFactor::Parent );
+ } else {
+ bwFactor = new LauBlattWeisskopfFactor( resSpin, 4.0, bwBarrierType_, bwRestFrame_, LauBlattWeisskopfFactor::Parent );
+ std::cerr<<"WARNING in LauResonanceMaker::getParentBWFactor : Default radius 4.0 set for Blatt-Weisskopf factor category: Parent"<<std::endl;
+ }
+ categoryInfo.bwFactor_ = bwFactor;
+
+ // Set whether the radius should be fixed/floated
+ LauParameter* radius = bwFactor->getRadiusParameter();
+ radius->fixed( categoryInfo.radiusFixed_ );
}
}
- if ( bwFactor==0 ) {
- std::cerr<<"ERROR in LauResonanceMaker::getParentBWFactor : No parent Blatt-Weisskopf factor found to be cloned for K-matrix."<<std::endl;
- }
return bwFactor;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Sep 29, 12:57 PM (11 h, 38 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
6561824
Default Alt Text
D52.1759147036.diff (8 KB)
Attached To
Mode
D52: Alterations to allow Blatt-Weisskopf factor for parent to be created in a model with only a K-matrix
Attached
Detach File
Event Timeline
Log In to Comment