Index: /trunk/Cosmo/SimLSS/cmvobserv3d.cc
===================================================================
--- /trunk/Cosmo/SimLSS/cmvobserv3d.cc	(revision 3133)
+++ /trunk/Cosmo/SimLSS/cmvobserv3d.cc	(revision 3134)
@@ -265,6 +265,6 @@
 
  cout<<"\n--- Check mean and variance in real space"<<endl;
- size_t nlowone = fluct3d.NumberOfBad(-1.,1e+200);
- double rm,rs2; size_t nm;
+ int_8 nlowone = fluct3d.NumberOfBad(-1.,1e+200);
+ double rm,rs2; int_8 nm;
  nm = fluct3d.MeanSigma2(rm,rs2);
  cout<<"rgen:("<<nm<<") Mean = "<<rm<<", Sigma^2 = "
@@ -274,5 +274,5 @@
    cout<<"\n--- Check variance sigmaR in real space"<<endl;
    double varr;
-   size_t nvarr = fluct3d.VarianceFrReal(R,varr);
+   int_8 nvarr = fluct3d.VarianceFrReal(R,varr);
    cout<<"R="<<R<<" : sigmaR^2="<<varr<<" -> "<<sqrt(varr)<<",   n="<<nvarr<<endl;
  }
Index: /trunk/Cosmo/SimLSS/genefluct3d.cc
===================================================================
--- /trunk/Cosmo/SimLSS/genefluct3d.cc	(revision 3133)
+++ /trunk/Cosmo/SimLSS/genefluct3d.cc	(revision 3134)
@@ -127,5 +127,5 @@
  double sntot = sqrt((double)NRtot_);
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    data[ip] = NorRand()/sntot;
  }
@@ -259,5 +259,5 @@
        long i=0;
        if(ii==1) {if( Nx_%2!=0) continue; else i = Nx_/2;}
-       size_t ip = k+NCz_*(j+Ny_*i);
+       int_8 ip = k+NCz_*(j+Ny_*i);
        //cout<<"i="<<i<<" j="<<j<<" k="<<k<<" = ("<<fdata[ip][0]<<","<<fdata[ip][1]<<")"<<endl;
        fdata[ip][1] = 0.; fdata[ip][0] *= M_SQRT2;
