View Single Post
Andy-M's Avatar Andy-M Andy-M is offline Super Moderator 2008-03-13 #6 Old  
Hmm well thinking it through, it's possible to figure out, but not pretty.

Essentially you'll have to work off these equations:

A = A1 + A2 = x*cos(t) + y*sin(t)
B = B1 + B2 = y*cos(t) + x*sin(t)

which will give you:

A1 + A2 = something
B1 + B2 = something

however there's not enough information right there.

So then you have to add extra equations such as:

A1^2 + B2^2 = x^2
A2^2 + B1^2 = y^2

Then solve for all four equations:

A1 + A2 = x*cos(t) + y*sin(t)
B1 + B2 = y*cos(t) + x*sin(t)
A1^2 + B2^2 = x^2
A2^2 + B1^2 = y^2

Now actually this is where I was wrong before: it's not linear for the last two equations so you can't easily use matrices (or systems of LINEAR equations). I would actually solve it using a greedy algorithm from there (i.e. guess and check).
Reply With Quote