Illusions can help to understand perception by offering clues when and how perception fails. While hallucinations are defined as a false perception in the absence of stimulation, induced by drugs or other influences, illusions are misinterpretations of stimuli consistently experienced. The horizon illusion, in which the moon appears larger on the horizon than at the zenith was discussed in antiquity, and is still the subject of study. Illusions show the complexity of visual perception but there is no satisfying theory for many of these illusions, or even of the reasons why they should exist. They can be documented and classified though and they do have some practical applications. Illusions are no more or less illusory than anything else but it is an illusion in the technical sense that if you take a physical measurement and compare that to your perceptual judgment, there's a discrepancy. There are several types of visual illusion that are characteristic artifacts of the visual system and give clues to underlying processes. A long list of optical illusions demonstrates some of these mechanisms. A lot of them have to do with dimensional effects and/or background/foreground effects resulting from a failure of estimation, or from the faulty comparison of distances or objects. Illusions are also related to contrast of brightness and ambiguity. A picture drawn on a flat background is a deliberate illusion attempt to trick the eye into perceiving a three-dimensional scene, the skill of perceiving depth and perspective in a painting is learned and not innate. Since the eye, because the retina is two-dimensional, must do something similar in its normal functioning this is very effective. Adaptation, where the ambient illumination comes to appear as white as possible, and color constancy, where colors are interpreted similarly under different conditions of illumination are not illusions but fundamental and useful properties of the color sense.
From sensation, the reception of stimulation of the environment and the initial encoding into the nervous system to perception, the cognitive processes through which we interpret messages those sensors provide, it is a human cognitive tendency to construct meaningful perception from fragments of sensory information and to group objects into well organized whole structures instead of isolated parts. This grouping of features into perceptual wholes is based on rules like proximity, similarity, continuation, closure and common fate direction. Cognitive illusions or the illusions of knowing are analogous to optical illusions with a systematic discrepancy between a judged answer and a correctly measured answer. Individuals are subject to very consistent and predictable errors in judgment. These errors of reason are not due to lack of expertise or intelligence but are embedded in the fundamental mechanisms by which we process information.