A stable method to solve the Matrix Sturm-Liouville Equation for inhomogeneous layered structures. (December 2016)