as.function.exactmvp {jack} | R Documentation |
Coerces an exact multivariate polynomial into a function.
## S3 method for class 'exactmvp'
as.function(x, ...)
x |
object of class |
... |
ignored |
A function having the same variables as the polynomial.
# library(jack)
if(JuliaConnectoR::juliaSetupOk()){
julia <- Jack_julia()
( pol <- julia$JackPol(m = 2, lambda = c(3, 1), alpha = "3/2") )
f <- as.function(pol)
f(2, "3/7")
# the evaluation is performed by (R)yacas and complex numbers are
# allowed; the imaginary unit is denoted by `I`
f("2 + 2*I", "1/4")
JuliaConnectoR::stopJulia()
}