deboor: De Boor's algorithm for evaluating B-splines

Description Usage Arguments Value Examples

Description

Evaluate piecewise B-splines a various parameter values. Internal function.

Usage

1
deboor(x, t, y, order)

Arguments

x

A n by 2 matrix of control points.

t

A vector of support points

y

A vector of evaluation points. Should be sorted!

order

The spline order. Cubic splines is order 4.

Value

A 2 by length(y) matrix of the evaluated points on the spline.

Examples

1
2
3
4
5
6
7
order <- 3
x <- matrix(rnorm(12), 6, 2)
t <- seq(0, 1, l = nrow(x) - order + 2)
y <- seq(0, 1, l = 50)
print(res <- Bmisc:::deboor(x, t, y, order))
plot(x, type = "b", col = "grey", pch = 16)
points(res, col = "red", type = "l", pch = 16, lwd = 3)

AEBilgrau/Bmisc documentation built on May 5, 2019, 11:28 a.m.