Go to the source code of this file.
◆ IMATELEM
#define IMATELEM |
( |
|
M, |
|
|
|
I, |
|
|
|
J |
|
) |
| (M)[(I-1)*(M).cols()+J-1] |
◆ ivTest
◆ ivAdd()
Definition at line 249 of file intvec.cc.
259 for (i=0; i<mn; i++) (*iv)[
i] = (*a)[
i] + (*b)[
i];
264 for(i=mn; i<ma; i++) (*iv)[
i] = (*a)[
i];
268 for(i=mn; i<ma; i++) (*iv)[
i] = (*b)[
i];
273 if (mn != ma)
return NULL;
275 for (i=0; i<mn*a->
cols(); i++) { (*iv)[
i] += (*b)[
i]; }
static int si_min(const int a, const int b)
static int si_max(const int a, const int b)
◆ ivConcat()
Definition at line 804 of file intvec.cc.
811 for (i=1; i<=a->
rows(); i++)
816 for (i=1; i<=b->
rows(); i++)
818 for(j=1; j<=b->
cols(); j++)
static int si_max(const int a, const int b)
#define IMATELEM(M, I, J)
◆ ivCopy()
◆ ivMult()
Definition at line 331 of file intvec.cc.
337 if (ca != rb)
return NULL;
338 iv =
new intvec(ra, cb, 0);
345 sum += (*a)[i*ca+
k]*(*b)[k*cb+
j];
◆ ivSolveKern()
Definition at line 424 of file intvec.cc.
435 for (r=1;r<=dimtr;r++)
442 for (r=dimtr;r>0;r--)
static intvec * ivOptimizeKern(intvec *)
intvec * ivTranp(intvec *o)
static void ivKernFromRow(intvec *, intvec *, intvec *, int, int, int)
#define IMATELEM(M, I, J)
◆ ivSub()
Definition at line 279 of file intvec.cc.
289 for (i=0; i<mn; i++) (*iv)[
i] = (*a)[
i] - (*b)[
i];
294 for(i=mn; i<ma; i++) (*iv)[
i] = (*a)[
i];
298 for(i=mn; i<ma; i++) (*iv)[
i] = -(*b)[
i];
303 if (mn != ma)
return NULL;
305 for (i=0; i<mn*a->
cols(); i++) { (*iv)[
i] -= (*b)[
i]; }
static int si_min(const int a, const int b)
static int si_max(const int a, const int b)
◆ ivTrace()
Definition at line 321 of file intvec.cc.
const CanonicalForm int s
static int si_min(const int a, const int b)
◆ ivTranp()
Definition at line 309 of file intvec.cc.
316 (*iv)[j*r+
i] = (*o)[i*c+
j];
◆ ivTriangIntern()
void ivTriangIntern |
( |
intvec * |
imat, |
|
|
int & |
ready, |
|
|
int & |
all |
|
) |
| |
Definition at line 386 of file intvec.cc.
388 int rpiv, colpos=0, rowpos=0;
389 int ia=ready, ie=all;
397 rpiv =
ivColPivot(imat, colpos, rowpos, ia, ie);
409 if (ia==imat->
cols())
416 ivReduce(imat, rpiv, colpos, ia, ie);
static void ivZeroElim(intvec *, int, int, int &)
static void ivFreeRow(intvec *, int, int)
static void ivSaveRow(intvec *, int)
static int ivColPivot(intvec *, int, int, int, int)
static void ivReduce(intvec *, int, int, int, int)
static void ivSetRow(intvec *, int, int)