class JAS::SolvableSubModule
Represents a JAS sub-module over a solvable polynomial ring.
Methods to compute left, right and two-sided Groebner bases.
Attributes
the Java module, module list, number of columns and rows, module list
the Java module, module list, number of columns and rows, module list
the Java module, module list, number of columns and rows, module list
the Java module, module list, number of columns and rows, module list
the Java module, module list, number of columns and rows, module list
Public Class Methods
Constructor for sub-module over a solvable polynomial ring.
# File examples/jas.rb, line 4669 def initialize(modu,modstr="",list=nil) @modu = modu; if list == nil sr = StringReader.new( modstr ); tok = GenPolynomialTokenizer.new(modu.ring,sr); @list = tok.nextSolvableSubModuleList(); else if list.is_a? Array @list = rbarray2arraylist(list,@modu.ring,rec=2); else @list = list; end end @mset = OrderedModuleList.new(modu.ring,@list); @cols = @mset.cols; @rows = @mset.rows; end
Public Instance Methods
Test if this is a left Groebner base.
# File examples/jas.rb, line 4709 def isLeftGB() t = System.currentTimeMillis(); #b = SolvableGroebnerBaseSeq.new(@modu.ring.coFac).isLeftGB(@mset); b = SolvableGroebnerBaseSeq.new().isLeftGB(@mset); t = System.currentTimeMillis() - t; puts "module isLeftGB executed in #{t} ms\n"; return b; end
Test if this is a left syzygy of the vectors in g.
# File examples/jas.rb, line 4769 def isLeftSyzygy(g) l = @list; if g.is_a? SolvIdeal s = g.pset.list; # not g.list else if g.is_a? SolvableSubModule s = g.mset; l = @mset; else raise "unknown type #{g.getClass().getName()}"; end end #puts "l = #{l}"; #puts "s = #{s}"; t = System.currentTimeMillis(); z = SolvableSyzygySeq.new(@modu.ring.coFac).isLeftZeroRelation( l, s ); t = System.currentTimeMillis() - t; puts "executed isLeftSyzygy in #{t} ms\n"; return z; end
Test if this is a right Groebner base.
# File examples/jas.rb, line 4757 def isRightGB() t = System.currentTimeMillis(); #b = SolvableGroebnerBaseSeq.new(@modu.ring.coFac).isRightGB(@mset); b = SolvableGroebnerBaseSeq.new().isRightGB(@mset); t = System.currentTimeMillis() - t; puts "module isRightGB executed in #{t} ms\n"; return b; end
Test if this is a right syzygy of the vectors in g.
# File examples/jas.rb, line 4806 def isRightSyzygy(g) l = @list; if g.is_a? SolvIdeal s = g.pset.list; # not g.list else if g.is_a? SolvableSubModule s = g.mset; l = @mset; else raise "unknown type #{g.getClass().getName()}"; end end #puts "l = #{l}"; #puts "s = #{s}"; t = System.currentTimeMillis(); z = SolvableSyzygySeq.new(@modu.ring.coFac).isRightZeroRelation( l, s ); t = System.currentTimeMillis() - t; puts "executed isRightSyzygy in #{t} ms\n"; return z; end
Test if this is a two-sided Groebner base.
# File examples/jas.rb, line 4733 def isTwosidedGB() t = System.currentTimeMillis(); #b = SolvableGroebnerBaseSeq.new(@modu.ring.coFac).isTwosidedGB(@mset); b = SolvableGroebnerBaseSeq.new().isTwosidedGB(@mset); t = System.currentTimeMillis() - t; puts "module isTwosidedGB executed in #{t} ms\n"; return b; end
Compute a left Groebner base.
# File examples/jas.rb, line 4697 def leftGB() t = System.currentTimeMillis(); #gg = SolvableGroebnerBaseSeq.new(@modu.ring.coFac).leftGB(@mset); gg = SolvableGroebnerBaseSeq.new().leftGB(@mset); t = System.currentTimeMillis() - t; puts "executed left module GB in #{t} ms\n"; return SolvableSubModule.new(@modu,"",gg.list); end
Compute left syzygys of this module.
# File examples/jas.rb, line 4793 def leftSyzygy() l = @mset; t = System.currentTimeMillis(); p = SolvableSyzygySeq.new(@modu.ring.coFac).leftZeroRelationsArbitrary( l ); t = System.currentTimeMillis() - t; puts "executed left module syzygy in #{t} ms\n"; m = SolvableModule.new("",p.ring,p.cols); return SolvableSubModule.new(m,"",p.list); end
Compute a right Groebner base.
# File examples/jas.rb, line 4745 def rightGB() t = System.currentTimeMillis(); #gg = SolvableGroebnerBaseSeq.new(@modu.ring.coFac).rightGB(@mset); gg = SolvableGroebnerBaseSeq.new().rightGB(@mset); t = System.currentTimeMillis() - t; puts "executed right module GB in #{t} ms\n"; return SolvableSubModule.new(@modu,"",gg.list); end
Compute right syzygys of this module.
# File examples/jas.rb, line 4830 def rightSyzygy() l = @mset; t = System.currentTimeMillis(); #no: p = SolvableSyzygySeq.new(@modu.ring.coFac).rightZeroRelations( l ); p = SolvableSyzygySeq.new(@modu.ring.coFac).rightZeroRelationsArbitrary( l ); t = System.currentTimeMillis() - t; puts "executed right module syzygy in #{t} ms\n"; m = SolvableModule.new("",p.ring,p.cols); return SolvableSubModule.new(m,"",p.list); end
Create a string representation.
# File examples/jas.rb, line 4690 def to_s() return @mset.toScript(); # + "\n\n" + str(@pset); end
Compute a two-sided Groebner base.
# File examples/jas.rb, line 4721 def twosidedGB() t = System.currentTimeMillis(); #gg = SolvableGroebnerBaseSeq.new(@modu.ring.coFac).twosidedGB(@mset); gg = SolvableGroebnerBaseSeq.new().twosidedGB(@mset); t = System.currentTimeMillis() - t; puts "executed twosided module GB in #{t} ms\n"; return SolvableSubModule.new(@modu,"",gg.list); end