ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
InnerDetector
InDetConditions
SCT_ConditionsTools
src
SCT_ElectricFieldTool.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
SCT_ElectricFieldTool.h
"
6
7
#include "CLHEP/Units/SystemOfUnits.h"
8
9
#include <cmath>
10
11
SCT_ElectricFieldTool::SCT_ElectricFieldTool
(
const
std::string& t,
const
std::string& n,
const
IInterface* p) :
12
base_class(t, n, p) {
13
}
14
15
StatusCode
16
SCT_ElectricFieldTool::initialize
() {
17
m_model
.SetParameters(1.04176,
18
2095.14,
19
-606483.,
20
8.60976e+07,
21
-7.20639e+09,
22
3.59418e+11,
23
-9.43812e+12,
24
9.78747e+13);
25
26
return
StatusCode::SUCCESS;
27
}
28
29
30
31
StatusCode
SCT_ElectricFieldTool::finalize
() {
32
return
StatusCode::SUCCESS;
33
}
34
35
double
SCT_ElectricFieldTool::getElectricField
(
double
positionZ,
36
double
,
37
double
depletionVoltage,
38
double
sensorThickness,
39
double
biasVoltage)
const
{
40
if
((
m_eFieldModel
==
UNIFORM_FIELD
) or (
m_eFieldModel
==
FLAT_DIODE
)) {
41
//--------------------------------------------------------------
42
// Electric Field Ez
43
//--------------------------------------------------------------
44
// y is depth and should be give in mm
45
// the electric field is returned in V/mm
46
//
47
double
y
{positionZ*0.1};
// from mm to cm
48
double
bulkDepth{sensorThickness*0.1};
// from mm to cm;
49
double
Ey{0.};
50
y
= bulkDepth -
y
;
51
52
//------------ find depletion depth for model=0 and 1 -------------
53
double
depletionDepth{bulkDepth};
54
if
(biasVoltage < std::abs(depletionVoltage)) depletionDepth = std::sqrt(biasVoltage/std::abs(depletionVoltage)) * bulkDepth;
55
if
(
y
<=depletionDepth){
56
//---------- case for uniform electric field ------------------------
57
if
(
m_eFieldModel
==
UNIFORM_FIELD
) {
58
Ey = biasVoltage / depletionDepth ;
59
Ey = Ey*0.1;
60
return
Ey / CLHEP::volt;
61
}
62
63
//---------- case for flat diode model ------------------------------
64
if
(
m_eFieldModel
==
FLAT_DIODE
) {
65
if
(biasVoltage > std::abs(depletionVoltage)) {
66
Ey = (biasVoltage+depletionVoltage)/depletionDepth - 2.*depletionVoltage*(bulkDepth-
y
)/(bulkDepth*bulkDepth);
67
}
else
{
68
double
Emax{2.* depletionDepth * depletionVoltage / (bulkDepth*bulkDepth)};
69
Ey = Emax*(1-(bulkDepth-
y
)/depletionDepth);
70
}
71
Ey = Ey*0.1;
72
return
Ey / CLHEP::volt;
73
}
74
}
else
{
75
return
0.;
76
}
77
}
else
{
78
//simple toy model --> to be replaced with complete parameterization later
79
ATH_MSG_INFO
(
"Using for E-field simple toy model corresponding to 10^15 fluence, full depletion end for holes."
);
80
81
double
E_D{
m_model
.Eval(positionZ*0.1)*0.1};
//the model is in cm
82
return
E_D;
83
}
84
85
return
-99.;
86
}
//end method
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition
AthMsgStreamMacros.h:31
SCT_ElectricFieldTool.h
y
#define y
SCT_ElectricFieldTool::SCT_ElectricFieldTool
SCT_ElectricFieldTool(const std::string &t, const std::string &n, const IInterface *p)
Definition
SCT_ElectricFieldTool.cxx:11
SCT_ElectricFieldTool::initialize
virtual StatusCode initialize() override
Definition
SCT_ElectricFieldTool.cxx:16
SCT_ElectricFieldTool::getElectricField
virtual double getElectricField(double positionZ, double fluence, double depletionVoltage, double sensorThickness, double biasVoltage) const override
Definition
SCT_ElectricFieldTool.cxx:35
SCT_ElectricFieldTool::finalize
virtual StatusCode finalize() override
Definition
SCT_ElectricFieldTool.cxx:31
SCT_ElectricFieldTool::m_model
TF1 m_model
Definition
SCT_ElectricFieldTool.h:44
SCT_ElectricFieldTool::FLAT_DIODE
@ FLAT_DIODE
Definition
SCT_ElectricFieldTool.h:41
SCT_ElectricFieldTool::UNIFORM_FIELD
@ UNIFORM_FIELD
Definition
SCT_ElectricFieldTool.h:41
SCT_ElectricFieldTool::m_eFieldModel
IntegerProperty m_eFieldModel
Definition
SCT_ElectricFieldTool.h:43
Generated on
for ATLAS Offline Software by
1.17.0