Bromine water is an orange solution of bromine. It becomes colourless when it is shaken with an alkene. Alkenes can decolourise bromine water, but alkanes cannot. The slideshow shows this process.
The longest unbranched chain containing the functional group is the parent molecule, or simply the longest unbranched chain for alkanes. Remember that, the longest chain can go round a bend.
A dilute solution of bromine is added to samples of heptane and cyclohexene. The bromination reactions and mechanisms are compared. UV light splits the bromine molecule into two reactive radicals, ...