private double smooth(int x, int y, BufferedImage image) {
		double newValue = 0;
		for(int i = x - 1; i <= x + 1; ++i) {
			for(int j = y - 1; j <= y + 1; ++j) {
				newValue += grayscale(image.getRGB(i, j));
			}
		}
		return newValue/9;
	}