gen_simplex: Generator function for simplices

Description Usage Arguments Value Examples

View source: R/gen_simplex.R

Description

This function generates the d-dimensional unit simplex in H- or V-representation.

Usage

1
gen_simplex(dimension, representation = "H")

Arguments

dimension

The dimension of the unit simplex.

representation

A string to declare the representation. It has to be 'H' for H-representation or 'V' for V-representation. Default valus is 'H'.

Value

A polytope class representing the d-dimensional unit simplex in H- or V-representation.

Examples

1
2
3
4
5
# generate a 10-dimensional simplex in H-representation
PolyList = gen_simplex(10, 'H')

# generate a 20-dimensional simplex in V-representation
P = gen_simplex(20, 'V')

volesti documentation built on July 14, 2021, 5:11 p.m.