mapZX: Alternative mapping

View source: R/mappings.R

mapZXR Documentation

Alternative mapping

Description

Map from zonotope Z to the convex projection of A Y (E)

Usage

mapZX(z, A, eps = 1e-06, Amat = NULL, Aind = NULL)

Arguments

z

matrix of low-dimensional coordinates in the zonotope, one point per row

A

random embedding matrix, such that t(A)A = Id

eps

to avoid some numerical issues with quadratic programming

Aind, Amat

optional matrices to be passed to solve.QP.compact

Details

Numerical problems may occur, then the equality constraints are slightly relaxed.

Author(s)

Mickael Binois

References

M. Binois, D. Ginsbourger, O. Roustant (2018), On the choice of the low-dimensional domain for global optimization via random embeddings, arXiv:1704.05318

Examples

## Example of forward - backward mapping
d <- 5; D <- 26
A <- selectA(d, D, type = 'Gaussian')

n <- 10000
size <- 10
Y <- size * (2 * matrix(runif(n * d), n) - 1)
X <- randEmb(Y, A)
Z <- ortProj(X, t(A))
# Errors are catched and the problem slightly relaxed
Xback <- mapZX(Z, A)

print(max(abs(Xback - X)))
print(mean(Xback - X))

mbinois/RRembo documentation built on Sept. 16, 2023, 10:15 p.m.