Learn R Programming

stokes (version 1.2-0)

print.stokes: Print methods for \(k\)-tensors and \(k\)-forms

Description

Print methods for objects with options for printing in matrix form or multivariate polynomial form

Usage

# S3 method for kform
print(x, ...)
# S3 method for ktensor
print(x, ...)

Value

Returns its argument invisibly.

Arguments

x

k-form or k-tensor

...

Further arguments (currently ignored)

Author

Robin K. S. Hankin

Details

The print method is designed to tell the user that an object is a tensor or a k-form. It prints a message to this effect (with special dispensation for zero tensors), then calls the spray print method.

See Also

as.symbolic,dovs

Examples

Run this code

a <- rform()
a

options(kform_symbolic_print = "x")
a


options(kform_symbolic_print = "dx")
kform(spray(kform_basis(3,2),1:3))


kform(spray(kform_basis(4,2),1:6))  # runs out of symbols


options(kform_symbolic_print = "txyz")
kform(spray(kform_basis(4,2),1:6))  # standard notation


options(kform_symbolic_print = NULL) # revert to default
a

Run the code above in your browser using DataLab