18 #define OUTPUT_PRECISION 10
21 #define D1 -0.5772156649015328605195174
22 #define D2 0.4227843350984671393993777
23 #define D4 1.791759469228055000094023
24 #define SQRTPI 0.9189385332046727417803297
25 #define FRTBIG 1.42E+09
26 #define PNT68 0.6796875
28 #define MACHINE_EPSILON 2.22044604925031e-016
34 double v00,
double v01,
double v02,
double v10,
double v11,
double v20)
45 double axx = 1.0/2.0*(v00 - 2*v10 + v20);
46 double axy = v00 - v01 - v10 + v11;
47 double ayy = 1.0/2.0*(v00 - 2*v01 + v02);
48 double bx = 1.0/2.0*(-3.0*v00 + 4*v10 - v20);
49 double by = 1.0/2.0*(-3.0*v00 + 4*v01 - v02);
53 return axx*x*x + axy*x*y + ayy*y*y + bx*x + by*y +
c;
63 long size = x->size();
64 if (size==1) {cout<<
"interpCubicDirect warning: table size = 1";
return (*y)[0];}
65 double dx = (*x)[1]-(*x)[0];
68 if (abs(x0-(*x)[0])<dx*1
e-30)
return (*y)[0];
71 long idx = floor((x0-(*x)[0])/dx);
73 if (idx<0 || idx>=size-1)
75 cout <<
"interpCubicDirect: x0 out of bounds." << endl
76 <<
"x ranges from " << (*x)[0] <<
" to " << (*x)[size-1] <<
", "
77 <<
"x0=" << x0 <<
", " <<
"dx=" << dx <<
", " <<
"idx=" << idx << endl;
84 double A0 = (*y)[0], A1 = (*y)[1], A2 = (*y)[2], deltaX = x0 - (*x)[0];
85 return (A0-2.0*A1+A2)/(2.0*dx*dx)*deltaX*deltaX - (3.0*A0-4.0*A1+A2)/(2.0*dx)*deltaX + A0;
90 double A0 = (*y)[size-3], A1 = (*y)[size-2], A2 = (*y)[size-1], deltaX = x0 - ((*x)[0] + (idx-1)*dx);
91 return (A0-2.0*A1+A2)/(2.0*dx*dx)*deltaX*deltaX - (3.0*A0-4.0*A1+A2)/(2.0*dx)*deltaX + A0;
96 double A0 = (*y)[idx-1], A1 = (*y)[
idx], A2 = (*y)[idx+1], A3 = (*y)[idx+2], deltaX = x0 - ((*x)[0] + idx*dx);
98 return (-A0+3.0*A1-3.0*A2+A3)/(6.0*dx*dx*dx)*deltaX*deltaX*deltaX
99 + (A0-2.0*A1+A2)/(2.0*dx*dx)*deltaX*deltaX
100 - (2.0*A0+3.0*A1-6.0*A2+A3)/(6.0*dx)*deltaX
115 long size = x->size();
116 if (size==1) {cout<<
"interpLinearDirect warning: table size = 1"<<endl;
return (*y)[0];}
117 double dx = (*x)[1]-(*x)[0];
120 if (abs(x0-(*x)[0])<dx*1
e-30)
return (*y)[0];
123 long idx = floor((x0-(*x)[0])/dx);
125 if (idx<0 || idx>=size-1)
127 cout <<
"interpLinearDirect: x0 out of bounds." << endl
128 <<
"x ranges from " << (*x)[0] <<
" to " << (*x)[size-1] <<
", "
129 <<
"x0=" << x0 <<
", " <<
"dx=" << dx <<
", " <<
"idx=" << idx << endl;
133 return (*y)[
idx] + ((*y)[idx+1]-(*y)[
idx])/dx*(x0-(*x)[
idx]);
146 long size = x->size();
147 if (size==1) {cout<<
"interpNearestDirect warning: table size = 1"<<endl;
return (*y)[0];}
148 double dx = (*x)[1]-(*x)[0];
151 if (abs(x0-(*x)[0])<dx*1
e-30)
return (*y)[0];
154 long idx = floor((x0-(*x)[0])/dx);
156 if (idx<0 || idx>=size-1)
158 cout <<
"interpNearestDirect: x0 out of bounds." << endl
159 <<
"x ranges from " << (*x)[0] <<
" to " << (*x)[size-1] <<
", "
160 <<
"x0=" << x0 <<
", " <<
"dx=" << dx <<
", " <<
"idx=" << idx << endl;
164 return x0-(*x)[
idx]>dx/2 ? (*y)[idx+1] : (*y)[
idx];
178 long size = x->size();
179 if (size==1) {cout<<
"interpCubicMono warning: table size = 1"<<endl;
return (*y)[0];}
182 if (abs(xx-(*x)[0])<((*x)[1]-(*x)[0])*1
e-30)
return (*y)[0];
187 if (idx<0 || idx>=size-1)
189 cout <<
"interpCubicMono: x0 out of bounds." << endl
190 <<
"x ranges from " << (*x)[0] <<
" to " << (*x)[size-1] <<
", "
191 <<
"xx=" << xx <<
", " <<
"idx=" << idx << endl;
198 return (*y)[0] + ( (*y)[1]-(*y)[0] )/( (*x)[1]-(*x)[0] )*( xx-(*x)[0] );
200 else if (idx==size-2)
203 return (*y)[size-2] + ( (*y)[size-1]-(*y)[size-2] )/( (*x)[size-1]-(*x)[size-2] )*( xx-(*x)[size-2] );
208 long double y0 = (*y)[idx-1], y1 = (*y)[
idx], y2 = (*y)[idx+1], y3 = (*y)[idx+2];
209 long double y01=y0-y1, y02=y0-y2, y03=y0-y3, y12=y1-y2, y13=y1-y3, y23=y2-y3;
210 long double x0 = (*x)[idx-1], x1 = (*x)[
idx], x2 = (*x)[idx+1], x3 = (*x)[idx+2];
211 long double x01=x0-x1, x02=x0-x2, x03=x0-x3, x12=x1-x2, x13=x1-x3, x23=x2-x3;
212 long double x0s=x0*
x0, x1s=x1*x1, x2s=x2*x2, x3s=x3*x3;
213 long double denominator = x01*x02*x12*x03*x13*x23;
214 long double C0, C1, C2, C3;
215 C0 = (x0*x02*x2*x03*x23*x3*y1
216 + x1*x1s*(x0*x03*x3*y2+x2s*(-x3*y0+x0*y3)+x2*(x3s*y0-x0s*y3))
217 + x1*(x0s*x03*x3s*y2+x2*x2s*(-x3s*y0+x0s*y3)+x2s*(x3*x3s*y0-x0*x0s*y3))
218 + x1s*(x0*x3*(-x0s+x3s)*y2+x2*x2s*(x3*y0-x0*y3)+x2*(-x3*x3s*y0+x0*x0s*y3))
220 C1 = (x0s*x03*x3s*y12
221 + x2*x2s*(x3s*y01+x0s*y13)
222 + x1s*(x3*x3s*y02+x0*x0s*y23-x2*x2s*y03)
223 + x2s*(-x3*x3s*y01-x0*x0s*y13)
224 + x1*x1s*(-x3s*y02+x2s*y03-x0s*y23)
226 C2 = (-x0*x3*(x0s-x3s)*y12
227 + x2*(x3*x3s*y01+x0*x0s*y13)
228 + x1*x1s*(x3*y02+x0*y23-x2*y03)
229 + x2*x2s*(-x3*y01-x0*y13)
230 + x1*(-x3*x3s*y02+x2*x2s*y03-x0*x0s*y23)
233 + x2s*(x3*y01+x0*y13)
234 + x1*(x3s*y02+x0s*y23-x2s*y03)
235 + x2*(-x3s*y01-x0s*y13)
236 + x1s*(-x3*y02+x2*y03-x0*y23)
248 return C0 + C1*xx + C2*xx*xx + C3*xx*xx*xx;
263 long size = x->size();
264 if (size==1) {cout<<
"interpLinearMono warning: table size = 1"<<endl;
return (*y)[0];}
267 if (abs(xx-(*x)[0])<((*x)[1]-(*x)[0])*1
e-30)
return (*y)[0];
272 if (idx<0 || idx>=size-1)
274 cout <<
"interpLinearMono: x0 out of bounds." << endl
275 <<
"x ranges from " << (*x)[0] <<
" to " << (*x)[size-1] <<
", "
276 <<
"xx=" << xx <<
", " <<
"idx=" << idx << endl;
280 return (*y)[
idx] + ( (*y)[idx+1]-(*y)[
idx] )/( (*x)[idx+1]-(*x)[
idx] )*( xx-(*x)[
idx] );
293 long size = x->size();
294 if (size==1) {cout<<
"interpNearestMono warning: table size = 1"<<endl;
return (*y)[0];}
297 if (abs(xx-(*x)[0])<((*x)[1]-(*x)[0])*1
e-30)
return (*y)[0];
302 if (idx<0 || idx>=size-1)
304 cout <<
"interpNearestMono: x0 out of bounds." << endl
305 <<
"x ranges from " << (*x)[0] <<
" to " << (*x)[size-1] <<
", "
306 <<
"xx=" << xx <<
", " <<
"idx=" << idx << endl;
310 return xx-(*x)[
idx] > (*x)[idx+1]-xx ? (*y)[idx+1] : (*y)[
idx];
318 double invertFunc(
double (*func)(
double),
double y,
double xL,
double xR,
double dx,
double x0,
double relative_accuracy)
334 double F0,
F1,
F2,
F3, X1, X2;
339 accuracy = dx*relative_accuracy;
346 XX1 = XX2-10*accuracy;
348 while (abs(XX2-XX1)>accuracy)
353 F0 = (*func)(XX1) - y;
369 F3 = (F1-
F2)/(X1-X2);
373 impatience = impatience + 1;
375 if (impatience>tolerance)
377 cout <<
"invertFunc: " <<
"max number of iterations reached." << endl;
397 long size = x->size();
398 if (size==1)
return (*y)[0];
411 stringstream sst(str+
" ");
412 vector<double> valueList;
415 while (sst.eof()==
false)
417 valueList.push_back(val);
428 stringstream sst(str+
" ");
448 vector< vector<double>* >*
data;
449 vector<double> valuesInEachLine;
455 stream_in.getline(buffer,99999);
458 lineSize = valuesInEachLine.size();
462 cout <<
"readBlockData warning: input stream has empty first row; no data read" << endl;
468 data =
new vector< vector<double>* >(lineSize);
469 for (i=0; i<lineSize; i++) (*data)[i] = new vector<double>;
473 while (stream_in.eof()==
false)
476 for (i=0; i<lineSize; i++) (*(*data)[
i]).push_back(valuesInEachLine[i]);
478 stream_in.getline(buffer,99999);
492 for (
unsigned long i=0;
i<
data->size();
i++)
delete (*
data)[
i];
504 double S,
double fa,
double fb,
double fc,
int bottom) {
505 double c = (a +
b)/2,
h = b - a;
506 double d = (a +
c)/2,
e = (c + b)/2;
507 double fd =
f(d), fe =
f(
e);
508 double Sleft = (
h/12)*(fa + 4*fd + fc);
509 double Sright = (
h/12)*(fc + 4*fe + fb);
510 double S2 = Sleft + Sright;
511 if (bottom <= 0 || fabs(S2 - S) <= 15*epsilon)
512 return S2 + (S2 - S)/15;
522 int maxRecursionDepth) {
523 double c = (a +
b)/2,
h = b - a;
524 double fa =
f(a), fb =
f(b),
fc =
f(c);
525 double S = (
h/6)*(fa + 4*
fc + fb);
533 double epsilon,
int maxRecursionDepth)
536 double f_1=
f(a)+
f(b), f_2=0., f_4=0.;
537 double sum_previous=0., sum_current=0.;
543 int currentRecursionDepth = 1;
546 sum_current = (length/6)*(f_1 + f_2*2. + f_4*4.);
550 sum_previous = sum_current;
558 sum_current = (length/6/
count)*(f_1 + f_2*2. + f_4*4.);
561 if (currentRecursionDepth>maxRecursionDepth)
563 cout << endl <<
"Warning qiu_simpsons: maximum recursion depth reached!" << endl << endl;
566 else currentRecursionDepth++;
568 }
while (abs(sum_current-sum_previous)>epsilon);
576 double epsilon,
int maxRecursionDepth)
579 double f_1=
f(a)+
f(b), f_2=0., f_4=0.;
580 double sum_previous=0., sum_current=0.;
586 int currentRecursionDepth = 1;
589 sum_current = (length/6)*(f_1 + f_2*2. + f_4*4.);
593 sum_previous = sum_current;
601 sum_current = (length/6/
count)*(f_1 + f_2*2. + f_4*4.);
604 if (currentRecursionDepth>maxRecursionDepth)
606 cout << endl <<
"Warning qiu_simpsons: maximum recursion depth reached!" << endl << endl;
609 else currentRecursionDepth++;
611 }
while (abs(sum_current-sum_previous)/(sum_current-sum_previous)>epsilon);
622 for (string::iterator
it=tmp.begin();
it<=tmp.end();
it++) *
it = tolower(*
it);
631 long number_of_char = 0;
632 for (
size_t ii=0; ii<str.size(); ii++)
633 if (str[ii]!=
' ' && str[ii]!=
'\t')
635 tmp[number_of_char]=str[ii];
638 tmp.resize(number_of_char);
651 int idx_i, idx_f,
idx;
654 if(value > (*A)[idx_f])
656 if (skip_out_of_range)
return -1;
657 cout <<
"binarySearch: desired value is too large, exceeding the end of the table." << endl;
660 if(value < (*A)[idx_i])
662 if (skip_out_of_range)
return -1;
663 cout <<
"binarySearch: desired value is too small, exceeding the beginning of table." << endl;
666 idx = (int) floor((idx_f+idx_i)/2.);
667 while((idx_f-idx_i) > 1)
673 idx = (int) floor((idx_f+idx_i)/2.);
690 long double ga,
gr,
r=0,
z;
692 static long double g[] = {
696 -0.420026350340952e-1,
698 -0.421977345555443e-1,
701 -0.11651675918591e-2,
719 if (x > 171.0)
return 1e308;
743 for (k=23;k>=0;k--) {
750 ga = -M_PI/(x*ga*sin(M_PI*x));
768 if (x <= 0 || x >
XBIG)
779 4.945235359296727046734888E+00, 2.018112620856775083915565E+02, 2.290838373831346393026739E+03,
780 1.131967205903380828685045E+04, 2.855724635671635335736389E+04, 3.848496228443793359990269E+04,
781 2.637748787624195437963534E+04, 7.225813979700288197698961E+03
785 6.748212550303777196073036E+01, 1.113332393857199323513008E+03, 7.738757056935398733233834E+03,
786 2.763987074403340708898585E+04, 5.499310206226157329794414E+04, 6.161122180066002127833352E+04,
787 3.635127591501940507276287E+04, 8.785536302431013170870835E+03
791 4.974607845568932035012064E+00, 5.424138599891070494101986E+02, 1.550693864978364947665077E+04,
792 1.847932904445632425417223E+05, 1.088204769468828767498470E+06, 3.338152967987029735917223E+06,
793 5.106661678927352456275255E+06, 3.074109054850539556250927E+06
797 1.830328399370592604055942E+02, 7.765049321445005871323047E+03, 1.331903827966074194402448E+05,
798 1.136705821321969608938755E+06, 5.267964117437946917577538E+06, 1.346701454311101692290052E+07,
799 1.782736530353274213975932E+07, 9.533095591844353613395747E+06
803 double xden = 1, xnum = 0, xm = x <= 1.5 ? (x > 0.5 ? x - 1 :
x) : x - 2;
805 if (x <= 1.5 && (x <= 0.5 || x >=
PNT68)) flag =
true;
806 double *
p = flag ? p1 : p2, *q = flag ? q1 : q2;
808 xnum = xnum * xm + p[0], xden = xden * xm + q[0];
809 xnum = xnum * xm + p[1], xden = xden * xm + q[1];
810 xnum = xnum * xm + p[2], xden = xden * xm + q[2];
811 xnum = xnum * xm + p[3], xden = xden * xm + q[3];
812 xnum = xnum * xm + p[4], xden = xden * xm + q[4];
813 xnum = xnum * xm + p[5], xden = xden * xm + q[5];
814 xnum = xnum * xm + p[6], xden = xden * xm + q[6];
815 xnum = xnum * xm + p[7], xden = xden * xm + q[7];
817 return (x > 1.5 ? 0 : corr) + xm * ((flag ?
D1 :
D2) + xm * (xnum / xden));
822 double xm = x - 4, xden = -1, xnum = 0,
825 1.474502166059939948905062E+04, 2.426813369486704502836312E+06, 1.214755574045093227939592E+08,
826 2.663432449630976949898078E+09, 2.940378956634553899906876E+010,1.702665737765398868392998E+011,
827 4.926125793377430887588120E+011, 5.606251856223951465078242E+011
831 2.690530175870899333379843E+03, 6.393885654300092398984238E+05, 4.135599930241388052042842E+07,
832 1.120872109616147941376570E+09, 1.488613728678813811542398E+010, 1.016803586272438228077304E+011,
833 3.417476345507377132798597E+011, 4.463158187419713286462081E+011
836 xnum = xnum * xm +
p[0], xden = xden * xm + q[0];
837 xnum = xnum * xm + p[1], xden = xden * xm + q[1];
838 xnum = xnum * xm + p[2], xden = xden * xm + q[2];
839 xnum = xnum * xm + p[3], xden = xden * xm + q[3];
840 xnum = xnum * xm + p[4], xden = xden * xm + q[4];
841 xnum = xnum * xm + p[5], xden = xden * xm + q[5];
842 xnum = xnum * xm + p[6], xden = xden * xm + q[6];
843 xnum = xnum * xm + p[7], xden = xden * xm + q[7];
845 return D4 + xm * (xnum / xden);
854 -1.910444077728E-03, 8.4171387781295E-04, -5.952379913043012E-04, 7.93650793500350248E-04,
855 -2.777777777777681622553E-03, 8.333333333333333331554247E-02, 5.7083835261E-03
858 res = res / xsq + c[0];
859 res = res / xsq + c[1];
860 res = res / xsq + c[2];
861 res = res / xsq + c[3];
862 res = res / xsq + c[4];
863 res = res / xsq + c[5];
865 double corr = log(x);
866 res /=
x, res +=
SQRTPI - corr / 2 + x * (corr - 1);
902 static int previous_stop=0;
916 for (
int i=1;
i<=
length;
i++) cout <<
" ";
924 if (percentage>=0.99) stop=0.99*
length;
925 else stop = percentage*
length;
926 for (
int i=previous_stop;
i<stop;
i++) cout << symbol;
927 if (previous_stop<stop) previous_stop=stop;
930 if (status==0) cout <<
"-";
933 case 1: cout <<
"\\";
break;
934 case 2: cout <<
"|";
break;
935 case 3: cout <<
"/";
break;
936 case 4: cout <<
"-";
break;
940 if (status==5) status=1;
952 os << scientific << setprecision(
OUTPUT_PRECISION) <<
" " << va_arg(ap,
double);
966 cout <<
" ____ ____ _ " << endl;
967 cout <<
"|_ || _| (_) " << endl;
968 cout <<
" | |__| | .---. __ _ .--. ____ " << endl;
969 cout <<
" | __ | / /__\\\\ [ | [ `.-. | [_ ] " << endl;
970 cout <<
" _| | | |_ | \\__., | | | | | | .' /_ " << endl;
971 cout <<
"|____||____| '.__.' [___] [___||__] [_____]" << endl;
976 cout <<
"::: ::: :::::::::: ::::::::::: :::: ::: :::::::::" << endl;
977 cout <<
":+: :+: :+: :+: :+:+: :+: :+: " << endl;
978 cout <<
"+:+ +:+ +:+ +:+ :+:+:+ +:+ +:+ " << endl;
979 cout <<
"+#++:++#++ +#++:++# +#+ +#+ +:+ +#+ +#+ " << endl;
980 cout <<
"+#+ +#+ +#+ +#+ +#+ +#+#+# +#+ " << endl;
981 cout <<
"#+# #+# #+# #+# #+# #+#+# #+# " << endl;
982 cout <<
"### ### ########## ########### ### #### #########" << endl;
986 cout <<
" __ __ ______ __ __ __ _____ " << endl;
987 cout <<
"/\\ \\_\\ \\ /\\ ___\\ /\\ \\ /\\ '-.\\ \\ /\\___ \\ " << endl;
988 cout <<
"\\ \\ __ \\ \\ \\ __\\ \\ \\ \\ \\ \\ \\-. \\ \\/_/ /__ " << endl;
989 cout <<
" \\ \\_\\ \\_\\ \\ \\_____\\ \\ \\_\\ \\ \\_\\\\'\\_\\ /\\_____\\" << endl;
990 cout <<
" \\/_/\\/_/ \\/_____/ \\/_/ \\/_/ \\/_/ \\/_____/" << endl;
1020 static const double EPS = 3.0e-14;
1022 for(
int i=0;
i<
m;
i++) {
1023 double t=cos(M_PI*(
i+1-0.25)/(npts+0.5));
1030 for(
int j=0;
j<npts;
j++) {
1034 p1=((2.0*aj-1.0)*t*p2-(aj-1.0)*p3)/aj;
1036 pp=npts*(t*p1-p2)/(t*t-1.0);
1039 }
while(abs(t-t1)>EPS);
1042 wg[
i]=2.0/((1.0-t*
t)*pp*pp);
1058 for(
int i=0;
i<
N;
i++) {
1061 xp=(B+
A)/2+(B-A)/2*xg[
i];
1063 }
else if(iop == -1) {
1065 xp=(B+
A)/2+(B-A)/2*xg[
i];
1071 }
else if(iop == 2) {
1073 xp=A*(1+xg[
i])/(1-xg[
i]);
1074 double tmp=(1-xg[
i]);
1075 wp=2.*A/(tmp*
tmp)*wg[i];
1076 }
else if(iop == 3) {
1078 xp=A*(xg[
i])/(1-xg[
i]*xg[
i]);
1079 double tmp=1-xg[
i]*xg[
i];
1080 wp=A*(1+xg[
i]*xg[
i])/(tmp*tmp)*wg[
i];
1081 }
else if(iop == 4) {
1083 xp=(A+2*B+A*xg[
i])/(1-xg[
i]);
1085 wp=2.*(B+
A)/(tmp*tmp)*wg[
i];
1086 }
else if(iop == 5) {
1089 double tmp = xg[
i] >= 0 ? 1.0 : -1.0;
1090 xp=A*pow(abs(xg[
i]),B) *
tmp;
1092 wp=A*B*pow(abs(xg[i]),(B-1))*wg[
i];
1093 }
else if(iop == 6) {
1095 xp=A*B*(1+xg[
i])/(B+A-(B-A)*xg[
i]);
1096 double tmp = B+A-(B-
A)*xg[
i];
1097 wp=2*A*B*B/(tmp*
tmp)*wg[
i];
1099 cerr <<
" invalid option iop = " << iop << endl;
1137 char*
buffer =
new char[99999];
1139 is.getline(buffer, 99999);
1141 long number_of_cols = line_data.size();
1142 long number_of_bins = bins->size()-1;
1144 if (number_of_cols==0)
1146 cout <<
"get_bin_average_and_count error: the input data is empty!" << endl;
1151 if (wanted_data_columns>0) number_of_cols = wanted_data_columns;
1152 double bin_total_and_count[number_of_bins][number_of_cols+2];
1153 for (
long i=0;
i<number_of_bins;
i++)
1154 for (
long j=0;
j<number_of_cols+2;
j++)
1156 bin_total_and_count[
i][
j] = 0;
1160 long number_of_lines=1;
1161 while (is.eof()==
false)
1164 long bin_idx =
binarySearch(bins, line_data[col_to_bin-1],
true);
1168 line_data.resize(number_of_cols, 0);
1169 if (func) (*func) (&line_data);
1171 for (
long j=0;
j<number_of_cols;
j++) bin_total_and_count[bin_idx][
j] += line_data[
j];
1173 bin_total_and_count[bin_idx][number_of_cols] ++;
1176 is.getline(buffer, 99999);
1178 if (number_of_lines % 100000 == 0 && !silence) cout <<
"Line " << number_of_lines <<
" reached." << endl;
1183 for (
long i=0;
i<number_of_bins;
i++)
1184 for (
long j=0;
j<number_of_cols;
j++)
1186 if (bin_total_and_count[
i][number_of_cols]<1
e-15)
continue;
1187 bin_total_and_count[
i][
j] /= bin_total_and_count[
i][number_of_cols];
1192 for (
long i=0;
i<number_of_bins;
i++)
1194 if (bin_total_and_count[
i][number_of_cols]<1
e-15)
continue;
1195 bin_total_and_count[
i][number_of_cols+1] = bin_total_and_count[
i][number_of_cols]/((*bins)[
i+1]-(*bins)[
i]);
1199 for (
long i=0;
i<number_of_bins;
i++)
1201 for (
long j=0;
j<number_of_cols+2;
j++)
1203 os << scientific << scientific << setprecision(
OUTPUT_PRECISION) << bin_total_and_count[
i][
j] <<
" ";