View Single Post
  #9  
Old January 14th, 2008, 05:13 AM
ris8_allo_zen0 ris8_allo_zen0 is offline
Newbie
 
Join Date: Jan 2008
Posts: 6
Country:
Thanks: 0
Thanked 0 Times in 0 Posts
ris8_allo_zen0 is on a distinguished road
Default

Ok, I think I'm on the right way now.

Let's call \alpha_1 the angle between x and y, and \alpha_2 the one between y and z.
x and z join the "external" corners with the observer, and y joins the one which is farthest from the obs. Thus, y is between the two and is shared between \alpha_1 and \alpha_2.
\gamma_1 and \gamma_2 are the angles opposite to x and z, respectively. Since we're working on a half-square, their sum is \frac{\pi}{2}.

These are the calculations to be done, exploting theorems of sines and cosines:
\gamma_1=\arcsin(x \sin(\alpha_1))
y=\sqrt{x^2+1-2x \cos(\pi-\alpha_1-\gamma_1)}
\gamma_2=\frac{\pi}{2}-\gamma_1
z=\sqrt{y^2+1-2y \cos(\gamma_2)}
\alpha_2=\arcsin \left( \frac{\sin \left( \gamma_2 \right) }{z}  \right)

(am I correct until here?)

So the the computer's mission is to find an x value such as the calculated \alpha_2 is near enough to the given \alpha_2. This can be done in a way I'll investigate soon


Thanks mr fantastic to pointing me to the right direction!!!

Last edited by ris8_allo_zen0; January 14th, 2008 at 07:19 AM. Reason: math latex adjust
Reply With Quote