constant | R Documentation |
Get and set the constant term of an mvp
object
## S3 method for class 'mvp'
constant(x)
## S3 replacement method for class 'mvp'
constant(x) <- value
## S3 method for class 'numeric'
constant(x)
is.constant(x)
x |
Object of class |
value |
Scalar value for the constant |
The constant term in a polynomial is the coefficient of the empty term.
In an mvp
object, the map {} -> c
, implies that c
is
the constant.
If x
is an mvp
object, constant(x)
returns the value of
the constant in the multivariate polynomial; if x
is numeric,
it returns a constant multivariate polynomial with value x
.
Function is.constant()
returns TRUE
if its argument has
no variables and FALSE
otherwise.
Robin K. S. Hankin
a <- rmvp(5)+4
a
constant(a)
constant(a) <- 33
a
constant(0) # the zero mvp
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.