double[][] graySmooth(BufferedImage image) {
		double[][] graySmoothed = new double[image.getWidth()][image.getHeight()];
		for(int x = 0; x < graySmoothed.length; ++x) {
			for(int y = 0; y < graySmoothed[x].length; ++y) {
				if(x < 1 || x >= graySmoothed.length - 1 || y < 1 || y >= graySmoothed[x].length - 1) {
					graySmoothed[x][y] = grayscale(image.getRGB(x, y));
					continue;
				}
				graySmoothed[x][y] = smooth(x, y, image);
			}
		}
		return graySmoothed;
	}