32typedef void * (*iiConvertProc)(
void * data);
46 poly
p=
pISet((
int)(
long)data);
74 poly
p=
pISet((
int)(
long)data);
97 I->m[0]=
pISet((
int)(
long)data);
174static void *
iiN2P(
void *data);
195 int s=(int)(
long)data;
202 number n=
nInit((
int)(
long)data);
213static void * iiI2NN(
void *data)
217 WerrorS(
"missing basering while converting int to Number");
220 number n=
nInit((
int)(
long)data);
221 number2 nn=(number2)
omAlloc(
sizeof(*nn));
226static void * iiI2CP(
void *data)
230 WerrorS(
"missing basering while converting int to Poly");
233 poly n=
pISet((
int)(
long)data);
234 poly2 nn=(poly2)
omAlloc(
sizeof(*nn));
256static void * iiBI2NN(
void *data)
260 WerrorS(
"missing basering while converting bigint to Number");
271 number2 nn=(number2)
omAlloc(
sizeof(*nn));
276static void * iiBI2CP(
void *data)
280 WerrorS(
"missing basering while converting bigint to Poly");
291 poly2 nn=(poly2)
omAlloc(
sizeof(*nn));
296static void * iiP2CP(
void *data)
298 poly2 nn=(poly2)
omAlloc(
sizeof(*nn));
306static void * iiNN2N(
void *data)
308 number2 d=(number2)data;
312 WerrorS(
"cannot convert: incompatible");
315 number n =
n_Copy(d->n, d->cf);
322static void * iiNN2P(
void *data)
324 number2 d=(number2)data;
328 WerrorS(
"cannot convert: incompatible");
331 number n =
n_Copy(d->n, d->cf);
381 poly
p=
pNSet((number)data);
401 int add_row_shift = 0;
403 if (weights!=
NULL) add_row_shift=weights->
min_in();
438 if ((inputType==outputType)
442 memcpy(output,input,
sizeof(*output));
449 output->
data=(
char *)(
long)input->
Typ();
480 sprintf(tmp,
"%c%d",*(
currRing->names[nr-1]),
498 number n=(number)input->
data;
500 input->
data=(
void*)n;
524 Print(
"automatic conversion %s -> %s\n",
529 output->
rtyp=outputType;
557 while (input->
e!=
NULL)
577 if ((inputType==outputType)
579 || (outputType==
IDHDL)
584 if (inputType==
UNKNOWN)
return 0;
void atSet(idhdl root, char *name, void *data, int typ)
void * atGet(idhdl root, const char *name, int t, void *defaultReturnValue)
bigintmat * iv2bim(intvec *b, const coeffs C)
void killAll(const ring r)
Class used for (list of) interpreter objects.
void CleanUp(ring r=currRing)
Coefficient rings, fields and other domains suitable for Singular polynomials.
static FORCE_INLINE number n_Copy(number n, const coeffs r)
return a copy of 'n'
static FORCE_INLINE nMapFunc n_SetMap(const coeffs src, const coeffs dst)
set the mapping function pointers for translating numbers from src to dst
static FORCE_INLINE void n_Delete(number *p, const coeffs r)
delete 'p'
static FORCE_INLINE char * nCoeffName(const coeffs cf)
static FORCE_INLINE void n_Write(number n, const coeffs r, const BOOLEAN bShortOut=TRUE)
static FORCE_INLINE number n_Init(long i, const coeffs r)
a number representing i in the given coeff field/ring r
number(* nMapFunc)(number a, const coeffs src, const coeffs dst)
maps "a", which lives in src, into dst
const CanonicalForm int s
void WerrorS(const char *s)
const char * Tok2Cmdname(int tok)
static ideal idVec2Ideal(poly vec)
intvec * ivCopy(const intvec *o)
#define IMATELEM(M, I, J)
static void * iiBI2V(void *data)
static void * iiP2V(void *data)
static void iiL2R(leftv out, leftv in)
static void * iiIm2Ma(void *data)
static void * iiBI2P(void *data)
static void iiBu2P(leftv out, leftv in)
static void * iiN2Ma(void *data)
static void * iiN2P(void *data)
static void * iiV2Ma(void *data)
static void * iiDummy(void *data)
void *(* iiConvertProc)(void *data)
static void * iiI2BI(void *data)
void(* iiConvertProcL)(leftv out, leftv in)
static void * iiP2Id(void *data)
BOOLEAN iiConvert(int inputType, int outputType, int index, leftv input, leftv output, const struct sConvertTypes *dConvertTypes)
static void * iiMa2Mo(void *data)
static void * iiI2Id(void *data)
static void * iiS2Link(void *data)
static void * iiI2Iv(void *data)
static void * iiI2N(void *data)
static void * iiMo2Ma(void *data)
static void iiR2L_l(leftv out, leftv in)
static void * iiI2V(void *data)
int iiTestConvert(int inputType, int outputType, const struct sConvertTypes *dConvertTypes)
static void * iiIm2Bim(void *data)
static void * iiBu2Id(void *data)
static void * iiBu2V(void *data)
static void * iiBI2Id(void *data)
static void * iiI2P(void *data)
static void * iiBI2N(void *data)
const struct sConvertTypes dConvertTypes[]
syStrategy syConvList(lists li)
lists syConvRes(syStrategy syzstr, BOOLEAN toDel, int add_row_shift)
matrix mpNew(int r, int c)
create a r x c zero-matrix
#define MATELEM(mat, i, j)
1-based access to matrix
static number & pGetCoeff(poly p)
return an alias to the leading coefficient of p assumes that p != NULL NOTE: not copy
#define omFreeBin(addr, bin)
static int index(p_Length length, p_Ord ord)
poly p_NSet(number n, const ring r)
returns the poly representing the number n, destroys n
VAR ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
Compatibility layer for legacy polynomial operations (over currRing)
#define pIsConstant(p)
like above, except that Comp must be 0
#define pGetComp(p)
Component.
#define pGetExp(p, i)
Exponent.
void StringSetS(const char *st)
void Werror(const char *fmt,...)
void sBucketDestroyAdd(sBucket_pt bucket, poly *p, int *length)
BOOLEAN slInit(si_link l, char *istr)
ideal idInit(int idsize, int rank)
initialise an ideal / module
matrix id_Module2Matrix(ideal mod, const ring R)
ideal id_Matrix2Module(matrix mat, const ring R)
converts mat to module, destroys mat