Description Usage Arguments Details Examples
Allows arithmetic operators to be used for k-forms and k-tensors such as addition, multiplication, etc, where defined.
1 2 3 4 |
e1,e2 |
Objects of class |
The functions Ops.kform() and Ops.ktensor() pass unary
and binary arithmetic operators (“+”, “-”,
“*”, and “/”) to the appropriate
specialist function by coercing to spray objects.
For wedge products of k-forms, use wedge() or
%^%; and for cross products of k-tensors, use
cross() or %X%.
1 2 3 4 5 6 7 8 9 10 11 12 | ## dx_1 ^ dx_2 + 6dx_5 ^ dx_6:
as.kform(1) %^% as.kform(2) + 6*as.kform(5) %^% as.kform(6)
k1 <- kform_general(4,2,rnorm(6))
k2 <- kform_general(4,2,rnorm(6))
E <- matrix(rnorm(8),4,2)
as.function(k1+k2)(E)
as.function(2*k1+3*k2)(E)-(2*as.function(k1)(E) + 3*as.function(k1)(E))
## should be small
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.