Parcourir la source

Remove debug stuff in approx version

Jean Fromentin il y a 5 ans
Parent
commit
49453ab825
3 fichiers modifiés avec 6 ajouts et 14 suppressions
  1. 1 1
      approx/config.hpp
  2. 4 6
      approx/main.cpp
  3. 1 7
      approx/polygon.cpp

+ 1 - 1
approx/config.hpp

@@ -6,7 +6,7 @@
 using namespace std;
 
 //! Maximal self avoiding polygon length to consider
-static const size_t max_len=8; // Must be less or equal tin [6,38]
+static const size_t max_len=20; // Must be less or equal tin [6,38]
 
 typedef double Reel;
 typedef __int128 Int;

+ 4 - 6
approx/main.cpp

@@ -36,7 +36,7 @@ void treat(Polygon* P){
   delete P;
 }
 int main(){
-  cout<<std::setprecision(4);
+  cout<<std::setprecision(20);
   disp_info();
   compute_coeffs();
   size_t nb[max_len/2];
@@ -52,13 +52,11 @@ int main(){
   while(gen.next()){
     P=new Polygon;
     gen.set(*P);
-    //    if(P->length==4){
-    //cilk_spawn
+    cilk_spawn
     treat(P);
-      //}
     ++total;
   }
-  //  cilk_sync;
+  cilk_sync;
   Reel d=256;
   for(size_t i=1;2*i<max_len;++i){
     Reel l=2*i+2;
@@ -67,7 +65,7 @@ int main(){
     Reel n=2*l;
     coeff[i]=(n*r)/d;
     cout<<" > number : "<<cilk_result.numbers(i)<<endl;
-    cout<<" >  value : "<<coeff[i]<<endl; 
+    cout<<" >  value : "<<coeff[i]<<endl;
     d*=16;
   }
   cout<<endl<<">>> Total : "<<total<<endl;

+ 1 - 7
approx/polygon.cpp

@@ -133,16 +133,10 @@ Polygon::fp() const{
       AvxC.get(i,j)=get_coeff(dx,dy);
     }
   }
-  cout<<"Matrix B"<<endl;
-  AvxB.display(ne,ne);
-  cout<<"Matrix C"<<endl;
-  AvxC.display(ne,ne);
   AvxMatrix AvxM;
   AvxM.clear();
   AvxM.from_C_B(AvxC,AvxB,ne);
-  cout<<"Matrix M"<<endl;
-  AvxM.display(ne,ne);
-
+ 
   Reel det=AvxM.Gauss(ne,ne+1);
 
   Reel res=0;