Check the tutorial link,
http://arduino.cc/en/Tutorial/Fade

and below tutorial video