surana4u
surana4u

Reputation: 31

Algorithm for connecting geometric lines

I have n open geometric lines in 3D. which need to be joined into a single line based upon the criteria that minimum length of additional lines between the end points of the lines. Please suggest algorithm which have minimum complexity.

Upvotes: 3

Views: 727

Answers (1)

Yakov Galka
Yakov Galka

Reputation: 72539

A best known algorithm runs in O(2n) time. As Andrew Said in his comment, this is a more general version of traveling salesmen problem. If you find a better algorithm you'll be awarded a $1000000 prize.

You should try approximated solutions instead, see wikipedia.

Upvotes: 1

Related Questions