13#include "GaudiKernel/Bootstrap.h"
14#include "Gaudi/Property.h"
15#include "GaudiKernel/IService.h"
16#include "GaudiKernel/IToolSvc.h"
17#include "GaudiKernel/ISvcLocator.h"
18#include "GaudiKernel/IMessageSvc.h"
30#include "GaudiKernel/ThreadLocalContext.h"
43 const std::string& name,
44 const IInterface* parent) :
45 base_class(
type, name, parent),
100 float eta = -1.*std::log(tan( (
float)
104 (
" Numbers used for Calo geometry : "
120 StatusCode
sc = StatusCode::SUCCESS;
136 StatusCode
sc = StatusCode::SUCCESS;
145 pt_local = (*m_transform_ctb_to_calo)*pt_ctb;
153 pt_ctb = (*m_transform_calo_to_ctb)*pt_local;
158 double& x_local,
double& y_local,
double& z_local)
165 x_local = pt_local.x();
166 y_local = pt_local.y();
167 z_local = pt_local.z();
177 double& x_ctb,
double& y_ctb,
double& z_ctb)
179 Vector3D pt_local(x_local,y_local,z_local);
214 const EventContext& ctx = Gaudi::Hive::currentContext();
259 double alpha = Eigen::AngleAxisd(junkrot).angle();
260 Eigen::Vector3d junkaxis = Eigen::AngleAxisd(junkrot).axis();
301 StatusCode
sc = toolSvc()->retrieveTool(
"TBCaloPosTool",
m_postool);
304 (
"Cannot get Calo table position from DB : keep default" );
323 ATH_MSG_INFO (
" ==> Calorimeter table position read from DB makes no sense, DB updates will be overwitten " );
330 ATH_MSG_INFO (
" --------------------------------------------------------------------- " );
337 ATH_MSG_INFO (
" If it does not match the LAr logbook, inform LAr people " );
342 ATH_MSG_INFO (
" --------------------------------------------------------------------- " );
414 ATH_MSG_INFO (
" m_table_eta is not in [0,1.5] -> will set it to 0. " );
458 ATH_MSG_DEBUG (
" --------------------------------------------------------------------- " );
460 ATH_MSG_DEBUG (
" Calorimeter table DCS either OFF of not used, position is hardcoded : for run "
463 ATH_MSG_DEBUG (
" If it does not match the LAr logbook, inform LAr people " );
465 ATH_MSG_DEBUG (
" --------------------------------------------------------------------- " );
484 ATH_MSG_DEBUG (
" Moovement defined by hardcoded numbers : eta was set to "
Scalar eta() const
pseudorapidity method
#define ATH_CHECK
Evaluate an expression and check for errors.
CaloPhiRange class declaration.
double angle(const GeoTrf::Vector2D &a, const GeoTrf::Vector2D &b)
This class defines the phi convention for Calorimeters.
Amg::RotationMatrix3D * m_table_rotate
void print_transform(Amg::Transform3D &htrans)
Amg::Transform3D m_translxyz_extra_calo_to_ctb
Amg::Transform3D * m_transform_calo_to_ctb
void ctb_to_local(Amg::Vector3D &pt_ctb, Amg::Vector3D &pt_local)
Amg::Transform3D * transform_ctb_to_calo()
ITBCaloPosTool * m_postool
Amg::Transform3D m_roty_extra_calo_to_ctb
virtual void read_table_position()
Amg::Translation3D * m_table_shift
virtual void read_fake_table_position()
void read_user_position()
bool read_data_position()
Amg::Transform3D * transform_calo_to_ctb()
double m_table_calc_theta
void local_to_ctb(Amg::Vector3D &pt_local, Amg::Vector3D &pt_ctb)
TBCaloCoordinate(const std::string &type, const std::string &name, const IInterface *parent)
Amg::Transform3D m_rotx_extra_calo_to_ctb
Amg::Transform3D m_rotz_extra_calo_to_ctb
Amg::Transform3D * m_transform_ctb_to_calo
double m_calo_theta_shift
const TBDetDescrManager * m_MCmgr
void read_neutral_position()
TBElementID::TBElementID id() const
Amg::Vector3D position() const
Amg::RotationMatrix3D rotation() const
Eigen::AngleAxisd AngleAxis3D
Eigen::Quaternion< double > Rotation3D
Eigen::Matrix< double, 3, 3 > RotationMatrix3D
Eigen::Affine3d Transform3D
Eigen::Matrix< double, 3, 1 > Vector3D
Eigen::Translation< double, 3 > Translation3D