Perm¶
-
template<size_t N = 0, typename Scalar = std::conditional_t<N == 0, uint32_t, typename SmallestInteger<N>::type>>
class Perm : public libsemigroups::Transf<0, std::conditional_t<0 == 0, uint32_t, typename SmallestInteger<0>::type>>¶ Defined in
transf.hpp.A permutation \(f\) is an injective transformation defined on the whole of \(\{0, 1, \ldots, n - 1\}\) for some integer \(n\) called the degree of \(f\). A permutation is stored as a vector of the images of \((0, 1, \ldots, n - 1)\), i.e. \(((0)f, (1)f, \ldots, (n - 1)f)\).
If
Nis0(the default), then the degree of a PPerm instance can be defined at runtime, and ifNis not0, then the degree is fixed at compile time.If
Nis0, then the default value ofScalarisuint32_t. IfNis not0, then the default value ofScalaris the smallest integer type able to holdN. See also SmallestInteger.Note
Perm has the same member functions as StaticPTransf and DynamicPTransf, this isn’t current reflected by the contents of this page.
- Template Parameters:
N – the degree (default:
0)Scalar – an unsigned integer type (the type of the image values)
Member types¶
Type of the underlying container. |
|
Type of the image values. |
Static member functions¶
Returns the identity permutation on degree() points. |
|
Returns the identity permutation on the given number of points. |
|
Construct from image list and validate. |
|
Construct from a container and validate. |
Member functions¶
Returns the inverse. |
|
Multiply two transformations and store the product in |