function y=gauss5pts(fh,a,b)
%assign sample points and weights
y5=[sqrt((5-2*sqrt(10/7))/9),sqrt((5+2*sqrt(10/7))/9)];
w5=[0.3*((-0.7+5*sqrt(0.7))/(-2+5*sqrt(0.7))),0.3*((0.7+5*sqrt(0.7))/(2+5*sqrt(0.7)))];
w05=128/225;
c1=(b-a)/2;
c2=(a+b)/2;
f0=fh(c2);
s5=w05*f0;
for i=1:2
    s5=s5+w5(i)*(fh(c2+c1*y5(i))+fh(c2-c1*y5(i)));
end
y=c1*s5;