Square-root algorithms for structured matrices, interpolation, and completion problems