Computes the Levi-Civita totally antisymmetric tensor.

epsilon(n)

Arguments

n

number of dimensions.

Value

array representing the Levi-Civita symbol.

References

Guidotti E (2022). "calculus: High-Dimensional Numerical and Symbolic Calculus in R." Journal of Statistical Software, 104(5), 1-37. doi:10.18637/jss.v104.i05

See also

Other tensor algebra: contraction(), delta(), diagonal(), einstein(), index()

Examples

### Levi-Civita symbol in 2 dimensions
epsilon(2)
#>      [,1] [,2]
#> [1,]    0    1
#> [2,]   -1    0

### Levi-Civita symbol in 3 dimensions
epsilon(3)
#> , , 1
#> 
#>      [,1] [,2] [,3]
#> [1,]    0    0    0
#> [2,]    0    0    1
#> [3,]    0   -1    0
#> 
#> , , 2
#> 
#>      [,1] [,2] [,3]
#> [1,]    0    0   -1
#> [2,]    0    0    0
#> [3,]    1    0    0
#> 
#> , , 3
#> 
#>      [,1] [,2] [,3]
#> [1,]    0    1    0
#> [2,]   -1    0    0
#> [3,]    0    0    0
#>