Periodic structures having a period shorter than the light wavelength and optically defined by a permittivity tensor field (epsilon) (r) are considered to discuss some boundary effects evidenced in chiral smectic liquid crystals by a numerical analysis. A more general approach to the problem of the boundary effects is given by considering the exact equations for the propagation of light in periodic media and making use of the coupled wave method. For structures periodic in only one direction q, the boundary effects strongly depend on the angle (theta) between q and the boundary normal v. They are related to the existence of a boundary layer where the electromagnetic field is rapidly changing, owing to the presence of surface waves strongly attenuated along v. The thickness of the layer is comparable to the crystal period for (theta) equals(pi) /2, increases by decreasing (theta) , and diverges for sin (theta) equal to n(p/(lambda) ), where n is an average refractive index. Below this value it is no more possible to separate bulk and boundary effects, and the very existence of a macroscopic model becomes questionable. More precisely, no macroscopic model is able to correctly describe the properties related to the spatial dispersion, as for instance the optical activity and the depolarized reflection. Similar considerations can be done for 2D and 3D crystals, but the surface effects are more complex because different boundary layers are associated to the different vectors q of the reciprocal lattice. The thickness of the layer depends again on the angle (theta) q between q and v, and diverges for small enough (theta) q.