Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
partons
core
partons
Commits
94681c27
Commit
94681c27
authored
Apr 30, 2020
by
Pawel Sznajder
Browse files
new observables added
parent
a6b70256
Changes
8
Hide whitespace changes
Inline
Side-by-side
include/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUDVCSSubProc.h
0 → 100644
View file @
94681c27
#ifndef DVCSCROSSSECTIONUUDVCSSUBPROC_H
#define DVCSCROSSSECTIONUUDVCSSUBPROC_H
/**
* @file DVCSCrossSectionUUDVCSSubProc.h
* @author Pawel Sznajder (IPNO)
* @date November 25, 2016
* @version 1.0
*/
#include
<string>
#include
"../../../../beans/gpd/GPDType.h"
#include
"../../../../beans/List.h"
#include
"../../../../utils/type/PhysicalType.h"
#include
"../DVCSObservable.h"
namespace
PARTONS
{
/**
* @class DVCSCrossSectionUUDVCSSubProc
* @brief Unpolarized cross-section for DVCS only.
*
* Unit: \f$\mathrm{nbarn}/\mathrm{GeV}^4\f$.
*/
class
DVCSCrossSectionUUDVCSSubProc
:
public
DVCSObservable
{
public:
/**
* Unique ID to automatically register the class in the registry.
*/
static
const
unsigned
int
classId
;
/**
* Constructor.
* @param className Name of class.
*/
DVCSCrossSectionUUDVCSSubProc
(
const
std
::
string
&
className
);
/**
* Destructor.
*/
virtual
~
DVCSCrossSectionUUDVCSSubProc
();
virtual
DVCSCrossSectionUUDVCSSubProc
*
clone
()
const
;
protected:
/**
* Copy constructor.
* @param other Object to be copied.
*/
DVCSCrossSectionUUDVCSSubProc
(
const
DVCSCrossSectionUUDVCSSubProc
&
other
);
virtual
PhysicalType
<
double
>
computeObservable
(
const
DVCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
);
};
}
/* namespace PARTONS */
#endif
/* DVCSCROSSSECTIONUUDVCSSUBPROC_H */
include/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUDVCSSubProcPhiIntegrated.h
0 → 100644
View file @
94681c27
#ifndef DVCSCROSSSECTIONUUDVCSSUBPROCPHIINTEGRATED_H
#define DVCSCROSSSECTIONUUDVCSSUBPROCPHIINTEGRATED_H
/**
* @file DVCSCrossSectionUUDVCSSubProcPhiIntegrated.h
* @author Luca COLANERI (IPNO)
* @date April 24, 2017
* @version 1.0
*/
#include
<ElementaryUtils/parameters/Parameters.h>
#include
<string>
#include
<vector>
#include
"../../../../beans/gpd/GPDType.h"
#include
"../../../../beans/List.h"
#include
"../../../../utils/type/PhysicalType.h"
#include
"../../../MathIntegratorModule.h"
#include
"DVCSCrossSectionUUDVCSSubProc.h"
namespace
PARTONS
{
/**
* @class DVCSCrossSectionUUDVCSSubProcPhiIntegrated
* @brief Unpolarized cross-section for electro-production integrated over \f$\phi\f$.
*
* Unit: \f$\mathrm{nbarn}/\mathrm{GeV}^4\f$.
*/
class
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
:
public
DVCSCrossSectionUUDVCSSubProc
,
public
MathIntegratorModule
{
public:
/**
* Unique ID to automatically register the class in the registry.
*/
static
const
unsigned
int
classId
;
/**
* Constructor.
* @param className Name of class.
*/
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
(
const
std
::
string
&
className
);
/**
* Destructor.
*/
virtual
~
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
();
virtual
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
*
clone
()
const
;
virtual
void
configure
(
const
ElemUtils
::
Parameters
&
parameters
);
protected:
/**
* Copy constructor.
* @param other Object to be copied.
*/
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
(
const
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
&
other
);
virtual
PhysicalType
<
double
>
computeObservable
(
const
DVCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
);
/**
* Functor to perform the integration.
*/
NumA
::
FunctionType1D
*
m_pFunctionToIntegrateObservable
;
/**
* Function to be integrated.
*/
virtual
double
functionToIntegrateObservable
(
double
x
,
std
::
vector
<
double
>
params
);
/**
* Initialize functors.
*/
void
initFunctorsForIntegrations
();
};
}
/* namespace PARTONS */
#endif
/* DVCSCROSSSECTIONUUDVCSSUBPROCPHIINTEGRATED_H */
include/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUMinusPhiIntegrated.h
0 → 100644
View file @
94681c27
#ifndef DVCSCROSSSECTIONUUMINUSPHIINTEGRATED_H
#define DVCSCROSSSECTIONUUMINUSPHIINTEGRATED_H
/**
* @file DVCSCrossSectionUUMinusPhiIntegrated.h
* @author Luca COLANERI (IPNO)
* @date April 24, 2017
* @version 1.0
*/
#include
<ElementaryUtils/parameters/Parameters.h>
#include
<string>
#include
<vector>
#include
"../../../../beans/gpd/GPDType.h"
#include
"../../../../beans/List.h"
#include
"../../../../utils/type/PhysicalType.h"
#include
"../../../MathIntegratorModule.h"
#include
"DVCSCrossSectionUUMinus.h"
namespace
PARTONS
{
/**
* @class DVCSCrossSectionUUMinusPhiIntegrated
* @brief Unpolarized cross-section for electro-production integrated over \f$\phi\f$.
*
* Unit: \f$\mathrm{nbarn}/\mathrm{GeV}^4\f$.
*/
class
DVCSCrossSectionUUMinusPhiIntegrated
:
public
DVCSCrossSectionUUMinus
,
public
MathIntegratorModule
{
public:
/**
* Unique ID to automatically register the class in the registry.
*/
static
const
unsigned
int
classId
;
/**
* Constructor.
* @param className Name of class.
*/
DVCSCrossSectionUUMinusPhiIntegrated
(
const
std
::
string
&
className
);
/**
* Destructor.
*/
virtual
~
DVCSCrossSectionUUMinusPhiIntegrated
();
virtual
DVCSCrossSectionUUMinusPhiIntegrated
*
clone
()
const
;
virtual
void
configure
(
const
ElemUtils
::
Parameters
&
parameters
);
protected:
/**
* Copy constructor.
* @param other Object to be copied.
*/
DVCSCrossSectionUUMinusPhiIntegrated
(
const
DVCSCrossSectionUUMinusPhiIntegrated
&
other
);
virtual
PhysicalType
<
double
>
computeObservable
(
const
DVCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
);
/**
* Functor to perform the integration.
*/
NumA
::
FunctionType1D
*
m_pFunctionToIntegrateObservable
;
/**
* Function to be integrated.
*/
virtual
double
functionToIntegrateObservable
(
double
x
,
std
::
vector
<
double
>
params
);
/**
* Initialize functors.
*/
void
initFunctorsForIntegrations
();
};
}
/* namespace PARTONS */
#endif
/* DVCSCROSSSECTIONUUMINUSPHIINTEGRATED_H */
include/partons/modules/observable/TCS/asymmetry/TCSAfb.h
0 → 100644
View file @
94681c27
#ifndef TCSACU_H
#define TCSACU_H
/**
* @file TCSAfb.h
* @author Pawel Sznajder (IPNO)
* @date November 25, 2016
* @version 1.0
*/
#include
<string>
#include
"../../../../beans/gpd/GPDType.h"
#include
"../../../../beans/List.h"
#include
"../../../../utils/type/PhysicalType.h"
#include
"../TCSObservable.h"
namespace
PARTONS
{
/**
* @class TCSAfb
* @brief Forward-backward TCS asymmetry.
*
* Unit: none.
*/
class
TCSAfb
:
public
TCSObservable
{
public:
/**
* Unique ID to automatically register the class in the registry.
*/
static
const
unsigned
int
classId
;
/**
* Constructor.
* @param className Name of class.
*/
TCSAfb
(
const
std
::
string
&
className
);
/**
* Destructor.
*/
virtual
~
TCSAfb
();
virtual
TCSAfb
*
clone
()
const
;
protected:
/**
* Copy constructor.
* @param other Object to be copied.
*/
TCSAfb
(
const
TCSAfb
&
other
);
virtual
PhysicalType
<
double
>
computeObservable
(
const
TCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
);
};
}
/* namespace PARTONS */
#endif
/* TCSACU_H */
src/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUDVCSSubProc.cpp
0 → 100644
View file @
94681c27
#include
"../../../../../../include/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUDVCSSubProc.h"
#include
<NumA/linear_algebra/vector/Vector3D.h>
#include
"../../../../../../include/partons/beans/observable/ObservableResult.h"
#include
"../../../../../../include/partons/beans/process/VCSSubProcessType.h"
#include
"../../../../../../include/partons/BaseObjectRegistry.h"
#include
"../../../../../../include/partons/FundamentalPhysicalConstants.h"
#include
"../../../../../../include/partons/modules/process/DVCS/DVCSProcessModule.h"
#include
"../../../../../../include/partons/utils/type/PhysicalUnit.h"
namespace
PARTONS
{
const
unsigned
int
DVCSCrossSectionUUDVCSSubProc
::
classId
=
BaseObjectRegistry
::
getInstance
()
->
registerBaseObject
(
new
DVCSCrossSectionUUDVCSSubProc
(
"DVCSCrossSectionUUDVCSSubProc"
));
DVCSCrossSectionUUDVCSSubProc
::
DVCSCrossSectionUUDVCSSubProc
(
const
std
::
string
&
className
)
:
DVCSObservable
(
className
)
{
}
DVCSCrossSectionUUDVCSSubProc
::
DVCSCrossSectionUUDVCSSubProc
(
const
DVCSCrossSectionUUDVCSSubProc
&
other
)
:
DVCSObservable
(
other
)
{
}
DVCSCrossSectionUUDVCSSubProc
::~
DVCSCrossSectionUUDVCSSubProc
()
{
}
DVCSCrossSectionUUDVCSSubProc
*
DVCSCrossSectionUUDVCSSubProc
::
clone
()
const
{
return
new
DVCSCrossSectionUUDVCSSubProc
(
*
this
);
}
PhysicalType
<
double
>
DVCSCrossSectionUUDVCSSubProc
::
computeObservable
(
const
DVCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
)
{
//evaluate
DVCSObservableResult
A
=
m_pProcessModule
->
compute
(
1.
,
-
1
,
NumA
::
Vector3D
(
0.
,
0.
,
0.
),
kinematic
,
gpdType
,
VCSSubProcessType
::
DVCS
);
DVCSObservableResult
B
=
m_pProcessModule
->
compute
(
-
1.
,
-
1
,
NumA
::
Vector3D
(
0.
,
0.
,
0.
),
kinematic
,
gpdType
,
VCSSubProcessType
::
DVCS
);
//combine
PhysicalType
<
double
>
result
=
(
A
.
getValue
()
+
B
.
getValue
())
/
2.
;
//integrate over transversely polarized target dependence to obtain 4-fold differential cross-section
result
*=
2.
*
Constant
::
PI
;
//change to nb
return
result
.
makeSameUnitAs
(
PhysicalUnit
::
NB
);
}
}
/* namespace PARTONS */
src/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUDVCSSubProcPhiIntegrated.cpp
0 → 100644
View file @
94681c27
#include
"../../../../../../include/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUDVCSSubProcPhiIntegrated.h"
#include
<NumA/functor/one_dimension/Functor1D.h>
#include
<NumA/integration/one_dimension/Integrator1D.h>
#include
<NumA/integration/one_dimension/IntegratorType1D.h>
#include
"../../../../../../include/partons/beans/observable/DVCS/DVCSObservableKinematic.h"
#include
"../../../../../../include/partons/BaseObjectRegistry.h"
#include
"../../../../../../include/partons/FundamentalPhysicalConstants.h"
#include
"../../../../../../include/partons/modules/observable/Observable.h"
#include
"../../../../../../include/partons/utils/type/PhysicalUnit.h"
namespace
PARTONS
{
const
unsigned
int
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
classId
=
BaseObjectRegistry
::
getInstance
()
->
registerBaseObject
(
new
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
(
"DVCSCrossSectionUUDVCSSubProcPhiIntegrated"
));
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
(
const
std
::
string
&
className
)
:
DVCSCrossSectionUUDVCSSubProc
(
className
),
MathIntegratorModule
(),
m_pFunctionToIntegrateObservable
(
0
)
{
setIntegrator
(
NumA
::
IntegratorType1D
::
DEXP
);
initFunctorsForIntegrations
();
}
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
(
const
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
&
other
)
:
DVCSCrossSectionUUDVCSSubProc
(
other
),
MathIntegratorModule
(
other
)
{
m_pFunctionToIntegrateObservable
=
0
;
initFunctorsForIntegrations
();
}
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::~
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
()
{
if
(
m_pFunctionToIntegrateObservable
)
{
delete
m_pFunctionToIntegrateObservable
;
m_pFunctionToIntegrateObservable
=
0
;
}
}
void
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
initFunctorsForIntegrations
()
{
m_pFunctionToIntegrateObservable
=
NumA
::
Integrator1D
::
newIntegrationFunctor
(
this
,
&
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
functionToIntegrateObservable
);
}
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
*
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
clone
()
const
{
return
new
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
(
*
this
);
}
void
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
configure
(
const
ElemUtils
::
Parameters
&
parameters
)
{
DVCSCrossSectionUUDVCSSubProc
::
configure
(
parameters
);
MathIntegratorModule
::
configureIntegrator
(
parameters
);
}
double
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
functionToIntegrateObservable
(
double
x
,
std
::
vector
<
double
>
params
)
{
DVCSObservableKinematic
kinematic
;
List
<
GPDType
>
gpdType
;
unserializeKinematicsAndGPDTypesFromStdVector
(
params
,
kinematic
,
gpdType
);
kinematic
.
setPhi
(
PhysicalType
<
double
>
(
x
,
PhysicalUnit
::
RAD
));
return
DVCSCrossSectionUUDVCSSubProc
::
computeObservable
(
kinematic
,
gpdType
).
getValue
();
}
PhysicalType
<
double
>
DVCSCrossSectionUUDVCSSubProcPhiIntegrated
::
computeObservable
(
const
DVCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
)
{
std
::
vector
<
double
>
params
=
serializeKinematicsAndGPDTypesIntoStdVector
(
kinematic
,
gpdType
);
return
PhysicalType
<
double
>
(
integrate
(
m_pFunctionToIntegrateObservable
,
0.
,
(
2
*
Constant
::
PI
),
params
),
PhysicalUnit
::
NB
);
}
}
/* namespace PARTONS */
src/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUMinusPhiIntegrated.cpp
0 → 100644
View file @
94681c27
#include
"../../../../../../include/partons/modules/observable/DVCS/cross_section/DVCSCrossSectionUUMinusPhiIntegrated.h"
#include
<NumA/functor/one_dimension/Functor1D.h>
#include
<NumA/integration/one_dimension/Integrator1D.h>
#include
<NumA/integration/one_dimension/IntegratorType1D.h>
#include
"../../../../../../include/partons/beans/observable/DVCS/DVCSObservableKinematic.h"
#include
"../../../../../../include/partons/BaseObjectRegistry.h"
#include
"../../../../../../include/partons/FundamentalPhysicalConstants.h"
#include
"../../../../../../include/partons/modules/observable/Observable.h"
#include
"../../../../../../include/partons/utils/type/PhysicalUnit.h"
namespace
PARTONS
{
const
unsigned
int
DVCSCrossSectionUUMinusPhiIntegrated
::
classId
=
BaseObjectRegistry
::
getInstance
()
->
registerBaseObject
(
new
DVCSCrossSectionUUMinusPhiIntegrated
(
"DVCSCrossSectionUUMinusPhiIntegrated"
));
DVCSCrossSectionUUMinusPhiIntegrated
::
DVCSCrossSectionUUMinusPhiIntegrated
(
const
std
::
string
&
className
)
:
DVCSCrossSectionUUMinus
(
className
),
MathIntegratorModule
(),
m_pFunctionToIntegrateObservable
(
0
)
{
setIntegrator
(
NumA
::
IntegratorType1D
::
DEXP
);
initFunctorsForIntegrations
();
}
DVCSCrossSectionUUMinusPhiIntegrated
::
DVCSCrossSectionUUMinusPhiIntegrated
(
const
DVCSCrossSectionUUMinusPhiIntegrated
&
other
)
:
DVCSCrossSectionUUMinus
(
other
),
MathIntegratorModule
(
other
)
{
m_pFunctionToIntegrateObservable
=
0
;
initFunctorsForIntegrations
();
}
DVCSCrossSectionUUMinusPhiIntegrated
::~
DVCSCrossSectionUUMinusPhiIntegrated
()
{
if
(
m_pFunctionToIntegrateObservable
)
{
delete
m_pFunctionToIntegrateObservable
;
m_pFunctionToIntegrateObservable
=
0
;
}
}
void
DVCSCrossSectionUUMinusPhiIntegrated
::
initFunctorsForIntegrations
()
{
m_pFunctionToIntegrateObservable
=
NumA
::
Integrator1D
::
newIntegrationFunctor
(
this
,
&
DVCSCrossSectionUUMinusPhiIntegrated
::
functionToIntegrateObservable
);
}
DVCSCrossSectionUUMinusPhiIntegrated
*
DVCSCrossSectionUUMinusPhiIntegrated
::
clone
()
const
{
return
new
DVCSCrossSectionUUMinusPhiIntegrated
(
*
this
);
}
void
DVCSCrossSectionUUMinusPhiIntegrated
::
configure
(
const
ElemUtils
::
Parameters
&
parameters
)
{
DVCSCrossSectionUUMinus
::
configure
(
parameters
);
MathIntegratorModule
::
configureIntegrator
(
parameters
);
}
double
DVCSCrossSectionUUMinusPhiIntegrated
::
functionToIntegrateObservable
(
double
x
,
std
::
vector
<
double
>
params
)
{
DVCSObservableKinematic
kinematic
;
List
<
GPDType
>
gpdType
;
unserializeKinematicsAndGPDTypesFromStdVector
(
params
,
kinematic
,
gpdType
);
kinematic
.
setPhi
(
PhysicalType
<
double
>
(
x
,
PhysicalUnit
::
RAD
));
return
DVCSCrossSectionUUMinus
::
computeObservable
(
kinematic
,
gpdType
).
getValue
();
}
PhysicalType
<
double
>
DVCSCrossSectionUUMinusPhiIntegrated
::
computeObservable
(
const
DVCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
)
{
std
::
vector
<
double
>
params
=
serializeKinematicsAndGPDTypesIntoStdVector
(
kinematic
,
gpdType
);
return
PhysicalType
<
double
>
(
integrate
(
m_pFunctionToIntegrateObservable
,
0.
,
(
2
*
Constant
::
PI
),
params
),
PhysicalUnit
::
NB
);
}
}
/* namespace PARTONS */
src/partons/modules/observable/TCS/asymmetry/TCSAbf.cpp
0 → 100644
View file @
94681c27
#include
<NumA/linear_algebra/vector/Vector3D.h>
#include
<cmath>
#include
<string>
#include
"../../../../../../include/partons/beans/gpd/GPDType.h"
#include
"../../../../../../include/partons/beans/List.h"
#include
"../../../../../../include/partons/beans/observable/ObservableResult.h"
#include
"../../../../../../include/partons/beans/observable/TCS/TCSObservableKinematic.h"
#include
"../../../../../../include/partons/BaseObjectRegistry.h"
#include
"../../../../../../include/partons/modules/observable/TCS/asymmetry/TCSAfb.h"
#include
"../../../../../../include/partons/modules/process/TCS/TCSProcessModule.h"
#include
"../../../../../../include/partons/utils/type/PhysicalType.h"
#include
"../../../../../../include/partons/utils/type/PhysicalUnit.h"
namespace
PARTONS
{
const
unsigned
int
TCSAfb
::
classId
=
BaseObjectRegistry
::
getInstance
()
->
registerBaseObject
(
new
TCSAfb
(
"TCSAfb"
));
TCSAfb
::
TCSAfb
(
const
std
::
string
&
className
)
:
TCSObservable
(
className
)
{
}
TCSAfb
::
TCSAfb
(
const
TCSAfb
&
other
)
:
TCSObservable
(
other
)
{
}
TCSAfb
::~
TCSAfb
()
{
}
TCSAfb
*
TCSAfb
::
clone
()
const
{
return
new
TCSAfb
(
*
this
);
}
PhysicalType
<
double
>
TCSAfb
::
computeObservable
(
const
TCSObservableKinematic
&
kinematic
,
const
List
<
GPDType
>&
gpdType
)
{
//backward kinematics
TCSObservableKinematic
kinematicBackward
=
kinematic
;
kinematicBackward
.
setPhi
(
M_PI
+
kinematic
.
getPhi
().
makeSameUnitAs
(
PhysicalUnit
::
RAD
).
getValue
(),
PhysicalUnit
::
RAD
);
kinematicBackward
.
setTheta
(
M_PI
-
kinematic
.
getTheta
().
makeSameUnitAs
(
PhysicalUnit
::
RAD
).
getValue
(),
PhysicalUnit
::
RAD
);