x <- 2*runif(5) - 1
fnTrefethen(x)
fnWagon(x)
if (FALSE) {
T <- matrix(NA, nrow=1001, ncol=1001)
for (i in 1:1001) {
for (j in 1:1001) {
T[i, j] <- fnTrefethen(c(x[i], y[j]))
}
}
image(x, y, T)
contour(x, y, T, add=TRUE)
}
Run the code above in your browser using DataLab