ATLAS Offline Software
Loading...
Searching...
No Matches
AFPProtonTransportTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4
5#ifndef TRIGAFPHYPO_AFPPROTONTRANSPORTTOOL_H
6#define TRIGAFPHYPO_AFPPROTONTRANSPORTTOOL_H
7
11
12#include <string>
13#include <memory>
14
24
26public:
27 AFPProtonTransportTool(const std::string & type, const std::string & name, const IInterface* parent);
28
30
31 virtual StatusCode initialize() override;
32
34 virtual StatusCode load() override;
35
36 virtual void setParamFile(const std::string& paramFile) override { m_filename = paramFile; }
37
39 virtual double x(double x0, double y0, double z0, double sx0, double sy0, double E) const override {
41 sy0 + m_ySlopeInitIP, E);
42 }
43
45 double y(double x0, double y0, double z0, double sx0, double sy0, double E) const {
47 sy0 + m_ySlopeInitIP, E);
48 }
49
51 double sx(double x0, double y0, double z0, double sx0, double sy0, double E) const {
52 return m_x_slope->evaluate(x0 + m_xPositionInitIP, y0 + m_yPositionInitIP, z0 + m_zPositionInitIP, sx0 + m_xSlopeInitIP,
53 sy0 + m_ySlopeInitIP, E);
54 }
55
57 double sy(double x0, double y0, double z0, double sx0, double sy0, double E) const {
58 return m_y_slope->evaluate(x0 + m_xPositionInitIP, y0 + m_yPositionInitIP, z0 + m_zPositionInitIP, sx0 + m_xSlopeInitIP, sy0 + m_ySlopeInitIP, E);
59 }
60
63
65 double energy() const {return m_energy;};
66private:
67
69 std::unique_ptr<AFPProtonTransportParam> m_x_position;
71 std::unique_ptr<AFPProtonTransportParam> m_y_position;
73 std::unique_ptr<AFPProtonTransportParam> m_x_slope;
75 std::unique_ptr<AFPProtonTransportParam> m_y_slope;
76
78 Gaudi::Property<double> m_xSlopeInitIP {this, "xSlopeInitIp", 0, "Initial x slope at IP"};
80 Gaudi::Property<double> m_ySlopeInitIP {this, "ySlopeInitIp", 0, "Initial y slope at IP"};
82 Gaudi::Property<double> m_xPositionInitIP {this, "xPositionInitIp", 0, "Initial x position at IP"};
84 Gaudi::Property<double> m_yPositionInitIP {this, "yPositionInitIp", 0, "Initial y position at IP"};
86 Gaudi::Property<double> m_zPositionInitIP {this, "zPositionInitIp", 0, "Initial z position at IP"};
88 Gaudi::Property<double> m_energy {this, "beamEnergy", 0, "Nominal beam energy"};
90 Gaudi::Property<double> m_parametrisationPosition {this, "parameterisationPosition", 0, "Detector position for which parameterisation was derived"};
91
92 Gaudi::Property<std::string> m_filename {this, "filename", "", "Parameterisation file"};
93
94};
95
96#endif
Gaudi::Property< double > m_yPositionInitIP
Proton's initial y position at the interaction point.
double sy(double x0, double y0, double z0, double sx0, double sy0, double E) const
Evaluates value of vertical slope equation. It takes as arguments the initial position,...
std::unique_ptr< AFPProtonTransportParam > m_y_slope
AFPProtonTransportParam object used for the y slope.
Gaudi::Property< double > m_xPositionInitIP
Proton's initial x position at the interaction point.
Gaudi::Property< double > m_energy
Nominal beam energy.
Gaudi::Property< double > m_xSlopeInitIP
Beam crossing angle from x axis at the interaction point.
std::unique_ptr< AFPProtonTransportParam > m_x_slope
AFPProtonTransportParam object used for the x slope.
virtual StatusCode initialize() override
Gaudi::Property< double > m_ySlopeInitIP
Beam crossing angle from y axis at the interaction point.
double y(double x0, double y0, double z0, double sx0, double sy0, double E) const
Evaluates value of vertical position equation. It takes as arguments the initial position,...
std::unique_ptr< AFPProtonTransportParam > m_y_position
AFPProtonTransportParam object used for the y position evaluation.
double parametrisationPosition() const
Returns the detector position for which parametrization was performed.
virtual void setParamFile(const std::string &paramFile) override
AFPProtonTransportTool(const std::string &type, const std::string &name, const IInterface *parent)
std::unique_ptr< AFPProtonTransportParam > m_x_position
AFPProtonTransportParam object used for the x position evaluation.
Gaudi::Property< double > m_parametrisationPosition
Detector position for which the parameterisation has been done.
virtual double x(double x0, double y0, double z0, double sx0, double sy0, double E) const override
Evaluates value of the horizontal position equation. It takes as arguments the initial position,...
Gaudi::Property< std::string > m_filename
double energy() const
Returns nominal beam energy for which parametrization was performed.
double sx(double x0, double y0, double z0, double sx0, double sy0, double E) const
Evaluates value of horizontal slope equation. It takes as arguments the initial position,...
Gaudi::Property< double > m_zPositionInitIP
Proton's initial z position at the interaction point.
virtual StatusCode load() override
Loads parametrization file and gets the value of positions, slopes and nominal energy....
AthAlgTool(const std::string &type, const std::string &name, const IInterface *parent)
Constructor with parameters: