Output light from an optical cavity includes, for each of a set of modes,
an intensity function. Analyte can be positioned in the cavity, and a
mode's intensity function can be encoded to include information about an
optical characteristic of an analyte. For example, the intensity function
can include a peak, and its central energy, maximum intensity, contrast,
or intermediate intensity width (e.g. FWHM) can indicate the optical
characteristic. For example, the information can be about both refractive
index and absorption of an analyte.