Refactor MST implementation

Remove unnecessary copies, and move logic to a new namespace.
Add stub for MultipleCurve problem