8 #include "GaudiKernel/MsgStream.h"
22 for (
unsigned int k = 0;
k < sample_points.size();
k++) {
24 x_min = sample_points[
k].x1();
27 if (x_min > sample_points[
k].
x1()) { x_min = sample_points[
k].x1(); }
28 if (x_max < sample_points[
k].
x1()) { x_max = sample_points[
k].x1(); }
43 std::vector<double> rt_param(
order + 3);
46 std::vector<SamplePoint> my_points(sample_points);
51 get_min_max(sample_points, rt_param[0], rt_param[1]);
53 double mean(0.5 * (rt_param[1] + rt_param[0]));
54 double length(rt_param[1] - rt_param[0]);
55 for (
unsigned int k = 0;
k < my_points.size();
k++) { my_points[
k].set_x1(2 * (sample_points[
k].
x1() -
mean) /
length); }
60 fitter.fit_parameters(my_points, 1, sample_points.size(), chebyshev);
62 for (
unsigned int k = 0;
k <
order + 1;
k++) { rt_param[
k + 2] =
fitter.coefficients()[
k]; }
79 for (
unsigned int i = 0;
i < sample_points.size();
i++) {
80 pars[2 *
i] = sample_points[
i].x1();
81 pars[2 *
i + 1] = sample_points[
i].x2();
86 unsigned int nb_points(100);
88 std::vector<double> rt_param(nb_points + 2);
98 return rt_relation_look_up;