Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.
| Download
GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it
Project: cocalc-sagemath-dev-slelievre
Views: 418346<?xml version="1.0" encoding="UTF-8"?>1<Section>2<Heading>Intersections, and quotients and multiples by integers</Heading>3<ManSection>4<Oper Name="Intersection" Arg="S, T" Label="for numerical semigroups"/>5<Func Name="IntersectionOfNumericalSemigroups" Arg="S, T"/>6<Description>7<A>S</A> and <A>T</A>8are numerical semigroups. Computes the intersection of <A>S</A> and <A>T</A>9(which is a numerical semigroup).10<Example><![CDATA[11gap> S := NumericalSemigroup("modular", 5,53);12<Modular numerical semigroup satisfying 5x mod 53 <= x >13gap> T := NumericalSemigroup(2,17);14<Numerical semigroup with 2 generators>15gap> SmallElements(S);16[ 0, 11, 12, 13, 22, 23, 24, 25, 26, 32, 33, 34, 35, 36, 37, 38, 39, 43 ]17gap> SmallElements(T);18[ 0, 2, 4, 6, 8, 10, 12, 14, 16 ]19gap> IntersectionOfNumericalSemigroups(S,T);20<Numerical semigroup>21gap> SmallElements(last);22[ 0, 12, 22, 23, 24, 25, 26, 32, 33, 34, 35, 36, 37, 38, 39, 43 ]23]]></Example>24</Description>25</ManSection>2627<ManSection>28<Func Name="QuotientOfNumericalSemigroup" Arg="S, n"></Func>29<Oper Name="\/" Arg="S, n" Label="quotient of numerical semigroup"/>30<Description>31<A>S</A> is a numerical semigroup and <A>n</A> is an integer.32Computes the quotient of <A>S</A> by <A>n</A>, that is, the set <M>\{ x\in {\mathbb N}\ |\ nx \in S\}</M>, which is again a numerical semigroup.33<C>S / n</C> may be used as a short for <C>QuotientOfNumericalSemigroup(S, n)</C>.34<Example><![CDATA[35gap> s:=NumericalSemigroup(3,29);36<Numerical semigroup with 2 generators>37gap> SmallElements(s);38[ 0, 3, 6, 9, 12, 15, 18, 21, 24, 27, 29, 30, 32, 33, 35, 36, 38,3939, 41, 42, 44, 45, 47, 48, 50, 51, 53, 54, 56 ]40gap> t:=QuotientOfNumericalSemigroup(s,7);41<Numerical semigroup>42gap> SmallElements(t);43[ 0, 3, 5, 6, 8 ]44gap> u := s / 7;45<Numerical semigroup>46gap> SmallElements(u);47[ 0, 3, 5, 6, 8 ]48]]></Example>49</Description>50</ManSection>5152<ManSection>53<Func Name="MultipleOfNumericalSemigroup" Arg="S, a, b"/>54<Description>55<A>S</A> is a numerical semigroup, and <A>a</A> and <A>b</A> are positive integers.56Computes <M>a S\cup \{b,b+1,\to\}</M>. If <A>b</A> is smaller than <M>a c</M>, with <M>c</M> the conductor of <M>S</M>, then a warning is displayed.57<Example><![CDATA[58gap> N:=NumericalSemigroup(1);;59gap> s:=MultipleOfNumericalSemigroup(N,4,20);;60gap> SmallElements(s);61[ 0, 4, 8, 12, 16, 20 ]62]]></Example>63</Description>6465</ManSection>66<ManSection>67<Oper Name="Difference" Arg="S, T" Label="for numerical semigroups"/>68<Func Arg="S, T" Name="DifferenceOfNumericalSemigroups"></Func>69<Description>70<A>S, T</A> are numerical semigroups.71The output is the set <M><A>S</A>\setminus <A>T</A></M>.7273<Example><![CDATA[74gap> ns1 := NumericalSemigroup(5,7);;75gap> ns2 := NumericalSemigroup(7,11,12);;76gap> Difference(ns1,ns2);77[ 5, 10, 15, 17, 20, 27 ]78gap> Difference(ns2,ns1);79[ 11, 18, 23 ]80gap> DifferenceOfNumericalSemigroups(ns2,ns1);81[ 11, 18, 23 ]82]]></Example>83</Description>84</ManSection>8586<ManSection>87<Func Name="NumericalDuplication" Arg="S, E, b"/>88<Description>89<A>S</A> is a numerical semigroup, and <A>E</A> and ideal of <A>S</A>, and <A>b</A> is a positive odd integer, so that <M>2S\cup (2E+b)</M> is a numerical semigroup90(this extends slightly the original definition where <A>b</A> was imposed to be in <A>S</A>, <Cite Key="duplication"></Cite>; now the condition imposed is <M>E+E+b\subseteq S</M>).9192Computes <M>2S\cup (2E+b)</M>.93<Example><![CDATA[94gap> s:=NumericalSemigroup(3,5,7);95<Numerical semigroup with 3 generators>96gap> e:=6+s;97<Ideal of numerical semigroup>98gap> ndup:=NumericalDuplication(s,e,3);99<Numerical semigroup with 4 generators>100gap> SmallElements(ndup);101[ 0, 6, 10, 12, 14, 15, 16, 18, 20, 21, 22, 24 ]102]]></Example>103</Description>104</ManSection>105106<ManSection>107<Func Name="InductiveNumericalSemigroup" Arg="S, a, b"/>108<Description>109<A>S</A> is a numerical semigroup, and <A>a</A> and <A>b</A> are lists of positive integers, such that <M>b[i+1]\ge a[i]b[i]</M>.110Computes inductively <M>S_0=\mathbb N</M> and <M>S_{i+1}=a[i]S_i\cup \{a[i]b[i],a[i]b[i]+1,\to\}</M>, and returns <M>S_{k}</M>, with <M>k</M> the length of <A>a</A> and <A>b</A>.111<Example><![CDATA[112gap> s:=InductiveNumericalSemigroup([4,2],[5,23]);;113gap> SmallElements(s);114[ 0, 8, 16, 24, 32, 40, 42, 44, 46 ]115]]></Example>116</Description>117</ManSection>118119120121</Section>122123124