Here’s the long and short of it: A lens that electronically switches its focus from far to near may someday provide an alternative to traditional bifocal lenses.
The natural lens in your eye is supposed to bend light rays and focus them on the retina at the back of the eye. If the eye is misshapen or not strong enough to do the job itself, glasses help bend the light rays through a process called refraction–the same one that makes a stick appear to kink when one end is submerged in water. Just how much a given lens bends light depends on its precise shape and curvature. Bifocals are essentially two lenses ground into a single piece of glass or plastic. In contrast, the new electronic lens is flat and focuses light through a phenomenon known as diffraction, in which light waves overlap either peak-to-trough to cancel one another out, or peak-to-peak to reinforce one another.
More here.