polyOptim: Polynomial Optimization

Description Usage Arguments Value Examples

View source: R/polyOptim.r

Description

Find the collection of critical points of a multivariate polynomial unconstrained or constrained to an affine variety (algebraic set; solution set of multivariate polynomials).

Usage

1
polyOptim(objective, constraints, varOrder, ...)

Arguments

objective

the objective polynomial (as a character or mpoly)

constraints

(as a character or mpoly/mpolyList)

varOrder

variable order (see examples)

...

stuff to pass to bertini

Value

an object of class bertini

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
## Not run: 

# unconstrained optimization of polynomial functions is available
polyOptim("x^2")
polyOptim("-x^2")
polyOptim("-(x - 2)^2")
polyOptim("-(x^2 + y^2)")
polyOptim("-(x^2 + (y - 2)^2)")

polyOptim("(x - 1) (x - 2) (x - 3)") # fix global labeling


# constrained optimization over the affine varieties is also available
# (affine variety = solution set of polynomial equations)

# find the critical points of the plane f(x,y) = x + y
# over the unit circle x^2 + y^2 = 1
polyOptim("x + y", "x^2 + y^2 = 1")

# you can specify them as a combo of mpoly, mpolyList, and characters
o <- mp("x + y")
c <- "x^2 + y^2 = 1"
polyOptim(o, c)

c <- mp("x^2 + y^2 - 1")
polyOptim(o, c)

out <- polyOptim("x + y", c)
str(out)

# another example, note the solutions are computed over the complex numbers
polyOptim("x^2 y", "x^2 + y^2 = 3")
# solutions: (+-sqrt(2), +-1) and (0, +-sqrt(3))





## End(Not run)

algstat documentation built on May 29, 2017, 10:34 p.m.

Related to polyOptim in algstat...