@@ -279,6 +279,6 @@
      if(jj==1) {if( Ny_%2!=0) continue; else j = Ny_/2;}
      for(long i=1;i<(Nx_+1)/2;i++) {
-       size_t ip = k+NCz_*(j+Ny_*i);
-       size_t ip1 = k+NCz_*(j+Ny_*(Nx_-i));
+       int_8 ip = k+NCz_*(j+Ny_*i);
+       int_8 ip1 = k+NCz_*(j+Ny_*(Nx_-i));
        fdata[ip1][0] = fdata[ip][0]; fdata[ip1][1] = -fdata[ip][1];
        nconj1++;
@@ -289,6 +289,6 @@
      if(ii==1) {if( Nx_%2!=0) continue; else i = Nx_/2;}
      for(long j=1;j<(Ny_+1)/2;j++) {
-       size_t ip = k+NCz_*(j+Ny_*i);
-       size_t ip1 = k+NCz_*((Ny_-j)+Ny_*i);
+       int_8 ip = k+NCz_*(j+Ny_*i);
+       int_8 ip1 = k+NCz_*((Ny_-j)+Ny_*i);
        fdata[ip1][0] = fdata[ip][0]; fdata[ip1][1] = -fdata[ip][1];
        nconj1++;
@@ -307,6 +307,6 @@
      for(long i=1;i<Nx_;i++) {
        if(Nx_%2==0 && i==Nx_/2) continue; // on ne retraite pas nyquist en i
-       size_t ip = k+NCz_*(j+Ny_*i);
-       size_t ip1 = k+NCz_*((Ny_-j)+Ny_*(Nx_-i));
+       int_8 ip = k+NCz_*(j+Ny_*i);
+       int_8 ip1 = k+NCz_*((Ny_-j)+Ny_*(Nx_-i));
        fdata[ip1][0] = fdata[ip][0]; fdata[ip1][1] = -fdata[ip][1];
        nconj2++;
@@ -445,5 +445,5 @@
 
 //-------------------------------------------------------
-size_t GeneFluct3D::VarianceFrReal(double R,double& var)
+int_8 GeneFluct3D::VarianceFrReal(double R,double& var)
 // Recompute MASS variance in spherical top-hat (rayon=R)
 {
@@ -457,10 +457,10 @@
  cout<<"dnx="<<dnx<<" dny="<<dny<<" dnz="<<dnz<<endl;
 
- double sum=0., sum2=0., r2 = R*R; size_t nsum=0;
+ double sum=0., sum2=0., r2 = R*R; int_8 nsum=0;
 
  for(long i=dnx;i<Nx_-dnx;i+=dnx) {
    for(long j=dny;j<Ny_-dny;j+=dny) {
      for(long l=dnz;l<Nz_-dnz;l+=dnz) {
-       double s=0.; size_t n=0;
+       double s=0.; int_8 n=0;
        for(long ii=i-dnx;ii<=i+dnx;ii++) {
          double x = (ii-i)*Dx_; x *= x;
@@ -470,5 +470,5 @@
              double z = (ll-l)*Dz_; z *= z;
              if(x+y+z>r2) continue;
-             size_t ip = ll+NTz_*(jj+Ny_*ii);
+             int_8 ip = ll+NTz_*(jj+Ny_*ii);
              s += 1.+data[ip];
              n++;
@@ -496,5 +496,5 @@
 
 //-------------------------------------------------------
-size_t GeneFluct3D::NumberOfBad(double vmin,double vmax)
+int_8 GeneFluct3D::NumberOfBad(double vmin,double vmax)
 // number of pixels outside of ]vmin,vmax[ extremites exclues
 //     ->  vmin and vmax are considered as bad
@@ -502,7 +502,7 @@
  double *data = (double *) (&T_(0,0,0));
 
- size_t nbad = 0;
- for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+ int_8 nbad = 0;
+ for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
+   int_8 ip = l+NTz_*(j+Ny_*i);
    double v = data[ip];
    if(v<=vmin || v>=vmax) nbad++;
@@ -512,5 +512,5 @@
 }
 
-size_t GeneFluct3D::MeanSigma2(double& rm,double& rs2,double vmin,double vmax)
+int_8 GeneFluct3D::MeanSigma2(double& rm,double& rs2,double vmin,double vmax)
 // mean,sigma^2 pour pixels avec valeurs ]vmin,vmax[ extremites exclues
 //   -> mean and sigma^2 are NOT computed with pixels values vmin and vmax
@@ -518,9 +518,9 @@
  double *data = (double *) (&T_(0,0,0));
 
- size_t n = 0;
+ int_8 n = 0;
  rm = rs2 = 0.;
 
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    double v = data[ip];
    if(v<=vmin || v>=vmax) continue;
@@ -538,5 +538,5 @@
 }
 
-size_t GeneFluct3D::SetToVal(double vmin, double vmax,double val0)
+int_8 GeneFluct3D::SetToVal(double vmin, double vmax,double val0)
 // set to "val0" if out of range ]vmin,vmax[ extremites exclues
 //     ->  vmin and vmax are set to val0
@@ -544,7 +544,7 @@
  double *data = (double *) (&T_(0,0,0));
 
- size_t nbad = 0;
- for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+ int_8 nbad = 0;
+ for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
+   int_8 ip = l+NTz_*(j+Ny_*i);
    double v = data[ip];
    if(v<=vmin || v>=vmax) {data[ip] = val0; nbad++;}
@@ -563,5 +563,5 @@
 
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    data[ip] += 1.;
  }
@@ -580,5 +580,5 @@
 
  double m,s2;
- size_t ngood = MeanSigma2(m,s2,0.,1e+200);
+ int_8 ngood = MeanSigma2(m,s2,0.,1e+200);
  if(lp) cout<<"TurnMass2MeanNumber: ngood="<<ngood
             <<" m="<<m<<" s2="<<s2<<" -> "<<sqrt(s2)<<endl;
@@ -596,5 +596,5 @@
  double sum = 0.;
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    data[ip] *= dn; // par coherence on multiplie aussi les <=0
    if(data[ip]>0.) sum += data[ip];  // mais on ne les compte pas
@@ -617,5 +617,5 @@
  double sum = 0.;
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    double v = data[ip];
    if(v>0.) {
@@ -647,5 +647,5 @@
  double sum = 0.;
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    double v = data[ip];
    if(v>0.) {
@@ -676,5 +676,5 @@
 
  for(long i=0;i<Nx_;i++) for(long j=0;j<Ny_;j++) for(long l=0;l<Nz_;l++) {
-   size_t ip = l+NTz_*(j+Ny_*i);
+   int_8 ip = l+NTz_*(j+Ny_*i);
    data[ip] += snoise*NorRand();
  }
Index: /trunk/Cosmo/SimLSS/genefluct3d.h
===================================================================
--- /trunk/Cosmo/SimLSS/genefluct3d.h	(revision 3133)
+++ /trunk/Cosmo/SimLSS/genefluct3d.h	(revision 3134)
@@ -29,5 +29,5 @@
   double GetVol(void) {return Vol_;}
   double GetDVol(void) {return dVol_;}
-  size_t NPix(void) {return NRtot_;}
+  int_8 NPix(void) {return NRtot_;}
   double GetKmax(void) {return sqrt(Knyqx_*Knyqx_+Knyqy_*Knyqy_+Knyqz_*Knyqz_);}
   vector<r_8> GetKinc(void)
@@ -47,8 +47,8 @@
   void ReComputeFourier(void);
 
-  size_t VarianceFrReal(double R,double& var);
-  size_t MeanSigma2(double& rm,double& rs2,double vmin=-1.e+150,double vmax=1.e+150);
-  size_t NumberOfBad(double vmin=-1.e+150,double vmax=1.e+150);
-  size_t SetToVal(double vmin, double vmax,double val0=0.);
+  int_8 VarianceFrReal(double R,double& var);
+  int_8 MeanSigma2(double& rm,double& rs2,double vmin=-1.e+150,double vmax=1.e+150);
+  int_8 NumberOfBad(double vmin=-1.e+150,double vmax=1.e+150);
+  int_8 SetToVal(double vmin, double vmax,double val0=0.);
 
   void TurnFluct2Mass(void);
@@ -71,5 +71,5 @@
   sa_size_t SzK_[3];
   long NCz_,NTz_;
-  size_t NRtot_;
+  int_8 NRtot_;
   double Dx_,Dy_,Dz_;
   double dVol_, Vol_;
