
Given a vector, return the corresponding 1-form; the exterior
derivative of a 0-form (that is, a scalar function). Function
grad()
is a synonym.
as.1form(v)
grad(v)
A one-form
A vector with element i being f/ x_idf/dxi
Robin K. S. Hankin
The exterior derivative of a k-form phi is a (k+1)-form dd phi given by
d ( P_x(v_i,...,v_k+1) ) = _h 01h^k+1_ P_x(hv_1,...,hv_k+1) omitted; see latex
We can use the facts that
d(f\,dx_i_1 dx_i_k)= df dx_i_1 dx_i_k omitted; see latex
and df=_j=1^n(D_j f)\,dx_j omitted; see latex
to calculate differentials of general k-forms. Specifically, if
=_1 i_i < < i_k n a_i_1... i_kdx_i_1 dx_i_k omitted; see latex
then d= _1 i_i < < i_k n [_j=1^nD_ja_i_1... i_kdx_j] dx_i_1 dx_i_k. omitted; see latex
The entry in square brackets is given by grad()
. See the
examples for appropriate R idiom.
kform
as.1form(1:9) # note ordering of terms
as.1form(rnorm(20))
grad(c(4,7)) ^ grad(1:4)
Run the code above in your browser using DataLab