Create several images of the following function: double f(double x, double y, double kx, double ky, int nx, int ny) { return 0.5*(x/nx)*(1+cos( kx* x*x))*(y/ny)*(1+cos(ky*y*y)); } where the image has nx by ny pixels and on the coordinate system where (x,y) \in [0,nx] x [0,ny] For all items except for number 5, use a box filter, i.e., color = INTEGRAL INTEGRAL f(x,y) dy dx where the limits are (i,i+1) x (j,j+1) create 9 images with (nx,ny) = (512,384) and kx=0.004 and ky=0.006: 0. Analytic solution 1. MC Integration, 16 random samples 2. MC Integration, 16 stratified samples 3. MC Integration, 100 random samples 4. MC Integration, 100 stratified samples 5. MC Inegration, 100 random samples, bspline filter 6. Density Estimation, 100 random samples per pixel on average 7. Density Estimation, 100 stratified samples per pixel on average 8. Metropolis, 100 random samples per pixel on average For number 5, generate a random sample location as follows: x = i + 0.5 y = j + 0.5 for k = 0; k < 4; k++ x += drand48()-0.5 y += drand48()-0.5