added mc sampling