Changeset 3773 in Sophya for trunk/Cosmo/SimLSS/cmvrvloscor.cc
- Timestamp:
- May 9, 2010, 12:47:58 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Cosmo/SimLSS/cmvrvloscor.cc
r3771 r3773 11 11 #include "timing.h" 12 12 #include "dvlist.h" 13 #include " ntuple.h"13 #include "histos.h" 14 14 #include "fabtcolread.h" 15 15 … … 27 27 { 28 28 int nthread = 1; 29 SophyaInit(); 30 InitTim(); 29 int_8 nhfill = 100000; 31 30 32 31 if(narg<=2) {usage(); return -1;} … … 35 34 try { 36 35 //----TRY-CATCH-TRY-CATCH-TRY-CATCH-TRY-CATCH-TRY-CATCH-TRY-CATCH 36 37 SophyaInit(); 38 InitTim(); 37 39 38 40 cout<<"> read rho: "<<arg[1]<<endl; … … 52 54 cout<<"Zref="<<Zref<<" Href="<<Href<<endl; 53 55 56 double dmin = min(Dx,min(Dy,Dz)); 57 double nmax = max(Nx,max(Ny,Nz)); 58 cout<<"dmin="<<dmin<<" nmax="<<nmax<<endl; 59 Histo hmpc(-dmin*nmax,dmin*nmax,4.*nmax); 60 nhfill = (int_8)Nx*(int_8)Ny*(int_8)Nz/nhfill; if(nhfill<=0) nhfill = 1; 61 54 62 POutPersist pos("cmvrvloscor.ppf"); 55 63 … … 58 66 TArray<GEN3D_TYPE>& rgen = fluct3d.GetRealArray(); 59 67 rgen = 0.; 60 TVector<r_8> R(Nz), Rdis(Nz); 68 TVector<GEN3D_TYPE> R(Nz), V(Nz); 69 TVector<r_8> Rdis(Nz); 61 70 62 71 cout<<"> filling redshift distorted cube"<<endl; 72 int_8 nread = 0; 63 73 for(int i=0;i<Nx;i++) { 64 74 if(i%(Nx/10)==0) cout<<"i="<<i<<endl; 65 75 for(int j=0;j<Ny;j++) { 66 for(int l=0;l<Nz;l++) R(l) = f3dr.Read(l,j,i); 76 //for(int l=0;l<Nz;l++) R(l) = f3dr.Read(l,j,i); 77 //for(int l=0;l<Nz;l++) V(l) = f3dv.Read(l,j,i); 78 f3dr.Read(j,i,R); 79 f3dv.Read(j,i,V); 67 80 Rdis = 0.; 68 81 for(int l=0;l<Nz;l++) { 69 double d = (1.+Zref) / Href * f3dv.Read(l,j,i); 82 double d = (1.+Zref) / Href * V(l); 83 if(nread%nhfill==0) hmpc.Add(d); 70 84 double lpd = (double)l + d/Dz; // valeur du deplacee 71 85 // on repartit proportionnelement au recouvrement sur 2 pixels … … 80 94 } 81 95 PrtTim(">>>> End filling redshift distorted cube"); 96 pos.PutObject(hmpc,"hmpc"); 82 97 83 98 fluct3d.ReComputeFourier(); … … 131 146 openppf cmvrvloscor.ppf 132 147 148 disp hmpc 149 133 150 n/plot hpkrec.val%x x>0 ! "nsta cpts logx" 134 151 … … 144 161 145 162 # proj selon kT (black), selon kZ (red) 146 n/plot hpkrec2.val%sqrt(x*x+y*y) ! ! "nsta c pts"163 n/plot hpkrec2.val%sqrt(x*x+y*y) ! ! "nsta crossmarker3 logx" 147 164 */
Note:
See TracChangeset
for help on using the changeset viewer.