Text this: A path integral approach to the coupled-mode equations with specific reference to optical waveguides