2#include "gfanlib/gfanlib_vector.h"
17std::pair<ideal,ring>
flip(
const ideal I,
const ring r,
18 const gfan::ZVector interiorPoint,
19 const gfan::ZVector facetNormal,
20 const gfan::ZVector adjustedInteriorPoint,
21 const gfan::ZVector adjustedFacetNormal)
26 int n = rVar(sAdjusted);
28 sAdjusted->block0 = (
int*)
omAlloc0(5*
sizeof(
int));
29 sAdjusted->block1 = (
int*)
omAlloc0(5*
sizeof(
int));
30 sAdjusted->wvhdl = (
int**)
omAlloc0(5*
sizeof(
int**));
32 sAdjusted->block0[0] = 1;
33 sAdjusted->block1[0] = n;
36 sAdjusted->block0[1] = 1;
37 sAdjusted->block1[1] = n;
40 sAdjusted->block0[2] = 1;
41 sAdjusted->block1[2] = n;
46 nMapFunc identity = n_SetMap(r->cf,sAdjusted->cf);
49 ideal inIr =
initial(I,r,interiorPoint);
51 for (
int i=0;
i<
k;
i++)
66 ideal IsAdjustedGB =
lift(I,r,inIsAdjustedGB,sAdjusted);
73 s->block0 = (
int*)
omAlloc0(5*
sizeof(
int));
74 s->block1 = (
int*)
omAlloc0(5*
sizeof(
int));
75 s->wvhdl = (
int**)
omAlloc0(5*
sizeof(
int**));
90 identity = n_SetMap(sAdjusted->cf,
s->cf);
92 for (
int i=0;
i<
k;
i++)
94 if (IsAdjustedGB->m[
i]!=
NULL)
107 return std::make_pair(IsGB,
s);
int * ZVectorToIntStar(const gfan::ZVector &v, bool &overflow)
number(*) nMapFunc(number a, const coeffs src, const coeffs dst)
maps "a", which lives in src, into dst
const CanonicalForm int s
std::pair< ideal, ring > flip(const ideal I, const ring r, const gfan::ZVector interiorPoint, const gfan::ZVector facetNormal, const gfan::ZVector adjustedInteriorPoint, const gfan::ZVector adjustedFacetNormal)
poly initial(const poly p, const ring r, const gfan::ZVector &w)
Returns the initial form of p with respect to w.
ideal kStd2(ideal F, ideal Q, tHomog h, intvec **w, bigintmat *hilb, int syzComp, int newIdeal, intvec *vw, s_poly_proc_t sp)
generic interface to GB/SB computations, large hilbert vectors
ideal lift(const ideal J, const ring r, const ideal inI, const ring s)
poly p_PermPoly(poly p, const int *perm, const ring oldRing, const ring dst, nMapFunc nMap, const int *par_perm, int OldPar, BOOLEAN use_mult)
void rChangeCurrRing(ring r)
VAR ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
BOOLEAN rComplete(ring r, int force)
this needs to be called whenever a new ring is created: new fields in ring are created (like VarOffse...
ring rCopy0(const ring r, BOOLEAN copy_qideal, BOOLEAN copy_ordering)
void rDelete(ring r)
unconditionally deletes fields in r
ideal idInit(int idsize, int rank)
initialise an ideal / module
void id_Delete(ideal *h, ring r)
deletes an ideal/module/matrix