Exact and numerical solutions for effective diffusivity and time lag through multiple layers