Skip to contents

FpSubgroup(G, gens, normal) is the subgroup of the FpGroup or free group G generated by gens (or the normal closure, if normal). fps_contains() tests membership (by Stallings foldings in a free group and by coset enumeration or rewriting in an FpGroup), fps_order() gives the order and fps_to_FpGroup() a presentation.

Usage

FpSubgroup(G, gens, normal = FALSE)

fps_contains(S, g)

fps_order(S)

fps_to_FpGroup(S)

Arguments

G

An FpGroup or a free group.

gens

A list of words.

normal

Take the normal closure.

S

An FpSubgroup.

g

A word.

Value

An FpSubgroup (an environment), a logical, an order or a group.

Examples

g <- free_group("x, y")
x <- g[[2]]; y <- g[[3]]
f <- FpGroup(g[[1]], list(x^4, y^2, x * y * x^-1 * y))
S <- FpSubgroup(f, list(x * y))
fps_contains(S, (x * y)^-3)
#> [1] TRUE
fps_order(S)
#> 4