diff options
author | jthorn <jthorn@f88db872-0e4f-0410-b76b-b9085cfa78c5> | 2002-09-03 15:08:31 +0000 |
---|---|---|
committer | jthorn <jthorn@f88db872-0e4f-0410-b76b-b9085cfa78c5> | 2002-09-03 15:08:31 +0000 |
commit | 8d5bce0424da13d921bb1945534249610e5c26ec (patch) | |
tree | 9508a6d5fda9c1a710e5de5157155af649a57766 | |
parent | f35b18c89fb683112994c8bc1322ae8417bb6d95 (diff) |
move these files here from ../gr/
git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinAnalysis/AHFinderDirect/trunk@704 f88db872-0e4f-0410-b76b-b9085cfa78c5
-rw-r--r-- | src/driver/ellipsoid.c | 28 | ||||
-rw-r--r-- | src/driver/ellipsoid.log | 38 |
2 files changed, 66 insertions, 0 deletions
diff --git a/src/driver/ellipsoid.c b/src/driver/ellipsoid.c new file mode 100644 index 0000000..49a6457 --- /dev/null +++ b/src/driver/ellipsoid.c @@ -0,0 +1,28 @@ +fp t1, t2, t3, t5, t6, t7, t9, t10, t12, t28; +fp t30, t33, t35, t36, t40, t42, t43, t48, t49, t52; +fp t55; + t1 = a*a; + t2 = b*b; + t3 = t1*t2; + t5 = t3*zcos*CW; + t6 = c*c; + t7 = t1*t6; + t9 = t7*ycos*BV; + t10 = t2*t6; + t12 = t10*xcos*AU; + t28 = xcos*xcos; + t30 = CW*CW; + t33 = BV*BV; + t35 = t10*t28; + t36 = ycos*ycos; + t40 = AU*AU; + t42 = t7*t36; + t43 = zcos*zcos; + t48 = t3*t43; + t49 = -2.0*t1*zcos*CW*ycos*BV-2.0*t2*zcos*CW*xcos*AU-2.0*t6*ycos*BV*xcos* +AU+t2*t28*t30+t6*t28*t33-t35+t1*t36*t30+t6*t36*t40-t42+t1*t43*t33+t2*t43*t40- +t48; + t52 = sqrt(-t3*t6*t49); + t55 = 1/(t35+t42+t48); + r_plus = (t5+t9+t12+t52)*t55; + r_minus = (t5+t9+t12-t52)*t55; diff --git a/src/driver/ellipsoid.log b/src/driver/ellipsoid.log new file mode 100644 index 0000000..71cad20 --- /dev/null +++ b/src/driver/ellipsoid.log @@ -0,0 +1,38 @@ + |\^/| Maple 7 (IBM INTEL LINUX) +._|\| |/|_. Copyright (c) 2001 by Waterloo Maple Inc. + \ MAPLE / All rights reserved. Maple is a registered trademark of + <____ ____> Waterloo Maple Inc. + | Type ? for help. +# ellipsoid.maple -- compute equations for offset ellipsoid setup +# $Header$ +> +# +# ellipsoid has center (A,B,C), radius (a,b,c) +# angular coordinate system has center (U,V,W) +# +# direction cosines wrt angular coordinate center are (alpha,beta,gamma) +# but Maple predefines gamma = Euler's constant, so we use (xcos,ycos,zcos) +# instead, i.e. a point has coordinates (U+xcos*r, V+ycos*r, W+zcos*r) +# +# then the equation of the ellipsoid is +# (U+xcos*r - A)^2 (V+ycos*r - B)^2 (W+zcos*r - C)^2 +# ----------------- + ---------------- + ----------------- = 1 +# a^2 b^2 c^2 +# +# to solve this, we introduce intermediate variables +# AU = A - U +# BV = B - V +# CW = C - W +# +> eqn := (xcos*r - AU)^2/a^2 + (ycos*r - BV)^2/b^2 + (zcos*r - CW)^2/c^2 = 1; + 2 2 2 + (xcos r - AU) (ycos r - BV) (zcos r - CW) + eqn := -------------- + -------------- + -------------- = 1 + 2 2 2 + a b c + +> +> read "../maple/util.mm"; +Error, unable to read `../maple/util.mm` +> quit +bytes used=129844, alloc=196572, time=0.03 |