constant: The constant term

Description Usage Arguments Details Author(s) Examples

Description

Get and set the constant term of a mvp object

Usage

1
2
3
4
5
6
## S3 method for class 'mvp'
constant(x)
## S3 replacement method for class 'mvp'
constant(x) <- value
## S3 method for class 'numeric'
constant(x)

Arguments

x

Object of class mvp

value

Scalar value for the constant

Details

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.

Author(s)

Robin K. S. Hankin

Examples

1
2
3
4
5
6
a <- rmvp(5)+4
constant(a)
constant(a) <- 33
a

constant(0)  # the zero mvp

mvp documentation built on Feb. 4, 2019, 5:05 p.m.