#include "kernel/mod2.h"
#include "misc/intvec.h"
#include "polys/matpol.h"
#include "kernel/polys.h"
#include "kernel/ideals.h"
#include "tok.h"
#include "ipid.h"
#include "subexpr.h"
#include "ipshell.h"
#include "ipprint.h"
#include "attrib.h"
Go to the source code of this file.
◆ ipPrint_CRING()
Definition at line 210 of file ipprint.cc.
211{
213 {
215 else PrintS(
"ring (with zero-divisors): ");
216 }
220}
static FORCE_INLINE BOOLEAN nCoeff_is_Domain(const coeffs r)
returns TRUE, if r is a field or r has no zero divisors (i.e is a domain)
static FORCE_INLINE BOOLEAN nCoeff_is_Ring(const coeffs r)
static FORCE_INLINE char * nCoeffName(const coeffs cf)
void PrintS(const char *s)
◆ ipPrint_INTMAT()
Definition at line 40 of file ipprint.cc.
41{
43 for(
i=0;
i<
v->rows();
i++)
44 {
45 for(
j=0;
j<
v->cols();
j++)
46 {
48 }
50 }
52}
const Variable & v
< [in] a sqrfree bivariate poly
#define IMATELEM(M, I, J)
◆ ipPrint_INTVEC()
◆ ipPrint_MA()
Definition at line 183 of file ipprint.cc.
184{
188}
void ipPrint_MA0(matrix m, const char *name)
◆ ipPrint_MA0()
Definition at line 57 of file ipprint.cc.
58{
60 {
62 char *ss;
66
67
70 vl=
si_max(vl,(
int)strlen(ss));
72
73
79 {
86 }
87
88
90 {
92 {
94 {
97 ss[0]='\0';
98 sprintf(ss,
"%s[%d,%d]",
name,
i+1,
j+1);
100 {
101 strcat(ss,",");
102 vl=
si_max(vl,(
int)strlen(ss));
103 }
104 }
107 }
108 }
109
110 int maxlen=0;
112 {
114 }
116 {
117
118
119
120
122 {
124 {
127 {
131 ss[0]='\0';
132 sprintf(ss,
"%s[%d,%d]",
name,
i+1,
j+1);
134 {
135 strcat(ss,",");
136 }
139 {
140
141
142
144 }
146 }
147 else
148 {
150 }
151 }
152 }
153 }
154
156 {
161 {
163 {
166 }
170 }
172 }
173
176 }
178}
static int si_max(const int a, const int b)
const CanonicalForm int s
#define omFreeSize(addr, size)
#define omFreeBinAddr(addr)
void StringSetS(const char *st)
void StringAppendS(const char *st)
int name
New type name for int.
◆ ipPrint_RING()
static BOOLEAN ipPrint_RING |
( |
ring |
r | ) |
|
|
static |
Definition at line 193 of file ipprint.cc.
194{
195 PrintS(
"polynomial ring, over a ");
197 {
199 else PrintS(
"ring (with zero-divisors)");
200 }
202 if (r->OrdSgn==1)
PrintS(
", global");
203 else if (r->MixedOrder==1)
PrintS(
", mixed");
208}
void rWrite(ring r, BOOLEAN details)
static BOOLEAN rField_is_Domain(const ring r)
#define rField_is_Ring(R)
◆ ipPrint_V()
Definition at line 224 of file ipprint.cc.
225{
228
230
234 {
238 else
239 {
241 break;
242 }
243 }
244
248}
void p_Vec2Polys(poly v, poly **p, int *len, const ring r)
VAR ring currRing
Widely used global variable which specifies the current polynomial ring for Singular interpreter and ...
◆ ipPrintBetti()
static void ipPrintBetti |
( |
leftv |
u | ) |
|
|
static |
Definition at line 344 of file ipprint.cc.
345{
347 int row_shift=(int)((
long)(
atGet(u,
"rowShift",
INT_CMD)));
349
355
357 {
358 Print(
"%5d:",
i+row_shift);
360 {
364 else
366 }
368 }
369
374 {
377 {
379 }
381 }
383}
void * atGet(idhdl root, const char *name, int t, void *defaultReturnValue)
◆ jjDBPRINT()
Definition at line 316 of file ipprint.cc.
317{
320 {
321 print= (((int)((
long)(u->
Data()))) > 0);
323 }
324 if (print)
325 {
326
330 {
339 }
340 }
342}
Class used for (list of) interpreter objects.
BOOLEAN jjPRINT(leftv res, leftv u)
◆ jjPRINT()
Definition at line 250 of file ipprint.cc.
251{
256 {
259 break;
260
263 break;
264
267 break;
268
270 {
275 break;
276 }
277
279 {
283 break;
284 }
285
288 break;
289
292 break;
293
296 break;
297
298 default:
300 break;
301 }
304 {
306 if (
s[
l-1]==
'\n')
s[
l-1]=
'\0';
307 }
309 return bo;
310}
char * String(void *d=NULL, BOOLEAN typed=FALSE, int dim=1)
Called for conversion to string (used by string(..), write(..),..)
void Print(leftv store=NULL, int spaces=0)
Called by type_cmd (e.g. "r;") or as default in jPRINT.
ideal id_Copy(ideal h1, const ring r)
copy an ideal
static BOOLEAN ipPrint_RING(ring r)
static BOOLEAN ipPrint_V(poly u)
static BOOLEAN ipPrint_MA(leftv u)
static BOOLEAN ipPrint_INTVEC(intvec *v)
static BOOLEAN ipPrint_INTMAT(intvec *v)
static BOOLEAN ipPrint_CRING(coeffs r)
The main handler for Singular numbers which are suitable for Singular polynomials.
void id_Delete(ideal *h, ring r)
deletes an ideal/module/matrix
matrix id_Module2Matrix(ideal mod, const ring R)
◆ jjPRINT_FORMAT()
Definition at line 389 of file ipprint.cc.
390{
391
392 if ((u->
Typ()==
INTMAT_CMD)&&(strcmp((
char *)
v->Data(),
"betti")==0))
393 {
399 }
400 else
401
402 {
405 if (strlen(ns) == 3 && ns[1] == '2')
406 {
408 ns[1] = ns[2];
409 ns[2] = '\0';
410 }
411 if (strcmp(ns,"%l") == 0)
412 {
415 {
416 char* ns = (
char*)
omAlloc(strlen((
char*)
res->data) + 2);
417 strcpy(ns, (
char*)
res->data);
419 strcat(ns, "\n");
421 }
422 }
423 else if (strcmp(ns,"%t") == 0)
424 {
429 ((
char*)
res->data)[strlen((
char*)
res->data) -1] =
'\0';
430 }
431 else if (strcmp(ns,"%;") == 0)
432 {
437 }
438 else if (strcmp(ns,"%p") == 0)
439 {
441 }
443 {
448 }
449 else
450 {
453 {
454 char* ns = (
char*)
omAlloc(strlen((
char*)
res->data) + 2);
455 strcpy(ns, (
char*)
res->data);
457 strcat(ns, "\n");
459 }
460 }
462 }
464}
BOOLEAN iiExprArith1(leftv res, leftv a, int op)
static void ipPrintBetti(leftv u)