added gauss legendre contour to reduce integration