wedge (version 1.0-3)

rform: Random kforms and ktensors

Description

Random \(k\)-form objects and \(k\)-tensors, intended as quick “get you going” examples

Usage

rform(terms=9,k=3,n=7,coeffs)
rtensor(terms=9,k=3,n=7,coeffs)

Arguments

terms

Number of distinct terms

k,n

A \(k\)-form maps \(V^k\) to \(R\), where \(V=R^n\)

coeffs

The coefficients of the form; if missing use 1 (inherited from spray())

Details

What you see is what you get, basically.

Note that argument terms is an upper bound, as the index matrix might contain repeats. But coeffs should have length equal to terms (or 1).

Examples

Run this code
# NOT RUN {
rform()
rform(coeffs=1:9)   # any repeated rows are combined

dx <- as.kform(1)
dy <- as.kform(2)
rform() %^% dx
rform() %^% dx %^% dy


rtensor()
# }

Run the code above in your browser using DataLab