Rigorous Analysis of Finite Periodic Structures in Dielectric Waveguides