Here is a program to demonstrate the working of a laser. Laser is a device that creates a uniform and coherent light, unlike an ordinary bulb light. Many lasers deliver light in an almost perfectly parallel (collimated) beam, approaching a single wavelength. Laser light can be focused down to a tiny spot as small as a single wavelength.
How a laser works
Laser is an acronym for ‘Light Amplification by Stimulated Emission of Radiation.’ It emits high-intensity, amplified beam of light due to stimulation of atoms. Laser beam is shown in Fig. 1.
A laser can be as small as a microscopic computer chip or as huge as the National Ignition Facility (NIF), which is three football fields wide.
Lasers are possible due to the way light interacts with atom. In an atom, electrons exist at specific energy levels. Electrons in outer orbit rings are at higher energy levels than those in inner rings. These can be bumped up to higher energy levels by the injection of energy—for example, by a flash of light.
Once an electron moves to a higher-energy orbit, it eventually wants to return to the ground state. When it does, it releases the excess energy as a photon—a particle of light. The emitted photon has a very specific wavelength (colour) that depends on the state of the electron’s energy when the photon is released. Fig. 3 shows emission of light. The light and an electron in an excited energy level produce two photons of the same wavelength and phase.
Standard laser. A standard laser is a tube where a particular substance is held. The atoms in that substance are excited to give off a particular wavelength of light. One end of the tube is heavily mirrored. At the other end is a partially silvered mirror. Photons of light bounce off the mirrors, exciting other atoms as well.
The tube is surrounded by a strong, coiled light source called a flash lamp. When the flash lamp sends a charge of light into the ruby tube, a chain reaction begins on the sub-atomic level causing generation of a large number of highly excited photons.
These photons race back and forth at nearly the speed of light between the two mirrored ends of the tube, producing even more photons until the number of photons exceeds the ability of the partially silvered end of the tube to hold them all. When this point is reached, the photons burst out of the partially silvered end of the tube in the form of a highly intense, concentrated beam of light that we know as laser beam.
Application of lasers
Lasers are used for everything from media storage to medicine and manufacturing. Their precision and energy allow users to very accurately measure or convey information:
Medicines. The pinpoint beam of a laser can focus precisely on a target and make highly delicate incisions. This newfound precision achieved by using lasers has drastically changed medicine. High-precision operations are now possible, thanks to lasers.
Supermarket scanners. In the grocery store these days, the supermarket checkers use laser technology to instantly find the right price and information for your purchases. 3D scanners are also available in the market.
Measurement. Lasers make fantastic rulers. These measure distances with a very high accuracy. There are two major ways a laser can do this. One way a laser can measure distance is by time of flight. The other method makes use of an interferometer.
Military. In military, IR countermeasure systems use lasers to confuse the seeker heads on heat-seeking anti-aircraft missiles. High-power, boost-phase intercept laser systems use a complex system of lasers to find, track and destroy intercontinental ballistic missiles.
Some weapons simply use a laser to disorient a person. One such weapon is the Thales green laser optical warner.
Another military use of lasers is as a laser target designator. This is a low-power laser pointer used to indicate a target for a precision-guided munition, typically launched from an aircraft.
Cutting tools. Lasers produce such an intense and precisely focused energy that they can cut through metals, ceramics, plastics and cloths. They have become popular in many industrial operations because high-precision, computer-controlled lasers are much more accurate than human-operated cutting tools and, unlike traditional tools, laser beams never turn blunt.
Scientific research. Since the laser was patented in 1958, it has become smaller, more precise and more powerful today. Nuclear fusion, spectroscopy and cooling atoms are some of the laser applications in scientific research.
Microscopy. Confocal laser scanning microscopy and two-photon excitation microscopy make use of lasers to obtain blur-free images of thick specimen at various depths. Laser-capture micro-dissection uses lasers to procure specific cell populations from a tissue section under microscopic visualisation.
The above laser concepts have been taken into consideration while developing this program. The program is written in ‘C’ language and compiled using Turbo C integrated development environment. Turbo C has a good collection of graphics libraries. This program uses various ‘C’ graphics files including egavga.bgi, scri.chr, trip.chr and tscr.chr. All these files should be stored in the same folder as the executable file.
The different program outputs depict working of a laser as below:
Amplification of photons. The first program output screen demonstrates generation of multiple photons inside the laser due to amplification from a single photon (see Fig. 4).
Release of photons. The second screen demonstrates the stimulation process of an atom where a photon stimulates the atom to release more photons (refer Fig. 5). The arrows have been added in the actual screenshot to show the flow taking place.
Inside the laser. The third screen (Fig. 6) demonstrates the complete process that takes place inside the laser. Proper flow is presented in which photons energise by the application of power supply, amplify with stimulation of the atoms and exit the laser through the semi-silvered mirror. The symbols of the photon and the atom are displayed on the top left.
End of demo. The final screen prompts the user to press any key to exit the program.
Main functions used
Initgraph(&gd,&gm,”c:\\turboc3\\bgi”). Initialises the graphics system by loading a graphics driver from the disk and then putting the system into graphics mode. It also resets all the graphics settings (like colour, palette and current position) to their default values.
*gd. Specifies the graphics driver to be used.
*gm. Specifies the initial graphics mode, unless *gd = DETECT. When *gd = DETECT, initgraph sets the graphics mode to the highest resolution available for the detected driver.
Closegraph( ). Switches the screen back from graphics mode to text mode. It is called after getch( ) function so that the screen doesn’t clear until the user hits the key.
Void projectwork1( ). Demonstrates amplification of photons.
Void projectwork2( ). Demonstrates stimulation of an atom to release photons.
Void projectwork3( ). Demonstrates how laser works.
Void closing. Provides an exit screen to exit the program.
Download source code: click here
The author is a software developer in Amdocs Development Centre India Pvt Ltd, Pune