MCPcopy Create free account
hub / github.com/Singular/Singular / wDimensions

Function wDimensions

libpolys/polys/weight.cc:34–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32void wGcd(int *x, int n);
33
34static void wDimensions(poly* s, int sl, int *lpol, int *npol, int *mons)
35{
36 int i, i1, j, k;
37 poly p, q;
38
39 i1 = j = 0;
40 for (i = 0; i <= sl; i++)
41 {
42 p = s[i];
43 if (p!=NULL)
44 {
45 k = 1;
46 q = pNext(p);
47 while (q!=NULL)
48 {
49 k++;
50 q = pNext(q);
51 }
52 if (k > 1)
53 {
54 lpol[i1++] = k;
55 j += k;
56 }
57 }
58 }
59 *npol = i1;
60 *mons = j;
61}
62
63
64static void wInit(poly* s, int sl, int mons, int *A, const ring R)

Callers 1

wCallFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected