|
unsigned short | MB_DT_Check_boundaries (double distime, double alpha, double by, double bz, short ifl) const |
|
double | MB_DT_delta_x (double, double *) const |
|
double | MB_DT_dist (double, double *) const |
|
unsigned short | MB_DT_drift_distance (double time, double alpha, double by, double bz, drift_distance *DX, short interpolate) const |
| Calculate drift distance and spread. More...
|
|
void | MB_DT_Get_grid_points (double alpha, double by, double bz, unsigned short *p_alpha, unsigned short *p_By, unsigned short *p_Bz, unsigned short *q_alpha, unsigned short *q_By, unsigned short *q_Bz) const |
|
void | MB_DT_Get_grid_values (double Var, unsigned short *pi, unsigned short *pj, short Initial, unsigned short N, const double *Values) const |
|
double | MB_DT_MLInterpolation (double *al, double *by, double *bz, double *f) const |
|
double | MB_DT_sigma_t_m (double, double *) const |
|
double | MB_DT_sigma_t_p (double, double *) const |
|
This class access the cell parametrization by Pablo Garcia-Abia and Jesus Puerta (CIEMAT). The two public methods act as an interface for the parametrization converting the reference frame and the units accordingly to CMSSW convention.
- Author
- Pablo Garcia-Abia and Jesus Puerta (CIEMAT, Madrid)
Definition at line 18 of file DTTime2DriftParametrization.h.
bool DTTime2DriftParametrization::computeDriftDistance_mean |
( |
double |
time, |
|
|
double |
alpha, |
|
|
double |
by, |
|
|
double |
bz, |
|
|
short |
interpolate, |
|
|
drift_distance * |
dx |
|
) |
| const |
Compute the drift distance and relative errors (cm). The drift distance is computed as the MEAN value of the distance distribution for this particular time. This method takes care of the conversions of units and reference frame used by CMSSW and the parametrization. time is in ns, alpha (=atan(x/-z)) in rad, by and bz are the magnetic field in the layer RF. False is returned if the parametrization fails
Definition at line 52 of file DTTime2DriftParametrization.cc.
73 dx->v_drift =
dx->v_drift / 10.;
74 dx->x_drift =
dx->x_drift / 10.;
75 dx->delta_x =
dx->delta_x / 10.;
76 dx->x_width_m =
dx->x_width_m / 10.;
77 dx->x_width_p =
dx->x_width_p / 10.;
References alpha, PVValHelper::dx, RemoveAddSevLevel::flag, HiCaloJetParameters_cff::interpolate, SiStripPI::max, MB_DT_drift_distance(), Geom::pi(), mathSSE::sqrt(), and protons_cff::time.
Referenced by DTParametrizedDriftAlgo::compute().
bool DTTime2DriftParametrization::computeDriftDistance_mode |
( |
double |
time, |
|
|
double |
alpha, |
|
|
double |
by, |
|
|
double |
bz, |
|
|
short |
interpolate, |
|
|
drift_distance * |
dx |
|
) |
| const |
unsigned short DTTime2DriftParametrization::MB_DT_drift_distance |
( |
double |
time, |
|
|
double |
alpha, |
|
|
double |
by, |
|
|
double |
bz, |
|
|
drift_distance * |
DX, |
|
|
short |
interpolate |
|
) |
| const |
|
private |
Calculate drift distance and spread.
Definition at line 85 of file DTTime2DriftParametrization.cc.
87 unsigned short i,
j, n_func, ial, iby, ibz;
88 unsigned short i_alpha, i_By, i_Bz;
89 unsigned short j_alpha, j_By, j_Bz;
95 double V_al[3], V_by[3], V_bz[3];
97 double DXV_v_drift[N_Func];
98 double DXV_x_drift[N_Func];
99 double DXV_delta_x[N_Func];
100 double DXV_x_width_m[N_Func];
101 double DXV_x_width_p[N_Func];
114 for (
j = 0;
j < N_Func;
j++) {
118 DXV_x_width_m[
j] = -1;
119 DXV_x_width_p[
j] = -1;
128 printf(
"*** ERROR, MB_DT_drift_distance: invalid interpolate value = %d\n",
interpolate);
136 printf(
"\nMB_DT_drift_distance: Function called with values:\n\n");
137 printf(
"MB_DT_drift_distance: time = %f\n",
time);
138 printf(
"MB_DT_drift_distance: alpha = %f\n",
alpha);
139 printf(
"MB_DT_drift_distance: by = %f\n", by);
140 printf(
"MB_DT_drift_distance: bz = %f\n", bz);
160 printf(
"MB_DT_drift_distance:\n");
161 printf(
"MB_DT_drift_distance: i_alpha j_alpha alpha_value's %d %d %.0f %.0f\n",
166 printf(
"MB_DT_drift_distance: i_By j_By By_value's %d %d %.2f %.2f\n",
171 printf(
"MB_DT_drift_distance: i_Bz j_Bz Bz_value's %d %d %.2f %.2f\n",
180 for (
j = 0;
j < n_func;
j++) {
181 ial = (
j & 4) ? j_alpha : i_alpha;
182 iby = (
j & 2) ? j_By : i_By;
183 ibz = (
j & 1) ? j_Bz : i_Bz;
186 par_x[
i] =
fun_x[ial][iby][ibz][
i];
192 DXV_v_drift[
j] = par_x[0];
195 DXV_x_drift[
j] =
MB_DT_dist(
time, par_x) + DXV_delta_x[
j] - OffSet * par_x[0];
202 printf(
"MB_DT_drift_LOOP: OffSet = %f\n", OffSet);
203 printf(
"MB_DT_drift_LOOP: time, v_drift, x_drift, lin, x_width_m, x_width_p = %f %f %f %f %f %f\n",
216 DX->v_drift = DXV_v_drift[0];
217 DX->delta_x = DXV_delta_x[0];
218 DX->x_drift = DXV_x_drift[0];
219 DX->x_width_m = DXV_x_width_m[0];
220 DX->x_width_p = DXV_x_width_p[0];
240 printf(
"MB_DT_drift_distance: time, v_drift, x_drift, lin, x_width_m, x_width_p = %f %f %f %f %f %f\n",
References alpha, alpha_value, By_value, Bz_value, DTTime2DriftParametrization::drift_distance::delta_x, fun_sigma_t, fun_x, mps_fire::i, HiCaloJetParameters_cff::interpolate, dqmiolumiharvest::j, MB_DT_Check_boundaries(), MB_DT_delta_x(), MB_DT_dist(), MB_DT_Get_grid_points(), MB_DT_MLInterpolation(), MB_DT_sigma_t_m(), MB_DT_sigma_t_p(), N_Par_x, N_Sigma_t, protons_cff::time, DTTime2DriftParametrization::drift_distance::v_drift, DTTime2DriftParametrization::drift_distance::x_drift, DTTime2DriftParametrization::drift_distance::x_width_m, and DTTime2DriftParametrization::drift_distance::x_width_p.
Referenced by computeDriftDistance_mean(), and computeDriftDistance_mode().