<?xml version="1.0" encoding="UTF-8"?>
<Section>
                <Heading>
                    Irreducible numerical semigroups
                </Heading>
                An irreducible numerical semigroup is a semigroup that cannot be expressed as the
                intersection of numerical semigroups properly containing it.
                <P/>

                It is not difficult to prove that a semigroup is irreducible if and only if it is
                maximal (with respect to set inclusion) in the set of all numerical semigroups having
                its same Frobenius number (see <Cite Key="RB03"></Cite>). Hence, according to
                <Cite Key="FGH87"></Cite> (respectively <Cite Key="BDF97"></Cite>),
                symmetric (respectively pseudo-symmetric) numerical semigroups are those irreducible
                numerical semigroups with odd (respectively even) Frobenius number.
                <P/>

                In <Cite Key="RGGJ03"></Cite> it is shown that a nontrivial numerical semigroup is irreducible if and
                only if it has only one special gap. We use this characterization.
                <P/>

                In this section we show how to construct the set of all numerical semigroups with a
                given Frobenius number. In old versions of the package, we first constructed an irreducible numerical semigroup with
                the given Frobenius number (as explained in <Cite Key="RGS04"></Cite>), and then
                we constructed the rest from it. That is why we separated both functions.
				The present version uses a faster procedure presented in <Cite Key="BR13"></Cite>.
                <P/>

                Every numerical semigroup can be expressed as an intersection of irreducible
                numerical semigroups. If <M>S</M> can be expressed as <M>S=S_1\cap \cdots\cap S_n</M>,
                with <M>S_i</M> irreducible numerical semigroups, and no factor can be removed, then
                we say that this decomposition is minimal. Minimal decompositions can be computed by
                using Algorithm 26 in <Cite Key="RGGJ03"></Cite>.
                <P/>


                <ManSection>
                    <Prop Arg="s" Name="IsIrreducibleNumericalSemigroup"></Prop>
                    <Prop Arg="s" Name="IsIrreducible" Label="for numerical semigroups"></Prop>

                    <Description>
                        <A>s</A> is a numerical semigroup. The output is true if <A>s</A> is irreducible,
                        false otherwise.


                        <P/>
                        This filter implies <Ref Func="IsAlmostSymmetricNumericalSemigroup"/> and <Ref Func="IsAcuteNumericalSemigroup"/>.
                        
                        <Example><![CDATA[
gap> IsIrreducibleNumericalSemigroup(NumericalSemigroup(4,6,9));
true
gap> IsIrreducibleNumericalSemigroup(NumericalSemigroup(4,6,7,9));
false
]]></Example>
                    </Description>
                </ManSection>


                <ManSection>
                    <!--<Prop Arg="s" Name="IsSymmetric"></Prop>-->
                    <Attr Arg="s" Name="IsSymmetricNumericalSemigroup"></Attr>
                    <Attr Arg="s" Name="IsSymmetric" Label="for numerical semigroups"></Attr>

                    <Description>
                        <A>s</A> is a numerical semigroup. The output is true if <A>s</A> is symmetric,
                        false otherwise.


                        <P/>
                        This filter implies <Ref Func="IsIrreducibleNumericalSemigroup"/>.

                        <Example><![CDATA[
gap> IsSymmetric(NumericalSemigroup(10,23));
true
gap> IsSymmetricNumericalSemigroup(NumericalSemigroup(10,11,23));
false
]]></Example>
                    </Description>
                </ManSection>

                <ManSection>
                  <Prop Arg="s" Name="IsPseudoSymmetric" Label="for numerical semigroups"></Prop>
                    <Prop Arg="s" Name="IsPseudoSymmetricNumericalSemigroup"></Prop>
                    <Description>
                        <A>s</A> is a numerical semigroup. The output is true if <A>s</A> is pseudo-symmetric,
                        false otherwise.

                        <P/>
                        This filter implies <Ref Func="IsIrreducibleNumericalSemigroup"/>.

                        <Example><![CDATA[
gap> IsPseudoSymmetricNumericalSemigroup(NumericalSemigroup(6,7,8,9,11));
true
gap> IsPseudoSymmetricNumericalSemigroup(NumericalSemigroup(4,6,9));
false
]]></Example>
                    </Description>
                </ManSection>


                <ManSection>
                    <Func Arg="f" Name="AnIrreducibleNumericalSemigroupWithFrobeniusNumber"></Func>
                    <Description>
                        <A>f</A> is an integer greater than or equal to -1. The output is an irreducible
                        numerical semigroup with Frobenius number <A> f</A>. From the way the procedure is
                        implemented, the resulting semigroup has at most four generators (see <Cite Key="RGS04"></Cite>).
                        <Example><![CDATA[
gap> s := AnIrreducibleNumericalSemigroupWithFrobeniusNumber(28);
<Numerical semigroup with 3 generators>
gap> MinimalGenerators(s);
[ 3, 17, 31 ]
gap> FrobeniusNumber(s);
28
]]></Example>
                    </Description>
                </ManSection>


                <ManSection>
                    <Func Arg="f" Name="IrreducibleNumericalSemigroupsWithFrobeniusNumber"></Func>
                    <Description>
                        <A>f</A> is an integer greater than or equal to -1. The output is the set of all
                        irreducible numerical semigroups with Frobenius number <A>f</A>.
                        <Example><![CDATA[
gap> Length(IrreducibleNumericalSemigroupsWithFrobeniusNumber(19));
20
]]></Example>
                    </Description>
                </ManSection>

                <ManSection>
                    <Func Arg="s" Name="DecomposeIntoIrreducibles" Label="for numerical semigroup"></Func>
                    <Description>
                        <A>s</A> is a numerical semigroup. The output is a set of irreducible
                        numerical semigroups containing it. These elements appear in a minimal
                        decomposition of <A>s</A> as intersection into irreducibles.
                        <Example><![CDATA[
gap> DecomposeIntoIrreducibles(NumericalSemigroup(5,6,8));
[ <Numerical semigroup with 3 generators>,
  <Numerical semigroup with 4 generators> ]
]]></Example>
                    </Description>
                </ManSection>

            </Section>
