tensor
act
perform an action on either a tensor_type, a spin coefficient table and curvature component table
Calling Sequence
Parameters
Description
Examples
act( action, args[2..nargs])
action
-
name that is recognized by act() to designate the action wanted to be performed on an object.
args[2..nargs]
contains the objects to be acted upon and additional parameters depending on the specified action.
Important: The tensor package has been deprecated. Use the superseding packages DifferentialGeometry and Physics instead.
action usually is the name of an admissible procedure, and,
acts on precisely ONE algebraic argument, and
the "target" argument it acts on is its FIRST argument. (Most of the standard functions like simplify(), normal() fall into this category.) Note: an admissible procedure may employ extra or optional argument(s), as long as they come after the "target" one in the parameter list, e.g. simplify( .. , trig ).
There are, however, two exceptions :
action can take the name display, used as a flag. In which case act displays the nonzero element/component(s) of the parameter immediately after it which is presumably either a tensor_type, spin coefficient table or a curvature component table.
action can also take subs, which is a maple function. subs is an exception because the "target" object in the function subs() is the last parameter.
To reinforce, any other input to action (which then must be the name of a procedure) must abide by the restrictions (1) and (2) above.
args[2..nargs] - if action was input 'display', then this contains ONE argument which is the object to display.
args[2..nargs] - if action is an "admissible" procedure name, then this is essentially the argument sequence of the procedure "action", including any possible extra arguments needed to specify the operation wanted, except the target argument is now of a more complex structure than just algebraic.
This function is part of the tensor package, and can be used in the form act(..) only after performing the command with(tensor), or with(tensor, act). The function can always be accessed in the long form tensor[act].
with⁡tensor:
U_compts≔array⁡symmetric,1..2,1..2:
U_compts1,1≔x:U_compts1,2≔1−sin⁡t2−cos⁡t2:U_compts2,2≔y:
U≔create⁡1,−1,op⁡U_compts
U≔table⁡compts=x1−sin⁡t2−cos⁡t21−sin⁡t2−cos⁡t2y,index_char=1,−1
Z≔act⁡subs,t=z,x=x+x⁢y,U
Z≔table⁡compts=x⁢y+x1−sin⁡z2−cos⁡z21−sin⁡z2−cos⁡z2y,index_char=1,−1
act⁡factor,Z
table⁡compts=x⁢y+11−sin⁡z2−cos⁡z21−sin⁡z2−cos⁡z2y,index_char=1,−1
V≔act⁡simplify,Z,trig
V≔table⁡compts=x⁢y+100y,index_char=1,−1
act⁡display,V
NON-ZERO INDEPENDENT COMPONENTS :"[2, 2] ="
"[1, 1] ="
CHARACTER :
INDEXING FUNCTION :
_____________________________________________________
y
x⁢y+1
1,−1
symmetric
S_tble≔table⁡κ=x,σ=x,ρ=x,τ=y,ε=y,α=y,β=z,γ=z,ν=z,λ=0,μ=0,pi=0
S_tble≔table⁡τ=y,ρ=x,σ=x,γ=z,β=z,ν=z,α=y,π=0,κ=x,λ=0,ε=y,μ=0
S_tble≔act⁡subs,y=sin⁡y2+cos⁡y2,S_tble
S_tble≔table⁡τ=sin⁡y2+cos⁡y2,ρ=x,σ=x,γ=z,β=z,ν=z,α=sin⁡y2+cos⁡y2,π=0,κ=x,λ=0,ε=sin⁡y2+cos⁡y2,μ=0
act⁡simplify,S_tble
table⁡τ=1,ρ=x,σ=x,γ=z,β=z,ν=z,α=1,π=0,κ=x,λ=0,ε=1,μ=0
act⁡display,S_tble:
NON-ZERO SPIN COEFFICIENTS :"tau ="
"rho ="
"sigma ="
"gamma ="
"beta ="
"nu ="
"alpha ="
"kappa ="
"epsilon ="
sin⁡y2+cos⁡y2
x
z
PHI≔array⁡0..2,0..2:
forifrom0to2doforjfrom0to2doPHIi,j≔cat⁡PHI,i,jenddoenddo:PSI≔array⁡0..4,PSI0,PSI1,PSI2,PSI3,PSI4:Curve≔table⁡Φ=op⁡PHI,Ψ=op⁡PSI,R=R
Curve≔table⁡R=R,Ψ=array⁡0..4,0=PSI0,1=PSI1,2=PSI2,3=PSI3,4=PSI4,Φ=array⁡0..2,0..2,0,0=PHI00,0,1=PHI01,0,2=PHI02,1,0=PHI10,1,1=PHI11,1,2=PHI12,2,0=PHI20,2,1=PHI21,2,2=PHI22
Curve2≔act⁡subs,PHI00=0,PHI11=sin⁡t2,R=tan⁡t,PSI2=x2,PSI3=x⁢y3,PSI0=0,PSI1=0,PSI4=0,PHI22=0,PHI11=0,PHI01=x,PHI10=x,PHI02=y,PHI20=y,PHI12=z,PHI21=z,Curve
Curve2≔table⁡R=tan⁡t,Ψ=array⁡0..4,0=0,1=0,2=x2,3=x⁢y3,4=0,Φ=array⁡0..2,0..2,0,0=0,0,1=x,0,2=y,1,0=x,1,1=sin⁡t2,1,2=z,2,0=y,2,1=z,2,2=0
act⁡simplify,Curve2
table⁡R=tan⁡t,Ψ=array⁡0..4,0=0,1=0,2=x2,3=x⁢y3,4=0,Φ=array⁡0..2,0..2,0,0=0,0,1=x,0,2=y,1,0=x,1,1=sin⁡t2,1,2=z,2,0=y,2,1=z,2,2=0
act⁡display,Curve2
NON-ZERO CURVATURE COMPONENTS :`Psi[2] =`
`Psi[3] =`
R =
x2
x⁢y3
tan⁡t
%a ,Phi[1, 2] =
%a ,Phi[1, 0] =
%a ,Phi[0, 1] =
%a ,Phi[2, 0] =
%a ,Phi[1, 1] =
sin⁡t2
%a ,Phi[0, 2] =
%a ,Phi[2, 1] =
See Also
tensor(deprecated)
Download Help Document