1 #include <gfanlib/gfanlib.h> 17 int temp = (int) mpz_get_si(i);
43 for(
int j=1;
j<=n;
j++)
57 return new gfan::Integer(n->z);
64 gfan::ZMatrix* zm =
new gfan::ZMatrix(d,n);
78 gfan::ZVector* zv=
new gfan::ZVector(bim.
cols());
93 for(
int j=0;
j<d;
j++)
101 for(
int i=0;
i<n;
i++)
102 zv[
i]=gfan::Integer(expv[
i+1]);
109 for(
int j=0;
j<n;
j++)
116 int*
w = (
int*)
omAlloc(v.size()*
sizeof(int));
117 for (
unsigned i=0;
i<v.size();
i++)
119 if (!v[
i].fitsInInt())
122 WerrorS(
"intoverflow converting gfan:ZVector to int*");
143 if (setOfCones.size() > 0)
145 std::set<gfan::ZCone>::iterator cone = setOfCones.begin();
146 gfan::ZFan* zf =
new gfan::ZFan(cone->ambientDimension());
147 for (std::set<gfan::ZCone>::iterator cone = setOfCones.begin(); cone!=setOfCones.end(); cone++)
155 std::set<gfan::ZVector>
rays(std::set<gfan::ZCone> setOfCones)
157 std::set<gfan::ZVector> setOfRays;
158 for (std::set<gfan::ZCone>::iterator cone = setOfCones.begin(); cone!=setOfCones.end(); cone++)
160 gfan::ZMatrix raysOfCone = cone->extremeRays();
161 for (
int i=0;
i<raysOfCone.getHeight();
i++)
162 setOfRays.insert(raysOfCone[
i]);
const CanonicalForm int s
std::set< gfan::ZVector > rays(std::set< gfan::ZCone > setOfCones)
char * toString(gfan::ZMatrix const &zm)
gfan::ZFan * toFanStar(std::set< gfan::ZCone > setOfCones)
BOOLEAN fullFan(leftv res, leftv args)
static FORCE_INLINE number n_Init(long i, const coeffs r)
a number representing i in the given coeff field/ring r
bigintmat * zMatrixToBigintmat(const gfan::ZMatrix &zm)
gfan::ZVector wvhdlEntryToZVector(const int n, const int *wvhdl0)
char * StringAsPrinted()
Returns a string as it would have been printed in the interpreter.
int * ZVectorToIntStar(const gfan::ZVector &v, bool &overflow)
void WerrorS(const char *s)
bigintmat * zVectorToBigintmat(const gfan::ZVector &zv)
void set(int i, int j, number n, const coeffs C=NULL)
replace an entry with a copy (delete old + copy new!). NOTE: starts at [1,1]
gfan::Integer * numberToInteger(const number &n)
ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
gfan::ZMatrix * bigintmatToZMatrix(const bigintmat &bim)
gfan::ZVector intStar2ZVector(const int d, const int *i)
static FORCE_INLINE number n_InitMPZ(mpz_t n, const coeffs r)
conversion of a GMP integer to number
number integerToNumber(const gfan::Integer &I)
gfan::ZVector expvToZVector(const int n, const int *expv)
#define BIMATELEM(M, I, J)
const Variable & v
< [in] a sqrfree bivariate poly
static FORCE_INLINE void n_Delete(number *p, const coeffs r)
delete 'p'
gfan::ZVector * bigintmatToZVector(const bigintmat &bim)