Matlab program files for images

A gray-scale image is just a special graph of a function of two variables that takes values between 0 and 1. The graph is white where the function equals 1, it is black where the function is 0, and is various shades of gray for intermediate values. It can be manipulated like any other function, and you can add or average two different images, as you would add or average two functions. In practice, the image data is stored in a matrix whose entries are numbers between 0 and 1. For the examples loaded in the file images.m below, the matrices are 200 by 320. Color images are not much different. They simply have 3 functions (or matrices), one showing the red intensity, one for blue, and one for green.


Loading images and making simple modifications