       Matrix/tensor algebra shortcuts?

• To: mathgroup at smc.vnet.net
• Subject: [mg119615] Matrix/tensor algebra shortcuts?
• From: Hauke Reddmann <fc3a501 at uni-hamburg.de>
• Date: Mon, 13 Jun 2011 05:18:16 -0400 (EDT)

```Two questions. My tensors are very sparse, in fact if
it has e.g. two upper and one lower index T_ab_c, then
the only nonzero elements have a+b=c. (This is general,
always sum of upper=sum of lower.) Clearly, if I could
avoid carrying through all the zeroes I could save
a factor n (and already at dimension n=10 Mathematica
chokes on time and space ressources for my problems).
Do you have a more elegant way than throwing all Outer[]
and Dot[] and so on out of the window and programming
everything with Do[] loops?
Another thing. Sometimes I don't even want to specify
the matrices and just need a formal noncommutative
multiplication "knowing" that Z°(l*(Y+W))°(X*m)=
l*m*Z°Y°X+l*m*Z°W°X (where of course ° is some matrix
multiplication sign, * is normal scalar multiplication,
and scalar, distributive and associative properties
should be executed latest on an Expand[] command.
How can I define me a ° with these properties?
Please answer n00b-friendly. :-)
--
Hauke Reddmann <:-EX8    fc3a501 at uni-hamburg.de
Leierklang und ein flammendes Inferno grüßen dich
auf das Allerzärtlichste

```

• Prev by Date: Re: Is there ToNumber?
• Next by Date: Re: Is there ToNumber?
• Previous by thread: Re: Is there ToNumber?
• Next by thread: Question with ToExpression