我在看代码的时候:fitLine2D_wods
t = (float) atan2( 2 * dxy, dx2 - dy2 ) / 2;
line[0] = (float) cos( t );
line[1] = (float) sin( t );
我不明白这个陈述的意思:
t = (float) atan2( 2 * dxy, dx2 - dy2 ) / 2;
你能帮忙解释一下吗?
我觉得应该是这个
https://www.mathsisfun.com/data/least-squares-regression.html
我试图在整个网站上搜索它,但没有有用的信息。
就是“Inertia principal axis (? Sorry, I don’t know how this word in English)”的方向(角度)公式。