Wikipedia:Reference desk/Archives/Mathematics/2009 May 28

= May 28 =

Wolfram Alpha exponentiation quirk?
Wolfram Alpha, given the input x^x, gives a graph that shows a positive real part and a negative imaginary part for -1 < x < 0. But Google (e.g. -0.5^-0.5) gives negative real numbers for the same function in the same range. Is this some quirk of Wolfram Alpha, or is there actually more than one way to evaluate the function? Neon Merlin  04:19, 28 May 2009 (UTC)
 * Look at the parenthesization on the Google result. It's not (&minus;0.5)^(&minus;0.5), but rather &minus;(0.5^(&minus;0.5)).  Much as I hate to combine the words Wolfram and right, I think Wolfram is right in this case.
 * However there is indeed more than one way to evaluate the function &mdash; it depends on which branch of the logarithm you take. Real-to-real exponentiation, xy, is properly defined only for x&gt;0.  For negative x you need to use complex-valued exponentiation. --Trovatore (talk) 05:51, 28 May 2009 (UTC)
 * You forgot the third option, that this could have been some quirk of Google calculator. Those exist too. -- Meni Rosenfeld (talk) 08:21, 28 May 2009 (UTC)

It's not a "quirk" of google causing it to give a wrong answer; rather the user entered the information incorrectly. Look at this. Michael Hardy (talk) 20:42, 28 May 2009 (UTC)
 * When it comes to believing a mathematical result from either one of Wolfram's Mathematica and Google's calculator, I will choose Mathematica any time. Yes, but input has to be the same in both for comparison. - DSachan (talk) 10:13, 29 May 2009 (UTC)

Solving for a matrix...
I've looked around for the answer to this. I learned a lot and added to total least squares in the process, but I don't have a solution to the exact problem I have in mind. Suppose I have two corresponding point clouds, X and Y, in $$R^n$$, both centered on the origin. If one is approximately a rigid-body rotation of the other, I can solve the orthogonal Procrustes problem to find a rotation matrix, R, such that $$Y=RX$$. If I know it's an unconstrained total least squares problem, I can solve for the matrix M such that $$Y=MX$$.

Suppose I want to find a symmetric positive definite matrix, S, with determinant 1 such that
 * $$SY=SRX$$

where R is the rotation matrix above? It seems like this is the same as solving
 * $$M=S^{-1}RS$$

for M and R above. This seems like it should be easy, but I'm not seeing it. Thanks. —Ben FrantzDale (talk) 13:49, 28 May 2009 (UTC)


 * sorry, what you want is not completely clear. Would you shortly reformulate the problem more clearly? ("given X ,Y, R such and such, find S such that etc"). thanks --194.95.184.202 (talk) 07:11, 29 May 2009 (UTC)
 * Oops. I wrote it wrong above. It should be $$SY=RSX$$. But yea, sure. Given Y and X (both 3&times;n), and given a 3&times;3 rotation matrix, R, find a symmetric positive definite matrix with determinant of one, S such that $$SY=RSX$$ in the least-squares sense. That is,
 * $$\operatorname{argmin}_{S\in \mathrm{SPD} \atop \det(S) = 1} \| Y - S^{-1}RSX\|_F$$
 * Alternately, since total least squares lets me solve $$Y=MX$$ and since R can be found by the orthogonal Procrustes problem, I think this reduces to the problem: Solve $$M=S^{-1}RS$$ for S with known M and R. —Ben FrantzDale (talk) 13:21, 29 May 2009 (UTC)