cartan
is a package which implements the calculus of differential
forms. Included are facilities for computing exterior products,
contraction of vectors and forms, exterior derivatives, and Lie
derivatives. The differential forms are given in terms of the natural
basis forms derived from the coordinates on the manifold. Type
load(cartan);
to load this package. For a demonstration, type
demo(cartan);
cartan
was implemented by F.B. Estabrook and H.D. Wahlquist.
Initializes some global variables for the package. The argument, a
Maxima list, is an ordered list of coordinates. The coordinate list is
stored as the value of the variable cartan_coords
. The value of
the variable cartan_basis
is a list of the basis 1-forms. The
dimension is stored as the value of the variable cartan_dim
.
(%i1) load("cartan")$ (%i2) init_cartan([x,y,z]); (%o2) [dx, dy, dz] (%i3) cartan_basis; (%o3) [dx, dy, dz] (%i4) cartan_dim; (%o4) 3
The tilde “~” is an infix operator which denotes the exterior (wedge)
product. The canonical ordering of the products is determined by the
order in which the coordinates were specified. For example, if the
coordinate list is specified as [x,y,z]
, then the two-form
dy~dx
simplifies to -dx~dy
.
(%i1) init_cartan([x,y,z]); (%o1) [dx, dy, dz] (%i2) vr:[v1,v2,v3]; (%o2) [v1, v2, v3] (%i3) f1:x~dy+z~dz; (%o3) z dz + x dy (%i4) f2:dz~f1; (%o4) - x dy dz
The bar “|” is an infix operator which defines the contraction of a vector on a form. The vector should be given on the left.
The exterior derivative operator. It takes one argument, which should be a differential form.
The Lie derivative operator. The first argument is a vector field. The second argument may be either a vector field or a differential form.
(Note: display2d is set to false in the following example.)
(%i1) init_cartan([x,y,z]); (%o1) [dx,dy,dz] (%i2) vr:[v1,v2,v3]; (%o2) [v1,v2,v3] (%i3) f1:x ~ dy+z ~ dz; (%o3) z*dz+x*dy (%i4) vr | f1; (%o4) v3*z+v2*x (%i5) f2:dz ~ f1; (%o5) -(x*dy*dz) (%i6) ext_diff(f1); (%o6) dx*dy (%i7) ext_diff(f3(x,y,z) ~ dx); (%o7) -('diff(f3(x,y,z),z,1)*dx*dz)-'diff(f3(x,y,z),y,1)*dx*dy (%i8) depends([v1,v2,v3],[x,y,z]); (%o8) [v1(x,y,z),v2(x,y,z),v3(x,y,z)] (%i9) lie_diff(vr,f2); (%o9) -('diff(v3,z,1)*x*dy*dz)-'diff(v2,y,1)*x*dy*dz-v1*dy*dz -'diff(v2,x,1)*x*dx*dz+'diff(v3,x,1)*x*dx*dy (%i10) depends([w1,w2,w3],[x,y,z]); (%o10) [w1(x,y,z),w2(x,y,z),w3(x,y,z)] (%i11) wr:[w1,w2,w3]; (%o11) [w1,w2,w3] (%i12) lie_diff(vr,wr); (%o12) [-('diff(v1,z,1)*w3)-'diff(v1,y,1)*w2+v3*'diff(w1,z,1)+v2*'diff(w1,y,1) +v1*'diff(w1,x,1)-'diff(v1,x,1)*w1, -('diff(v2,z,1)*w3)+v3*'diff(w2,z,1)+v2*'diff(w2,y,1)+v1*'diff(w2,x,1) -'diff(v2,y,1)*w2-'diff(v2,x,1)*w1, v3*'diff(w3,z,1)+v2*'diff(w3,y,1)+v1*'diff(w3,x,1)-'diff(v3,z,1)*w3 -'diff(v3,y,1)*w2-'diff(v3,x,1)*w1]