The article presents a design of an optical filter using Photonic Band Gap (PBG) materials in the visible and infrared region of the electromagnetic spectrum. This idea is based on the famous Kronig-Penny model in the band theory of solids. The suggested filter may work at any range of the wavelength that can be achieved by choosing the appropriate values of the controlling parameters. This structure is also able to pass the light emitted by the Ruby laser and this acts as a monochromator. Also, we have studied the anomalous behavior of refractive index for the structure having alternate layers of air and GaAs.