  Aims: Little information exists on the circumstellar molecular abundance
stratifications of many molecules. The aim is to study the circumstellar
chemical abundance pattern of 11 molecules and isotopologs ($^{12}$CO,
$^{13}$CO, SiS, $^{28}$SiO, $^{29}$SiO, $^{30}$SiO, HCN, CN, CS, SO, SO$_2$) in
the oxygen-rich evolved star IK~Tau. Methods: We have performed an in-depth
analysis of a large number of molecular emission lines excited in the
circumstellar envelope around IK~Tau. The analysis is done based on a non-local
thermodynamic equilibrium (non-LTE) radiative transfer analysis, which
calculates the temperature and velocity structure in a self-consistent way. The
chemical abundance pattern is coupled to theoretical outer wind model
predictions including photodestruction and cosmic ray ionization. Not only the
integrated line intensities, but also the line shapes, are used as diagnostic
tool to study the envelope structure. Results: The deduced wind acceleration is
much slower than predicted from classical theories. SiO and SiS are depleted in
the envelope, possibly due to the adsorption onto dust grains. For HCN and CS a
clear difference with respect to inner wind non-equilibrium predictions is
found, either indicating uncertainties in the inner wind theoretical modeling
or the possibility that HCN and CS (or the radical CN) participate in the dust
formation. The low signal-to-noise profiles of SO and CN prohibit an accurate
abundance determination; the modeling of high-excitation SO$_2$ lines is
cumbersome, possibly related to line misidentifications or problems with the
collisional rates. The SiO isotopic ratios ($^{29}$SiO/$^{28}$SiO and
$^{30}$SiO/$^{28}$SiO) point toward an enhancement in $^{28}$SiO compared to
results of classical stellar evolution codes. Predictions for H$_2$O lines in
the spectral range of the Herschel/HIFI mission are performed. [abbreviated]
