An approximation theory for boundary value problems on infinite intervals