Re: Quaternion problem--> Jacobian derivation/ Metric
- To: mathgroup at smc.vnet.net
- Subject: [mg68137] Re: Quaternion problem--> Jacobian derivation/ Metric
- From: Roger Bagula <rlbagula at sbcglobal.net>
- Date: Tue, 25 Jul 2006 04:01:43 -0400 (EDT)
- References: <e7ap5q$952$1@smc.vnet.net> <e7lf1d$3l9$1@smc.vnet.net> <e7no3j$97f$1@smc.vnet.net> <e9ri0i$pa1$1@smc.vnet.net> <e9sukq$rl6$1@smc.vnet.net> <ea25uv$1cn$1@smc.vnet.net>
- Sender: owner-wri-mathgroup at wolfram.com
SU(3) Rodrigues Jacobian using Paul's better version: jacobian = D[Exp[r0]*{Cos[ r], Sin[r]*Sin[p]*Cos[t], Sin[r]* Sin[p]*Sin[t], Sin[r]*Cos[p], Cos[r1], Sin[ r1]*Sin[p1]*Cos[t1], Sin[r1]*Sin[p1]*Sin[t1]}, {{r0, t, p, r, t1, p1, r1,}}] MatrixForm[jacobian] Tr[ Transpose[jacobian] . jacobian, List] // Simplify I Paul Abbott wrote: >In article <e9sukq$rl6$1 at smc.vnet.net>, > Roger Bagula <rlbagula at sbcglobal.net> wrote: > > > >>I did Jacobians and metrics way back in Mathematica using >>a Jacobian matrix form from Theoretical Mechanics ,Ames and Murnagham, >>Dover Books. >> >> > >D was extended to compute the Jacobian directly in version 5.1. >Alternatively, you can compute the Jacobian using Outer: > > Outer[D, f, vars] > >where f is list of functions and vars is a list of variables. > > > >>(*The hard way: there has got to be a more compact way of doing this!*) >> >> > >Indeed there is. > > > >>Exp[r]*{Cos[d], Sin[d]*Sin[p]*Cos[t], Sin[d]*Sin[p]*Sin[t], Sin[d]*Cos[p]} >>x = Exp[r]*Sin[d]*Sin[p]*Cos[t] >>y = Exp[r]*Sin[d]*Sin[p]*Sin[t] >>z = Exp[r]*Sin[d]*Cos[p] >>t0 = Exp[r]*Cos[d] >>xr = D[x, r] >>yr = D[y, r] >>zr = D[z, r] >>tr = D[t0, r] >>xt = D[x, t] >>yt = D[y, t] >>zt = D[z, t] >>tt = D[t0, t] >>xp = D[x, p] >>yp = D[y, p] >>zp = D[z, p] >>tp = D[t0, p] >>xd = D[x, d] >>yd = D[y, d] >>td = D[t0, d] >> >> > >No need to explicitly define x, y, z, and t0. The Jacobian is just > > jacobian = D[Exp[r] {Cos[d], Sin[d] Sin[p] Cos[t], > Sin[d] Sin[p] Sin[t], Sin[d] Cos[p]}, {{r,t,p,d}}]; > >Alternatively in Mathematica pre 5.1, > > jacobian = Outer[D, Exp[r] {Cos[d], Sin[d] Sin[p] Cos[t], > Sin[d] Sin[p] Sin[t], Sin[d] Cos[p]}, {r,t,p,d}]; > > > >>h1 = FullSimplify[1/Sqrt[xr^2 + yr^2 + zr^2 + tr^2]] >>h2 = FullSimplify[1/Sqrt[xt^2 + yt^2 + zt^2 + tt^2]] >>h3 = FullSimplify[1/Sqrt[xp^2 + yp^2 + zp^2 + tp^2]] >>h4 = FullSimplify[1/Sqrt[xd^2 + yd^2 + zd^2 + td^2]] >> >>rra = Simplify[Expand[1/h1^2]] >>tta = Simplify[Expand[1/h2^2]] >>ppa = Simplify[Expand[1/h3^2]] >>dda = Simplify[Expand[1/h4^2]] >> >> >> >The square of the scale factors can be obtained directly as > > Tr[ Transpose[jacobian] . jacobian, List] // Simplify > >Cheers, >Paul > >_______________________________________________________________________ >Paul Abbott Phone: 61 8 6488 2734 >School of Physics, M013 Fax: +61 8 6488 1014 >The University of Western Australia (CRICOS Provider No 00126G) >AUSTRALIA http://physics.uwa.edu.au/~paul > > >