#include <iostream>
#include <iomanip>
upol_i wilk(int n) {
upol_i w("x-1");
for (int j = 2; j <= n; j++) {
c[0] = -j;
}
return w;
}
upol_i mign(int a, int n, int m) {
upol_i f(1,n,0);
}
upol_i mign2(int a, int n, int m, int k) {
upol_i f(a,1,0);
f=f+integer(1);
f = f^k;
}
void mirror(upol_i & f) {
for (unsigned i=1;i<f.size();i+=2)
f[i]=-f[i];
}
template<class S, class P>
{
typedef typename P::Ring R;
unsigned start, total;
std::cout <<"\n----------- Input:\n"<<f<< std::endl;
std::cout <<"\n* Using B-Splines: "<<std::endl;
start = clock();
std::cout <<" First root in [2, 4]: "<<
std::cout <<" First positive root : "<<
solver<ring<double,Bernstein>,
Bspline>::first_root(f)<<std::endl;
total= clock () - start;
std::cout << "Computed in " << total << " ms"<< std::endl;
start= clock ();
std::cout <<"\n* Using CF solver: "<<std::endl;
std::cout <<" First root in (2, 4) (isolate) : "<<
std::endl;
std::cout <<" First positive root (isolate) : "<<
std::endl;
total= clock () - start;
std::cout << "Computed in " << total << " ms"<< std::endl;
std::cout <<" First root in (2, 4) (floor) : "<<
std::endl;
std::cout <<" First root in (2, 4) (approximate): "<<
std::endl;
std::cout <<" First positive root (floor) : "<<
std::endl;
std::cout <<" First positive root (approximate) : "<<
std::endl;
std::cout <<"\n* Positive real root(s) by CF : "<<
std::endl;
std::cout <<"\n* Separate real root(s) by CF : "<<
std::endl;
std::cout <<"\n* Real root(s) by Sleeve : "
}
int main(
int argc,
char** argv)
{
upol_i f;
upol_r g("22341334*x^8-2334457888*x^2-71232212*x+34554356");
f=upol_i("22341334*x^8-2334457888*x^2-71232212*x+34554356");
return 0;
}