The nice development described below is work in collaboration with Pascal Szriftgiser from Laboratoire PhLAM, Université Lille 1, France, used in the Mapleprimes post Magnetic traps in coldatom physics
A new keyword in Define and Setup : minimizetensorcomponents, allows for automatically minimizing the number of tensor components taking into account the tensor symmetries. For example, if a tensor with two indices in a 4D spacetime is defined as antisymmetric using Define with this new keyword, the number of different tensor components will be exactly 6, and the elements of the diagonal are automatically set equal to 0. After setting this keyword to true with Setup , all subsequent definitions of tensors automatically minimize the number of components while using this keyword with Define makes this minimization only happen with the tensors being defined in the call to Define .
Related to this new functionality, 4 new Library routines were added: MinimizeTensorComponents, NumberOfIndependentTensorComponents, RelabelTensorComponents and RedefineTensorComponents
Example:
> 

Define an antisymmetric tensor with two indices
> 


(1.1) 
Although the system knows that is antisymmetric, you need to use Simplify to apply the (anti)symmetry
> 


(1.2) 
> 


(1.3) 
so by default the components of do not automatically reflect the (anti)symmetry; likewise
> 


(1.4) 
> 


(1.5) 
and computing the array form of we do not see the elements of the diagonal equal to zero nor the lowerleft triangle equal to the upperright triangle but for a different sign:
> 


(1.6) 
On the other hand, this new functionality, here called minimizetensorcomponents, makes the symmetries of the tensor be explicitly reflected in its components.
There are three ways to use it. First, one can minimize the number of tensor components of a tensor previously defined. For example
> 


(1.7) 
After this, both (1.2) and (1.3) are automatically equal to 0 without having to use Simplify
> 


(1.8) 
> 


(1.9) 
And the output of TensorArray in (1.6) becomes equal to (1.7).
NOTE: in addition, after using minimizetensorcomponents in the definition of a tensor, say F, all the keywords implemented for Physics tensors are available for F:
> 


(1.10) 
> 


(1.11) 
> 


(1.12) 
> 


(1.13) 
Alternatively, one can define a tensor, specifying that the symmetries should be taken into account to minimize the number of its components passing the keyword minimizetensorcomponents to Define .
Example:
Define a tensor with the symmetries of the Riemann tensor, that is, a tensor of 4 indices that is symmetric with respect to interchanging the positions of the 1st and 2nd pair of indices and antisymmetric with respect to interchanging the position of its 1st and 2nd indices, or 3rd and 4th indices, and define it minimizing the number of tensor components
> 


(1.14) 
We now have
> 


(1.15) 
> 


(1.16) 
• 
One can always retrieve the symmetry properties in the abstract notation used by the Define command using the new , its output is ordered, first the symmetric then the antisymmetric properties

> 


(1.17) 
• 
After making the symmetries explicit (and also before that), it is frequently useful to know the number of independent components of a given tensor. For this purpose you can use the new

> 


(1.18) 
and besides taking into account the symmetries, in the case of the Riemann tensor, after taking into account the first Bianchi identity this number of components is further reduced to 20.
A third way of using the new minimizetensorcomponents functionality is using Setup , so that, automatically, every subsequent definition of tensors with symmetries is performed minimizing the number of its components using the indicated symmetries
Example:
> 


(1.19) 
So from hereafter you can define tensors taking into account their symmetries explicitly and without having to include the keyword at each definition
> 


(1.20) 
> 


(1.21) 
• 
Two new related functionalities are provided via and , the first one to have the number of tensor components directly reflected in the names of the components, the second one to redefine only one of these components

> 


(1.22) 
Suppose now we want to make one of these components equal to 1, say
> 


(1.23) 
This nice development is work in collaboration with Pascal Szriftgiser from Laboratoire PhLAM, UMR CNRS 8523, Université Lille 1, F59655, France.
