Approximating solutions of boundary value problems