26 #ifndef O2SCL_INTE_GAUSS56_CERN_H
27 #define O2SCL_INTE_GAUSS56_CERN_H
30 #include <boost/multiprecision/cpp_dec_float.hpp>
33 #include <o2scl/misc.h>
34 #include <o2scl/inte.h>
35 #include <o2scl/funct.h>
37 #ifndef DOXYGEN_NO_O2NS
69 x5[0]=4.6910077030668004e-02;
70 x5[1]=2.3076534494715846e-01;
71 x5[2]=5.0000000000000000e-01;
72 x5[3]=7.6923465505284154e-01;
73 x5[4]=9.5308992296933200e-01;
75 w5[0]=1.1846344252809454e-01;
76 w5[1]=2.3931433524968324e-01;
77 w5[2]=2.8444444444444444e-01;
78 w5[3]=2.3931433524968324e-01;
79 w5[4]=1.1846344252809454e-01;
81 x6[0]=3.3765242898423989e-02;
82 x6[1]=1.6939530676686775e-01;
83 x6[2]=3.8069040695840155e-01;
84 x6[3]=6.1930959304159845e-01;
85 x6[4]=8.3060469323313225e-01;
86 x6[5]=9.6623475710157601e-01;
88 w6[0]=8.5662246189585178e-02;
89 w6[1]=1.8038078652406930e-01;
90 w6[2]=2.3395696728634552e-01;
91 w6[3]=2.3395696728634552e-01;
92 w6[4]=1.8038078652406930e-01;
93 w6[5]=8.5662246189585178e-02;
129 x5[0]=0.04691007703066800360118656085030352L;
130 x5[1]=0.23076534494715845448184278964989560L;
132 x5[3]=0.76923465505284154551815721035010440L;
133 x5[4]=0.95308992296933199639881343914969648L;
135 w5[0]=0.11846344252809454375713202035995868L;
136 w5[1]=0.23931433524968323402064575741781910L;
137 w5[2]=0.28444444444444444444444444444444444L;
138 w5[3]=0.23931433524968323402064575741781910L;
139 w5[4]=0.11846344252809454375713202035995868L;
141 x6[0]=0.03376524289842398609384922275300270L;
142 x6[1]=0.16939530676686774316930020249004733L;
143 x6[2]=0.38069040695840154568474913915964403L;
144 x6[3]=0.61930959304159845431525086084035597L;
145 x6[4]=0.83060469323313225683069979750995267L;
146 x6[5]=0.96623475710157601390615077724699730L;
148 w6[0]=0.08566224618958517252014807108636645L;
149 w6[1]=0.18038078652406930378491675691885806L;
150 w6[2]=0.23395696728634552369493517199477550L;
151 w6[3]=0.23395696728634552369493517199477550L;
152 w6[4]=0.18038078652406930378491675691885806L;
153 w6[5]=0.08566224618958517252014807108636645L;
159 #if defined(O2SCL_LD_TYPES) || defined(DOXYGEN)
179 boost::multiprecision::cpp_dec_float_50
x5[5];
184 boost::multiprecision::cpp_dec_float_50
w5[5];
189 boost::multiprecision::cpp_dec_float_50
x6[6];
194 boost::multiprecision::cpp_dec_float_50
w6[6];
198 x5[0]=boost::multiprecision::cpp_dec_float_50
199 (
"4.69100770306680036011865608503035174371740446187346e-02");
200 w5[0]=boost::multiprecision::cpp_dec_float_50
201 (
"1.18463442528094543757132020359958681321630001106207e-01");
202 x5[1]=boost::multiprecision::cpp_dec_float_50
203 (
"2.30765344947158454481842789649895597516356696547220e-01");
204 w5[1]=boost::multiprecision::cpp_dec_float_50
205 (
"2.39314335249683234020645757417819096456147776671571e-01");
206 x5[2]=boost::multiprecision::cpp_dec_float_50
207 (
"5.00000000000000000000000000000000000000000000000000e-01");
208 w5[2]=boost::multiprecision::cpp_dec_float_50
209 (
"2.84444444444444444444444444444444444444444444444444e-01");
210 x5[3]=boost::multiprecision::cpp_dec_float_50
211 (
"7.69234655052841545518157210350104402483643303452780e-01");
212 w5[3]=boost::multiprecision::cpp_dec_float_50
213 (
"2.39314335249683234020645757417819096456147776671571e-01");
214 x5[4]=boost::multiprecision::cpp_dec_float_50
215 (
"9.53089922969331996398813439149696482562825955381265e-01");
216 w5[4]=boost::multiprecision::cpp_dec_float_50
217 (
"1.18463442528094543757132020359958681321630001106207e-01");
219 x6[0]=boost::multiprecision::cpp_dec_float_50
220 (
"3.37652428984239860938492227530026954326171311438551e-02");
221 w6[0]=boost::multiprecision::cpp_dec_float_50
222 (
"8.56622461895851725201480710863664467634112507420220e-02");
223 x6[1]=boost::multiprecision::cpp_dec_float_50
224 (
"1.69395306766867743169300202490047326496775717802415e-01");
225 w6[1]=boost::multiprecision::cpp_dec_float_50
226 (
"1.80380786524069303784916756918858055830760946373373e-01");
227 x6[2]=boost::multiprecision::cpp_dec_float_50
228 (
"3.80690406958401545684749139159644032290694684929989e-01");
229 w6[2]=boost::multiprecision::cpp_dec_float_50
230 (
"2.33956967286345523694935171994775497405827802884605e-01");
231 x6[3]=boost::multiprecision::cpp_dec_float_50
232 (
"6.19309593041598454315250860840355967709305315070011e-01");
233 w6[3]=boost::multiprecision::cpp_dec_float_50
234 (
"2.33956967286345523694935171994775497405827802884605e-01");
235 x6[4]=boost::multiprecision::cpp_dec_float_50
236 (
"8.30604693233132256830699797509952673503224282197585e-01");
237 w6[4]=boost::multiprecision::cpp_dec_float_50
238 (
"1.80380786524069303784916756918858055830760946373373e-01");
239 x6[5]=boost::multiprecision::cpp_dec_float_50
240 (
"9.66234757101576013906150777246997304567382868856145e-01");
241 w6[5]=boost::multiprecision::cpp_dec_float_50
242 (
"8.56622461895851725201480710863664467634112507420220e-02");
261 template<
class func_t=
funct,
class fp_t=double,
262 class weights_t=inte_gauss56_coeffs_double>
267 const fp_t *w5, *x5, *w6, *x6;
285 fp_t &res, fp_t &err) {
287 fp_t rang=b-a, e5=0.0, e6=0.0, ytmp;
289 for(
int i=0;i<5;i++) {
290 ytmp=func(a+rang*x5[i]);
292 ytmp=func(a+rang*x6[i]);
295 ytmp=func(a+rang*x6[5]);
297 res=(e6+e5)*rang/2.0;
305 #ifndef DOXYGEN_NO_O2NS