Eigenmath Manual
Eigenmath Manual
Eigenmath Manual
January 1, 2009
1
2
Contents
1 Introduction 3
1.1 Negative exponents . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2 Defining symbols . . . . . . . . . . . . . . . . . . . . . . . . . 5
2 Draw 8
3 Scripts 11
4 Complex numbers 13
5 Linear algebra 15
6 Calculus 17
6.1 Derivative . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
6.2 Gradient . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
6.3 Template functions . . . . . . . . . . . . . . . . . . . . . . . . 18
6.4 Integral . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
6.5 Arc length . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
6.6 Line integrals . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
6.7 Surface area . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
6.8 Surface integrals . . . . . . . . . . . . . . . . . . . . . . . . . 30
6.9 Green’s theorem . . . . . . . . . . . . . . . . . . . . . . . . . 31
6.10 Stokes’ theorem . . . . . . . . . . . . . . . . . . . . . . . . . . 33
7 More examples 34
7.1 François Viète . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
7.2 Curl in tensor form . . . . . . . . . . . . . . . . . . . . . . . . 35
7.3 Quantum harmonic oscillator . . . . . . . . . . . . . . . . . . 37
7.4 Hydrogen wavefunctions . . . . . . . . . . . . . . . . . . . . . 38
7.5 Space shuttle and Corvette . . . . . . . . . . . . . . . . . . . 39
7.6 Avogadro’s constant . . . . . . . . . . . . . . . . . . . . . . . 40
7.7 Zero to the zero power . . . . . . . . . . . . . . . . . . . . . . 41
8 Built-in functions 42
9 Syntax 54
3
1 Introduction
The following is an excerpt from Vladimir Nabokov’s autobiography Speak,
Memory.
3529471145760275132301897342055866171392
So Nabokov did get it right after all. We can enter float or click on the float
button to scale the number down to size.
float
3.52947 × 1039
Now let us see if Eigenmath can find the seventeenth root of this number,
like the Hindu calculator could.
N=212^17
N
N = 3529471145760275132301897342055866171392
N^(1/17)
212
1
2x
x1/2
5
3529471145760275132301897342055866171392
Beyond its prosaic syntax, Eigenmath does have a few tricks up its sleeve.
For example, a symbol can have a subscript.
NA=6.02214*10^23
NA
NA = 6.02214 × 1023
1
ξ= 2
Since xi is ξ, how is xi entered? Well, that is an issue that may get resolved
in the future. For now, xi is always ξ.
Greek letters can appear in the subscript too.
Amu=2.0
Amu
Aµ = 2.0
The general rule is this. Eigenmath scans the entire symbol looking for
Greek letters.
alphamunu
αµν
6
sin(D)
The binding of A is 1 and not B because B was already defined before the
A = B occurred. The quote function can be used to give a literal binding.
A=quote(B)
binding(A)
B
7
What this all means is that symbols have a dual nature. A symbol has a
binding which may be different from its evaluation. Normally this difference
is not important. The functions quote and binding are mentioned here
mainly to provide insight into what is happening belowdecks. Normally
you should not really need to use these functions. However, one notable
exception is the use of quote to clear a symbol.
x=3
x
x=3
x=quote(x)
x
x
8
2 Draw
draw(f, x) draws a graph of the function f of x. The second argument
can be omitted when the dependent variable is literally x or t. The vectors
xrange and yrange control the scale of the graph.
draw(x^2)
xrange=(-1,1)
yrange=(0,2)
draw(x^2)
clear
The clear command (or a click of the Clear button) resets xrange and
yrange. This needs to be done so that the next graph appears as shown.
9
trange=(0,pi/2)
draw(5*f)
10
Here are a couple of interesting curves and the code for drawing them. First
is a lemniscate.
clear
X=cos(t)/(1+sin(t)^2)
Y=sin(t)*cos(t)/(1+sin(t)^2)
draw(5*(X,Y))
Next is a cardioid.
r=(1+cos(t))/2
u=(cos(t),sin(t))
xrange=(-1,1)
yrange=(-1,1)
draw(r*u)
11
3 Scripts
Here is a simple example that draws the graph of y = mx + b.
y=m*x+b
m=1/2
b=-3
draw(y)
Now suppose that we want to draw the graph with a different m. We could
type in everything all over again, but it would be easier in the long run to
write a script. Then we can go back and quickly change m and b as many
times as we want.
To prepare a script, click on the Edit Script button. Then enter the script
commands, one per line, as shown above. Then click on the Run Script
button to see the graph.
Eigenmath runs a script by stepping through it line by line. Each line is
evaluated just like a regular command. This continues until the end of the
script is reached. After the script runs, you can click Edit Script and go
back and change something.
12
3.14159
4 Complex numbers
√
When Eigenmath starts up, it defines the symbol i as i = −1. Other than
that, there is nothing special about i. It is just a regular symbol that can
be redefined and used for some other purpose if need be.
Complex quantities can be entered in rectangular or polar form.
a+i*b
a + ib
exp(i*pi/3)
1
exp( iπ)
3
Converting to rectangular or polar coordinates simplifies mixed forms.
A=1+i
B=sqrt(2)*exp(i*pi/4)
A-B
1
1 + i − 21/2 exp( iπ)
4
rect
0
When a and b are numerical and the power is negative, the evaluation is
done as follows.
n n
a − ib a − ib
−n
(a + ib) = = 2
(a + ib)(a − ib) a + b2
|a + ib| = | − 1| = 1
and p √
a2 + b2 = −1 = i
Hence p
|a + ib| =
6 a2 + b2 for some a, b ∈ C
(a2 + b2 )1/2
15
5 Linear algebra
dot is used to multiply vectors and matrices. The following example shows
how to use dot and inv to solve for X in AX = B.
A=((3.8,7.2),(1.3,-0.9))
B=(16.5,-22.1)
X=dot(inv(A),B)
X
−11.2887
8.24961
One might wonder why the dot function is necessary. Why not simply use
X = inv(A) ∗ B like scalar multiplication? The reason is that the software
normally reorders factors internally to optimize processing. For example,
inv(A) ∗ B in symbolic form is changed to B ∗ inv(A) internally. Since
the dot product is not commutative, this reordering would give the wrong
result. Using a function to do the multiply avoids the problem because
function arguments are not reordered.
It should be noted that dot can have more than two arguments. For example,
dot(A, B, C) can be used for the dot product of three tensors.
−c a
det(A)
ad − bc
inv(A)-adj(A)/det(A)
0 0
0 0
16
d −c
C=
−b a
adj(A)-transpose(C)
0 0
0 0
17
6 Calculus
6.1 Derivative
d(f, x) returns the derivative of f with respect to x. The x can be omitted
for expressions in x.
d(x^2)
2x
∂2f
d(f,x,x) d(f,x,2)
∂x2
∂2f
d(f,x,y)
∂x ∂y
∂ m+n+··· f
d(f,x,...,y,...) d(f,x,m,y,n,...)
∂xm ∂y n · · ·
6.2 Gradient
The gradient of f is obtained by using a vector for x in d(f, x).
r=sqrt(x^2+y^2)
d(r,(x,y))
x
(x2 2
+y ) 1/2
y
(x2 + y 2 )1/2
The f in d(f, x) can be a tensor function. Gradient raises the rank by one.
F=(x+2y,3x+4y)
X=(x,y)
d(F,X)
1 2
3 4
18
As the final example shows, an empty argument list causes d(f ) to always
evaluate to itself, regardless of the second argument.
Template functions are useful for experimenting with differential forms. For
example, let us check the identity
div(curl F) = 0
6.4 Integral
integral(f, x) returns the integral of f with respect to x. The x can be
omitted for expressions in x. A multi-integral can be obtained by extending
the argument list.
integral(x^2)
1 3
x
3
integral(x*y,x,y)
1 2 2
x y
4
def int(f, x, a, b, . . .) computes the definite integral of f with respect to x
evaluated from a to b. The argument list can be extended for multiple
integrals.
The following example computes the integral of f = x2 over the √ domain of
a semicircle. For each x along the abscissa, y ranges from 0 to 1 − x2 .
defint(x^2,y,0,sqrt(1-x^2),x,-1,1)
1
π
8
As an alternative, the eval function can be used to compute a definite inte-
gral step by step.
I=integral(x^2,y)
I=eval(I,y,sqrt(1-x^2))-eval(I,y,0)
I=integral(I,x)
eval(I,x,1)-eval(I,x,-1)
1
π
8
20
Here is a useful trick. Difficult integrals involving sine and cosine can of-
ten be solved by using exponentials. Trigonometric simplifications involving
powers and multiple angles turn into simple algebra in the exponential do-
main. For example, the definite integral
Z 2π
sin4 t − 2 cos3 (t/2) sin t dt
0
0
21
draw(integral(d(f)))
The first graph shows that f 0 (x) is antisymmetric, therefore the total area
under the curve from −1 to 1 sums to zero. The second graph shows that
f (1) = f (−1). Hence for f (x) = 12 x2 we have
Z 1
f 0 (x) dx = f (1) − f (−1) = 0
−1
22
1
4 log(2 + 51/2 ) + 12 51/2
float
1.47894
23
√
As we would expect, the result is greater than 2, the length of the diagonal.
The result seems rather complicated given that we started with a simple
parabola. Let us inspect |g 0 (t)| to see why.
g
t
g=
t2
d(g,t)
1
2t
abs(d(g,t))
(4t2 + 1)1/2
The following script does a discrete computation of the arc length by dividing
the curve into 100 pieces.
g(t)=(t,t^2)
h(t)=abs(g(t)-g(t-0.01))
L=0
for(k,1,100,L=L+h(k/100.0))
L
L = 1.47894
24
56
27
56
27
25
For the vector field form, the symbol u is the unit tangent vector
g 0 (t)
u=
|g 0 (t)|
g 0 (t)
Z Z b Z b
(F · u) ds = F (g(t)) · |g 0 (t)| dt = F (g(t)) · g 0 (t) dt
C a |g 0 (t)| a
26
Evaluate Z Z
x ds and x dx
C C
where C is a straight line from (0, 0) to (1, 1).
What a difference the measure makes. The first integral is over a scalar field
and the second is over a vector field. This can be understood when we recall
that
ds = |g 0 (t)| dt
R
Hence for C x ds we have
x=t
y=t
g=(x,y)
defint(x*abs(d(g,t)),t,0,1)
1
21/2
R
For C x dx we have
x=t
y=t
g=(x,y)
F=(x,0)
defint(dot(F,d(g,t)),t,0,1)
1
2
27
The following line integral problems are from Advanced Calculus, Fifth Edi-
tion by Wilfred Kaplan.
R 2
Evaluate y dx along the straight line from (0, 0) to (2, 2).
x=2t
y=2t
g=(x,y)
F=(y^2,0)
defint(dot(F,d(g,t)),t,0,1)
8
3
0 ≤ t ≤ 1.
x=2t+1
y=t^2
z=1+t^3
g=(x,y,z)
F=(z,x,y)
defint(dot(F,d(g,t)),t,0,1)
163
30
28
The following example computes the surface area of a unit disk parallel to
the xy plane.
z=2
S=(x,y,z)
a=abs(cross(d(S,x),d(S,y)))
defint(a,y,-sqrt(1-x^2),sqrt(1-x^2),x,-1,1)
The result is π, the area of a unit circle, which is what we expect. The
following example computes the surface area of z = x2 + 2y over a unit
square.
z=x^2+2y
S=(x,y,z)
a=abs(cross(d(S,x),d(S,y)))
defint(a,x,0,1,y,0,1)
3 5
+ log(5)
2 8
As a practical matter, f (x, y) must be very simple in order for Eigenmath
to solve the double integral.
29
u cos v
S = u sin v ,
0 ≤ u ≤ 1, 0 ≤ v ≤ 3π
v
10.8177
1
Williamson and Trotter, Multivariable Mathematics, p. 598.
30
Hence
∂S ∂S
ZZ ZZ
F · n dA = × F· dx dy
∂x ∂y
For example, evaluate the surface integral
ZZ
F · n dσ
S
3
Wilfred Kaplan, Advanced Calculus, 5th Edition, 287.
32
8π
--Surface integral
x=quote(x) --remove parametrization of x
y=quote(y) --remove parametrization of y
h=sqrt(4-x^2)
defint(d(Q,x)-d(P,y),y,-h,h,x,-2,2)
8π
--Bonus point: Compute the surface integral using polar coordinates.
f=d(Q,x)-d(P,y) --do before change of coordinates
x=r*cos(theta)
y=r*sin(theta)
defint(f*r,r,0,2,theta,0,2pi)
8π
defint(f*r,theta,0,2pi,r,0,2) --try integrating over theta first
8π
In this case, Eigenmath solved both forms of the polar integral. However,
in cases where Eigenmath fails to solve a double integral, try changing the
order of integration.
33
∂S ∂S
n dσ = × dx dy
∂x ∂y
In many cases, converting an integral according to Stokes’ theorem can turn
a difficult problem into an easy one.
Let F = (y, z, x) and let S be the part of the paraboloid z = 4 − x2 − y 2
that is above the xy plane. The perimeter of the paraboloid is the circle
x2 + y 2 = 2. Calculate both the line and surface integrals. It turns out that
we need to use polar coordinates so that defint can succeed.
--Surface integral
z=4-x^2-y^2
F=(y,z,x)
S=(x,y,z)
f=dot(curl(F),cross(d(S,x),d(S,y)))
x=r*cos(theta)
y=r*sin(theta)
defint(f*r,r,0,2,theta,0,2pi)
−4π
--Line integral
x=2*cos(t)
y=2*sin(t)
z=4-x^2-y^2
P=y
Q=z
R=x
f=P*d(x,t)+Q*d(y,t)+R*d(z,t)
f=circexp(f)
defint(f,t,0,2pi)
−4π
34
7 More examples
7.1 François Viète
François Viète was the first to discover an exact formula for π. Here is his
formula. r
√ q √
q √
2 2 2+ 2 2 + 2+ 2
= × × × ···
π 2 2 2
√
Let a0 = 0 and an = 2 + an−1 . Then we can write
2 a1 a2 a3
= × × × ···
π 2 2 2
Solving for π we have
∞
2 2 2 Y 2
π =2× × × × ··· = 2
a1 a2 a3 a
k=1 k
3.14159
The function a(n) calls itself n times so overall there are 54 calls to a(n). By
using a different algorithm with temporary variables, we can get the answer
in just nine steps.
a=0
b=2
for(k,1,9,a=sqrt(2+a),b=b*2/a)
float(b)
3.14159
35
where ijk is the Levi-Civita tensor. The following script demonstrates that
this formula is equivalent to computing curl the old fashioned way.
-- Define epsilon.
epsilon=zero(3,3,3)
epsilon[1,2,3]=1
epsilon[2,3,1]=1
epsilon[3,1,2]=1
epsilon[3,2,1]=-1
epsilon[1,3,2]=-1
epsilon[2,1,3]=-1
-- F is a generic vector function.
F=(FX(),FY(),FZ())
-- A is the curl of F.
A=outer(epsilon,d(F,(x,y,z)))
A=contract(A,3,4) --sum across k
A=contract(A,2,3) --sum across j
-- B is the curl of F computed the old fashioned way.
BX=d(F[3],y)-d(F[2],z)
BY=d(F[1],z)-d(F[3],x)
BZ=d(F[2],x)-d(F[1],y)
B=(BX,BY,BZ)
-- Are A and B equal? Subtract to find out.
A-B
0
0
0
36
The following is a variation on the previous script. The product ijk ∂Fk /∂xj
is computed in just one line of code. In addition, the outer product and the
contraction across k are now computed with a dot product.
F=(FX(),FY(),FZ())
epsilon=zero(3,3,3)
epsilon[1,2,3]=1
epsilon[2,3,1]=1
epsilon[3,1,2]=1
epsilon[3,2,1]=-1
epsilon[1,3,2]=-1
epsilon[2,1,3]=-1
A=contract(dot(epsilon,d(F,(x,y,z))),2,3)
BX=d(F[3],y)-d(F[2],z)
BY=d(F[1],z)-d(F[3],x)
BZ=d(F[2],x)-d(F[1],y)
B=(BX,BY,BZ)
-- Are A and B equal? Subtract to find out.
A-B
0
0
0
37
E =K +V
d2 ψ
(2n + 1)ψ = − + x2 ψ
dx2
where n is an integer and represents the quantization of energy values. The
solution to the above equation is
0
38
1 ≤ l ≤ n − 1, −l ≤ m ≤ l
0
39
127500 mile
as =
(hr)2
48000 mile
ac =
(hr)2
Time for Corvette to reach orbital velocity:
0.354167 hr
21.25 min
40
−5.17173 × 1016
0.0000010*10^23
1 × 1017
We see that the proposed value is within the experimental error. Just for
the fun of it, let us factor the proposed value.
factor(A)
23 × 33 × 16673 × 84433
4
Fox, Ronald and Theodore Hill. “An Exact Value for Avogadro’s Number.” American
Scientist 95 (2007): 104–107. The proposed number in the article is actually 844468883 . In
a subsequent addendum the authors reduced it to 844468863 to make the number divisible
by 12. See www.physorg.com/news109595312.html
41
8 Built-in functions
abs
abs(x) returns the absolute value or vector length of x. The mag function
should be used for complex x.
P=(x,y)
abs(P)
(x2 + y 2 )1/2
adj
adj(m) returns the adjunct of matrix m.
and
and(a, b, . . .) returns the logical “and” of predicate expressions.
arccos
arccos(x) returns the inverse cosine of x.
arccosh
arccosh(x) returns the inverse hyperbolic cosine of x.
arcsin
arcsin(x) returns the inverse sine of x.
arcsinh
arcsinh(x) returns the inverse hyperbolic sine of x.
43
arctan
arcttan(x) returns the inverse tangent of x.
arctanh
arctanh(x) returns the inverse hyperbolic tangent of x.
arg
arg(z) returns the angle of complex z.
ceiling
ceiling(x) returns the smallest integer not less than x.
check
check(x) In a script, if the predicate x is true then continue, else stop.
choose
n
choose(n, k) returns
k
circexp
circexp(x) returns expression x with circular functions converted to expo-
nential forms. Sometimes this will simplify an expression.
coeff
coeff(p, x, n) returns the coefficient of xn in polynomial p.
cofactor
cofactor(m, i, j) returns of the cofactor of matrix m with respect to row i
and column j.
44
conj
conj(z) returns the complex conjugate of z.
contract
contract(a, i, j) returns tensor a summed over indices i and j. If i and j
are omitted then indices 1 and 2 are used. contract(m) is equivalent to the
trace of matrix m.
cos
cos(x) returns the cosine of x.
cosh
cosh(x) returns the hyperbolic cosine of x.
cross
cross(u, v) returns the cross product of vectors u and v.
curl
curl(u) returns the curl of vector u.
d
d(f, x) returns the derivative of f with respect to x.
defint
defint(f, x, a, b, . . .) returns the definite integral of f with respect to x eval-
uated from a to b. The argument list can be extended for multiple integrals.
For example, d(f, x, a, b, y, c, d).
45
deg
deg(p, x) returns the degree of polynomial p in x.
denominator
denominator(x) returns the denominator of expression x.
det
det(m) returns the determinant of matrix m.
do
do(a, b, . . .) evaluates the argument list from left to right. Returns the result
of the last argument.
dot
dot(a, b, . . .) returns the dot product of tensors.
draw
draw(f, x) draws the function f with respect to x.
erf
erf(x) returns the error function of x.
erfc
erf(x) returns the complementary error function of x.
eval
eval(f, x, n) returns f evaluated at x = n.
46
exp
exp(x) returns ex .
expand
expand(r, x) returns the partial fraction expansion of the ratio of polynomi-
als r in x.
expand(1/(x^3+x^2),x)
1 1 1
2
− +
x x x+1
expcos
expcos(x) returns the cosine of x in exponential form.
expcos(x)
1 1
exp(−ix) + exp(ix)
2 2
expsin
expsin(x) returns the sine of x in exponential form.
expsin(x)
1 1
i exp(−ix) − i exp(ix)
2 2
factor
factor(n) factors the integer n.
factor(12345)
3 × 5 × 823
factor(125*x^3-1)
(5x − 1)(25x2 + 5x + 1)
factorial
Example:
10!
3628800
filter
filter(f, a, b, . . .) returns f with terms involving a, b, etc. removed.
1/a+1/b+1/c
1 1 1
+ +
a b c
filter(last,a)
1 1
+
b c
float
float(x) converts x to a floating point value.
sum(n,0,20,(-1/2)^n)
699051
1048576
float(last)
0.666667
floor
floor(x) returns the largest integer not greater than x.
48
for
for(i, j, k, a, b, . . .) For i equals j through k evaluate a, b, etc.
x=0
y=2
for(k,1,9,x=sqrt(2+x),y=2*y/x)
float(y)
3.14159
gcd
gcd(a, b, . . .) returns the greatest common divisor.
hermite
hermite(x, n) returns the nth Hermite polynomial in x.
hilbert
hilbert(n) returns a Hilbert matrix of order n.
imag
imag(z) returns the imaginary part of complex z.
inner
inner(a, b, . . .) returns the inner product of tensors. Same as the dot product.
integral
integral(f, x) returns the integral of f with respect to x.
inv
inv(m) returns the inverse of matrix m.
49
isprime
isprime(n) returns 1 if n is prime, zero otherwise.
isprime(2^53-111)
laguerre
laguerre(x, n, a) returns the nth Laguerre polynomial in x. If a is omitted
then a = 0 is used.
lcm
lcm(a, b, . . .) returns the least common multiple.
leading
leading(p, x) returns the leading coefficient of polynomial p in x.
leading(5x^2+x+1,x)
legendre
legendre(x, n, m) returns the nth Legendre polynomial in x. If m is omitted
then m = 0 is used.
log
log(x) returns the natural logarithm of x.
mag
mag(z) returns the magnitude of complex z.
50
mod
mod(a, b) returns the remainder of a divided by b.
not
not(x) negates the result of predicate expression x.
nroots
nroots(p, x) returns all of the roots, both real and complex, of polynomial p
in x. The roots are computed numerically. The coefficients of p can be real
or complex.
numerator
numerator(x) returns the numerator of expression x.
or
or(a, b, . . .) returns the logical “or” of predicate expressions.
outer
outer(a, b, . . .) returns the outer product of tensors.
polar
polar(z) converts complex z to polar form.
prime
prime(n) returns the nth prime number, 1 ≤ n ≤ 10,000.
print
print(a, b, . . .) evaluates expressions and prints the results.. Useful for print-
ing from inside a “for” loop.
51
product
k
Y
product(i, j, k, f ) returns f
i=j
quote
quote(x) returns expression x unevaluated.
quotient
quotient(p, q, x) returns the quotient of polynomials in x.
rank
rank(a) returns the number of indices that tensor a has. A scalar has no
indices so its rank is zero.
rationalize
rationalize(x) puts everything over a common denominator.
rationalize(a/b+b/a)
a2 + b2
ab
real
real(z) returns the real part of complex z.
rect
rect(z) returns complex z in rectangular form.
roots
roots(p, x) returns the values of x such that the polynomial p(x) = 0. The
polynomial should be factorable over integers.
52
simplify
simplify(x) returns x in a simpler form.
sin
sin(x) returns the sine of x.
sinh
sinh(x) returns the hyperbolic sine of x.
sqrt
sqrt(x) returns the square root of x.
stop
In a script, it does what it says.
subst
subst(a, b, c) substitutes a for b in c and returns the result.
sum
k
X
sum(i, j, k, f ) returns f
i=j
tan
tan(x) returns the tangent of x.
tanh
tanh(x) returns the hyperbolic tangent of x.
53
taylor
taylor(f, x, n, a) returns the Taylor expansion of f of x at a. The argument
n is the degree of the expansion. If a is omitted then a = 0 is used.
taylor(1/cos(x),x,4)
5 4 1 2
x + x +1
24 2
test
test(a, b, c, d, . . .) If a is true then b is returned else if c is true then d is
returned, etc. If the number of arguments is odd then the last argument is
returned when all else fails.
transpose
transpose(a, i, j) returns the transpose of tensor a with respect to indices i
and j. If i and j are omitted then 1 and 2 are used. Hence a matrix can be
transposed with a single argument.
A=((a,b),(c,d))
transpose(A)
a c
b d
unit
unit(n) returns an n × n identity matrix.
unit(2)
1 0
0 1
zero
zero(i, j, . . .) returns a null tensor with dimensions i, j, etc. Useful for
creating a tensor and then setting the component values.
54
9 Syntax
Math Eigenmath Alternate form and/or comment
−a -a
a+b a+b
a−b a-b
a
a/b
b
a
a/b/c
bc
a2 a^2
√
a a^(1/2) sqrt(a)
1
√ a^(-1/2) 1/sqrt(a)
a
f (a) f(a)
a
b (a,b,c)
c
a b
((a,b),(c,d))
c d