80{
81 Nterm *f = a;
82 ring_elem fr = f;
83 MatrixConstructor matT(
T->make_FreeModule(1), 1);
85 bool breakFlag = false;
86
87 (void) numslots;
88 while ((f != nullptr) && (breakFlag == false))
89 {
90
91
92 ring_elem gInT = S->
eval(inclusionAmbient,fr,0);
93
94
95
96 if(gInT != nullptr)
97 {
98
99
100 Nterm *LTgInT = gInT;
101 LTgInT->
next =
nullptr;
102
103
104
105 matT.set_entry(0,0,LTgInT);
106 Matrix *m = matT.to_matrix();
108 ring_elem h1 = n->
elem(0,0);
109 delete m;
110 delete n;
111
112 ring_elem projectionh =
T->eval(substitutionInclusion,h1,0);
113
114 if(projectionh != nullptr)
115 {
116
117 ring_elem hInS =
T->eval(fullSubstitution,h1,0);
118 matS.set_entry(0,0,hInS);
119 Matrix *k = matS.to_matrix();
121 ring_elem h1InS = l->
elem(0,0);
122 delete k;
123 delete l;
124
126 f = fr;
127 }
128 else
129 breakFlag = true;
130 }
131 else
132 breakFlag = true;
133 }
134
135 return ring_elem(f);
136}
virtual const Matrix * matrix_remainder(const Matrix *m)=0
ring_elem elem(int i, int j) const
virtual ring_elem eval(const RingMap *map, const ring_elem f, int first_var) const
void internal_subtract_to(ring_elem &f, ring_elem &g) const
virtual FreeModule * make_FreeModule() const