I got your example up and going, and I've tried a few of my own. I've
tried to tackle some elementary examples so I could learn exactly what
maxima is doing. My examples culminate with an attempt at finding the
'extra terms' I discuss in my original posting. Some of
these give the results I would expect, others do not. If you could help
me track down my errors, it would be greatly appretiated.
These commands assume you have just completed the ex.mc script you
attached previously.
div(u cross v)
expr : diff(lch([k,l,m],[])*u([],[l])*v([],[m]),k);
grad(u dot v)
expr : diff(u([],[i])*v([],[i]),j);
Tensor dyad vv
expr : v([],[i])*v([],[j]);
u dot vv
expr : u([],[i])*v([],[i])*v([],[j]);
curl (u dot vv)
expr : diff(lch([k,l,j],[])*u([],[i])*v([],[i])*v([],[j]),k);
u cross div(vv)
expr : lch([l,k,j],[])*u([],[k])*diff(v([],[i])*v([],[j]),i);
curl (u dot vv) - u cross div(vv)
expr : diff(lch([k,l,j],[])*u([],[i])*v([],[i])*v([],[j]),k)-
lch([l,k,j],[])*u([],[k])*diff(v([],[i])*v([],[j]),i);
Also, if you could reveal the method by which you came up with this
sequence of simplifying commands, it would be appretiated.
SHOW(CANFORM(CONTRACT(CANFORM(TRFTKDT(EXPAND(EXPR))))))
Thanks for all the help,
Rob
On Thu, 6 Mar 2003, Valerij Pipin wrote:
> Hi
> I would advise to use itensor. The following will work under
> clisp,cmucl,sbcl (for gcl you should compile itensor before).
> (C1) batch("ex.mc");
>
> batching /home/vpip/work/math/emf/emf_ro/tmp/ex.mc
> (C2) LOAD(use.mc)
> (D2) use.mc
> (C3) BOTHCASES : FALSE
> (D3) FALSE
> (C4) LOAD(itensor)
> (D4) /usr/local/share/maxima/5.9.0.1cvs/share/tensor/itensor.lisp
> (C5) DUMMYX : U
> (D5) U
> (C6) DIM : 3
> (D6) 3
> (C7) ALLSYM : FALSE
> (D7) FALSE
> (C8) DECLARE(LCH, CONSTANT)
> (D8) DONE
> (C9) DECSYM(LCH, 0, 3, [], [CYC(ALL), ANTI(ALL)])
> (D9) DONE
> (C10) DECSYM(LCH, 3, 0, [CYC(ALL), ANTI(ALL)], [])
> (D10) DONE
> (C11) EXPR : LCH([], [I, J, K]) DIFF(LCH([K, L, M], []) U([], [L]) V([],
> [M]),
>
>
> J)
> (D11) LCH([], [I, J, K]) (U([], [L]) V([], [M], J) LCH([K, L, M], [])
>
> + U([], [L], J) V([], [M]) LCH([K, L,
> M], []))
> (C12) SHOW(CANFORM(CONTRACT(CANFORM(TRFTKDT(EXPAND(EXPR))))))
> I U1 I U1 I U1 I U1
> (D12) U V - V U + U V - V U
> ,U1 ,U1 ,U1 ,U1
> (C13)
>
> Rob McDonald wrote:
> > Martin was kind enough to answer some of my questions in a newsgroup, and to
> > direct me towards Maxima, and thereby here.
> >
> > I need to work with vector & tensor (dyad) derivatives (grad, div, curl,
> > tensor div) abstractly. I don't want the CAS program to try to evaluate the
> > derivative itself, rather it should be left as an operator. Thereby
> > something like
> >
> > DECLARE([u,v],nonscalar);
> > VECTORSIMP(CURL(v ~ u));
> >
> > should return something akin to
> >
> > u*div(v)-v*div(u)+(v dot del)u-(u dot del)v
> >
> > We have been discussing some elementary forms related to my larger problem;
> > baby steps are always a good idea. But, to put my problem into perspective,
> > I'll state it here.
> >
> > I am looking for an alternate form of the expression on the LHS. The first
> > term on the RHS is an educated guess (and may well be quite wrong), and
> > I would like to see how it pans out. I need to figure out exactly what
> > those
> > other terms are.
> >
> > curl ( u dot vv ) = u cross div (vv) + other terms...
> >
> > Where (vv) is the tensor dyad formed from the arbitrary vector (v); and (u)
> > is a vector such that div(u)=0 and curl(u)=0.
> >
> > I have just downloaded 5.9.0 binaries, and have poked around a bit, but like
> > Martin, I have not been able to make much progress following what vect.mac
> > and vector.mac from CVS would suggest.
> >
> > Thanks for your time and any suggestions,
> >
> > Rob McDonald
> >