realroot_doc 0.1.1
polynomial_mv_test.cpp
# include <iostream>
# include <realroot/polynomial_sparse.hpp>
  
int main(int argc, char** argv) 
{
  using namespace mmx;

  typedef ring<double, Sparse, DegRevLex >::Polynomial       Polynomial;
  typedef polynomial< double, with<Sparse, LexRevDegree> >   PolynomialR;

 //  typedef polynomial< double, with<Monomials > >             Tensor;
//   typedef polynomial< Polynomial, with<Monomials> >          TensorPol;
//   typedef polynomial< Tensor, with<Sparse, LexRevDegree> >   PolTensor;
//   typedef polynomial< Polynomial, with<Sparse,LexRevDegree> >  PolPol;

  Polynomial   f("t^2+u^2*t^2+u^2+3*u*t+u-1");
  std::cout << "f   : " << f << std::endl; 
  PolynomialR   fr("t^2+u^2*t^2+u^2+3*u*t+u-1");
  std::cout << "f   : " << fr << std::endl; 


  Seq<Polynomial> s=coefficients(f,1);
  std::cout << "f   : " << s << std::endl; 
 //  TensorPol g(1,2);
//   std::cout << "g   : " << g<<std::endl; 
//   g[0]=s[0];  g[1]=s[1];  g[2]=s[2];
//   std::cout << "g   : " << g<<std::endl; 
//   return 0;
}