  The aim of this manuscript is to discuss the Hilbert-Kunz functions over an
excellent local ring regular in codimension one. We study the shape of the
Hilbert-Kunz functions of modules and discuss the properties of the coefficient
of the second highest term in the function.
  Our results extend Huneke, McDermott and Monsky's result (Math. Res. Lett. 11
(2004), no. 4, 539-546) about the shape of the Hilbert-Kunz functions, and a
theorem of the second author (J. Algebra 304 (2006), no. 1, 487-499) for rings
with weaker conditions. In this paper, for a Cohen-Macaulay ring, we also
explores an equivalence condition under which the second coefficient vanishes
whenever the Hilbert-Kunz function of the ring is considered with respect to an
ideal primary to the maximal ideal and of finite projective dimension. We
introduce an additive error of the Hilbert-Kunz functions of modules on a short
exact sequence and give an estimate of such error.
