SamplePublisher`GrassmannCalculus`
TransferScalar |
|
| | ||||
Details and Options
Examples
(1)
Basic Examples
(1)
In[1]:=
<<GrassmannCalculus`
In[2]:=
★ |
5
The following transfers a scalar from the first factor to the third factor in the product.
In[3]:=
(a)⋀⋀⋀⋀%//
[a,{1,3}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[3]=
(a)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[3]=
e
1
e
2
e
3
e
4
e
5
It only transfers the specified scalar.
In[4]:=
(ab)⋀⋀⋀⋀%//
[a,{1,3}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[4]=
(ab)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[4]=
(b)⋀⋀(a)⋀⋀
e
1
e
2
e
3
e
4
e
5
Specifying for the scalar transfers all scalars in the first position.
Automatic
In[5]:=
(ab)⋀⋀⋀⋀%//
[Automatic,{1,3}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[5]=
(ab)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[5]=
e
1
e
2
e
3
e
4
e
5
Specifying for a position moves from or to the outside an expression.
All
In[6]:=
(a)⋀⋀⋀⋀%//
[Automatic,{1,All}]%//
[Automatic,{All,5}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
TransferScalar |
Out[6]=
(a)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[6]=
a⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[6]=
e
1
e
2
e
3
e
4
e
5
The scalar does not have to be in .
position1
In[7]:=
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[7]=
e
1
e
2
e
3
e
4
e
5
Out[7]=
(c)⋀⋀⋀⋀
e
1
e
2
e
3
c
e
4
e
5
If either position is not a positive integer or All, or if the scalar is not Automatic or a valid scalar expression the routine will return unevaluated. If a position is a positive integer but beyond the length of the product an error message is given and the calculation aborted.
The following don't evaluate because the scalar is not a scalar.
In[8]:=
(b)⋀⋀⋀⋀%//
[p,{1,2}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[8]=
(b)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[8]=
TransferScalar[p,{1,2}][(b)⋀⋀⋀⋀]
e
1
e
2
e
3
e
4
e
5
In[9]:=
(b)⋀⋀⋀⋀%//
[aaxv,{1,2}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[9]=
(b)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[9]=
TransferScalar[aaxv,{1,2}][(b)⋀⋀⋀⋀]
e
1
e
2
e
3
e
4
e
5
The following fails because the positions are outside the product.
In[10]:=
(b)⋀⋀⋀⋀%//
[Automatic,{7,6}]
e
1
e
2
e
3
e
4
e
5
TransferScalar |
Out[10]=
(b)⋀⋀⋀⋀
e
1
e
2
e
3
e
4
e
5
Out[10]=
$Aborted
Transfer between nested products must be done in steps.
In[11]:=
((a)⋀)⋄(⋀)MapAt
[Automatic,{1,All}],%,1%//
[Automatic,{1,2}]MapAt
[Automatic,{All,2}],%,2
e
1
e
2
e
3
e
4
TransferScalar |
TransferScalar |
TransferScalar |
Out[11]=
((a)⋀)⋄(⋀)
e
1
e
2
e
3
e
4
Out[11]=
(a⋀)⋄(⋀)
e
1
e
2
e
3
e
4
Out[11]=
(⋀)⋄(a⋀)
e
1
e
2
e
3
e
4
Out[11]=
(⋀)⋄(⋀(a))
e
1
e
2
e
3
e
4
In[12]:=
a⋀%//
[Automatic,{All,1}]MapAt
[Automatic,{All,2}],%,1
e
1
e
2
TransferScalar |
TransferScalar |
Out[12]=
a⋀
e
1
e
2
Out[12]=
a⋀
e
1
e
2
Out[12]=
e
1
e
2
Scalar factors may also be processed.
In[13]:=
e
1
e
4
TransferScalar |
Out[13]=
e
1
e
4
Out[13]=
e
1
e
4
|
|
""

