Boundary formulation of propagation and coupling problems in integrated optics