basis | R Documentation |
This function generates the basis for bivariate spline over triangulation.
basis(V, Tr, d = 5, r = 1, Z, Hmtx = TRUE, Kmtx = TRUE, QR = TRUE, TA = TRUE)
V |
The |
Tr |
The triangulation matrix of dimention |
d |
The degree of piecewise polynomials – default is 5, and usually |
r |
The smoothness parameter – default is 1, and 0 |
Z |
The cooridinates of dimension |
Hmtx |
The indicator of whether the smoothness matrix |
Kmtx |
The indicator of whether the energy matrix |
QR |
The indicator of whether a QR decomposition need to be performed on the smoothness matrix – default is |
TA |
The indicator of whether the area of the triangles need to be calculated – default is |
This R program is modified based on the Matlab program written by Ming-Jun Lai from the University of Georgia and Li Wang from the Iowa State University.
A list of vectors and matrice, including:
B |
The spline basis function of dimension |
Ind.inside |
A vector contains the indexes of all the points which are inside the triangulation. |
H |
The smoothness matrix. |
Q2 |
The Q2 matrix after QR decomposition of the smoothness matrix |
K |
The thin-plate energy function. |
tria.all |
The area of each triangle within the given triangulation. |
# example 1
xx = c(-0.25, 0.75, 0.25, 1.25)
yy = c(-0.25, 0.25, 0.75,1 .25)
Z = cbind(xx, yy)
d = 4; r = 1;
V0 = rbind(c(0, 0), c(1, 0), c(1, 1), c(0, 1))
Tr0 = rbind(c(1, 2, 3), c(1, 3, 4))
basis(V0, Tr0, d, r, Z)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.