Open xcarnd opened 6 years ago
derivative for ∂atan2(y,x)/∂x is actually -y/(x^2+y^2) instead of -x/(x^2+y^2). same for ∂atan2(y,x)/∂y.
Wolfram alpha result for reference (I've done that by hand too, same as result from wolfram alpha)
http://www.wolframalpha.com/input/?i=differentiate+atan2(y,x)
I also think the second row in Jacobian should be like following: [-x[1] / (x[0]2 + x[1]2), x[0] / (x[0]2 + x[1]2)] Surprisingly either way estimation result is about the same.
derivative for ∂atan2(y,x)/∂x is actually -y/(x^2+y^2) instead of -x/(x^2+y^2). same for ∂atan2(y,x)/∂y.
Wolfram alpha result for reference (I've done that by hand too, same as result from wolfram alpha)
http://www.wolframalpha.com/input/?i=differentiate+atan2(y,x)