#include <boost/python.hpp>
#include "kernel/mod2.h"
#include "Poly.h"
Go to the source code of this file.
◆ export_poly()
Definition at line 29 of file poly_wrap.cc.
30{
31 boost::python::class_<Poly>("Polynomial", "Wrapper for poly of Singular")
33 .def(boost::python::init <int>())
34 .def(boost::python::init <Poly>())
35
36 .def(boost::python::init <Number>())
37 .def(boost::python::init <Intvec> ())
39 .def("__iter__", boost::python::iterator<Poly>())
40
41 .def(boost::python::init <const char* >())
42
45
46 .def(-self)
47 .def(self*=self)
48 .def(self+=self)
49
50
51
52 .def(self+self)
58
59 .def(self*self);
60
61}
static Ring Poly_get_Ring(const Poly &p)
boost::python::str Poly_as_str(const Poly &p)
◆ Poly_as_str()
boost::python::str Poly_as_str |
( |
const Poly & |
p | ) |
|
Definition at line 10 of file poly_wrap.cc.
11{
12 using boost::python::str;
13
14
15 char* out=
p.c_string();
16 return boost::python::str(out,strlen(out));
17}
◆ Vector_as_str()
Definition at line 18 of file poly_wrap.cc.
19{
20 using boost::python::str;
21
22
23 char* out=
p.c_string();
24 return boost::python::str(out,strlen(out));
25}