1 | #ifndef INITIAL_H |
---|
2 | #define INITIAL_H |
---|
3 | |
---|
4 | /*** |
---|
5 | * various functions to compute the initial form of polynomials and ideals |
---|
6 | **/ |
---|
7 | |
---|
8 | #include <gfanlib/gfanlib_vector.h> |
---|
9 | #include <libpolys/polys/monomials/p_polys.h> |
---|
10 | #include <Singular/ipid.h> |
---|
11 | |
---|
12 | /*** |
---|
13 | * Computes the weighted degree of the leading monomial of p with respect to w |
---|
14 | **/ |
---|
15 | long wDeg(const poly p, const ring r, const gfan::ZVector w); |
---|
16 | |
---|
17 | /*** |
---|
18 | * Computes the weighted multidegree of the leading term of p with respect to W. |
---|
19 | * The weighted multidegree is a vector whose i-th entry is the weighted degree |
---|
20 | * with respect to the i-th row vector of W. |
---|
21 | **/ |
---|
22 | gfan::ZVector WDeg(const poly p, const ring r, const gfan::ZMatrix W); |
---|
23 | |
---|
24 | /*** |
---|
25 | * Returns the first terms of p of same weighted degree under w. |
---|
26 | * Coincides with the initial form of p with respect to w if and only if p was already |
---|
27 | * sorted with respect to w. |
---|
28 | **/ |
---|
29 | poly sloppyInitial(const poly p, const ring r, const gfan::ZVector w); |
---|
30 | |
---|
31 | /*** |
---|
32 | * Runs the above procedure over all generators of an ideal. |
---|
33 | * Coincides with the initial ideal of I with respect to w if and only if |
---|
34 | * the elements of I were already sorted with respect to w and |
---|
35 | * I is a standard basis form with respect to w. |
---|
36 | **/ |
---|
37 | ideal sloppyInitial(const ideal I, const ring r, const gfan::ZVector w); |
---|
38 | |
---|
39 | poly initial(const poly p, const ring r, const gfan::ZVector w); |
---|
40 | ideal initial(const ideal I, const ring r, const gfan::ZVector w); |
---|
41 | poly initial(const poly p, const ring r, const gfan::ZMatrix W); |
---|
42 | poly initial(const ideal I, const ring r, const gfan::ZMatrix W); |
---|
43 | |
---|
44 | |
---|
45 | poly initial(const poly p, const ring r); |
---|
46 | ideal initial(const ideal I, const ring r); |
---|
47 | BOOLEAN initial(leftv res, leftv args); |
---|
48 | #ifndef NDEBUG |
---|
49 | BOOLEAN initial0(leftv res, leftv args); |
---|
50 | #endif |
---|
51 | |
---|
52 | #endif |
---|