Learn R Programming

poseticDataAnalysis (version 1.0.0)

LEGenerator: Generator of all the linear extensions of a poset.

Description

Creates an object of S4 class LEGenerator to generate all of the linear extensions of a given poset. Actually, this function does not generate the linear extensions, but just the object that will generate them by using function LEGet.

Usage

LEGenerator(poset)

Value

An S4 class object LEGenerator.

Arguments

poset

An object of S4 class POSet representing the poset whose linear extensions are generated. Argument poset must be created by using any function contained in the package aimed at building object of S4 class POSet (e.g. POSet(), LinearPOSet(), ProductPOSet(), ...) .

Examples

Run this code
el <- c("a", "b", "c", "d")

dom <- matrix(c(
  "a", "b",
  "c", "b",
  "b", "d"
), ncol = 2, byrow = TRUE)

pos <- POSet(elements = el, dom = dom)

LEgen <- LEGenerator(pos)


Run the code above in your browser using DataLab