Changeset 3802 in Sophya for trunk/Cosmo
- Timestamp:
- Jul 22, 2010, 2:49:20 PM (15 years ago)
- Location:
- trunk/Cosmo/SimLSS
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Cosmo/SimLSS/cmvrvloscor.cc
r3800 r3802 368 368 n/plot hpkrec2.val%sqrt(x*x+y*y) ! ! "nsta crossmarker3 logx" 369 369 370 # les matrices 2D 371 set n 0 372 disp mx_$n 373 newwin 374 disp mxc_$n 375 370 376 defscript tom 371 377 del m2 … … 376 382 endscript 377 383 378 # les matrices 2D 379 set n 0 380 disp mx_$n 381 newwin 382 disp mxc_$n 384 ###### Comparaison avec le spectre initial 385 cd /home 386 mkdir ok 387 mkdir gene 388 cd /home 389 390 cd /ok 391 openppf cmvrvloscor.ppf 392 tom 393 cd /home 394 395 cd /gene 396 openppf ginit3d_?_?p?_???.ppf 397 tom 398 cd /home 399 400 h/oper / /ok/m2 /gene/m2 mdiff 401 disp mdiff 383 402 */ -
trunk/Cosmo/SimLSS/cmvtransf.cc
r3572 r3802 69 69 TransfertEisenstein tfnob(h100,Om0-Ob0,Ob0,tcmb,true); // No baryons 70 70 71 TransfertTabulate tfcmbfast (h100,Om0-Ob0,Ob0);71 TransfertTabulate tfcmbfast; 72 72 bool cmbfastOK = false; 73 73 if(fcmbfast.size()>0) { 74 74 cout<<endl<<"TransfertTabulate for CMBfast"<<endl; 75 tfcmbfast.ReadCMBFast(fcmbfast );75 tfcmbfast.ReadCMBFast(fcmbfast,h100,Om0-Ob0,Ob0); 76 76 tfcmbfast.SetInterpTyp(1); 77 77 if(tfcmbfast.NPoints()>0) cmbfastOK = true; -
trunk/Cosmo/SimLSS/pkspectrum.cc
r3768 r3802 295 295 /////////////////////////////////////////////////////////// 296 296 297 TransfertTabulate::TransfertTabulate(double h100,double OmegaCDM0,double OmegaBaryon0) 298 : Oc_(OmegaCDM0) , Ob_(OmegaBaryon0) , h100_(h100) , kmin_(1.) , kmax_(-1.) 299 , interptyp_(0) 297 TransfertTabulate::TransfertTabulate(void) 298 : kmin_(1.) , kmax_(-1.) , interptyp_(0) 300 299 { 301 300 } 302 301 303 302 TransfertTabulate::TransfertTabulate(TransfertTabulate& tf) 304 : Oc_(tf.Oc_) , Ob_(tf.Ob_) , h100_(tf.h100_) , kmin_(tf.kmin_) , kmax_(tf.kmax_) 305 , interptyp_(tf.interptyp_) , k_(tf.k_) , tf_(tf.tf_) 303 : kmin_(tf.kmin_) , kmax_(tf.kmax_) , interptyp_(tf.interptyp_) , k_(tf.k_) , tf_(tf.tf_) 306 304 { 307 305 } … … 323 321 } 324 322 325 int TransfertTabulate::ReadCMBFast(string filename )323 int TransfertTabulate::ReadCMBFast(string filename,double h100,double OmegaCDM0,double OmegaBaryon0) 326 324 { 327 325 FILE *file = fopen(filename.c_str(),"r"); 328 326 if(file==NULL) return -1; 327 cout<<"TransfertTabulate::ReadCMBFast: fn="<<filename<<" h100="<<h100 328 <<" OmegaCDM0="<<OmegaCDM0<<" OmegaBaryon0="<<OmegaBaryon0<<endl; 329 329 330 330 const int lenline = 512; … … 336 336 double k,tc,tb,tf; 337 337 sscanf(line,"%lf %lf %lf",&k,&tc,&tb); 338 k *= h100 _; // convert h^-1 Mpc -> Mpc339 tf = (O c_*tc+Ob_*tb)/(Oc_+Ob_);338 k *= h100; // convert h Mpc^-1 -> Mpc^-1 339 tf = (OmegaCDM0*tc+OmegaBaryon0*tb)/(OmegaCDM0+OmegaBaryon0); 340 340 if(tf>tmax) tmax = tf; 341 341 k_.push_back(k); -
trunk/Cosmo/SimLSS/pkspectrum.h
r3768 r3802 55 55 class TransfertTabulate : public GenericFunc { 56 56 public: 57 TransfertTabulate( double h100,double OmegaCDM0,double OmegaBaryon0);57 TransfertTabulate(void); 58 58 TransfertTabulate(TransfertTabulate& tf); 59 59 virtual ~TransfertTabulate(void); … … 61 61 int NPoints(void) {return k_.size();} 62 62 void SetInterpTyp(int typ=0); 63 int ReadCMBFast(string filename );63 int ReadCMBFast(string filename,double h100,double OmegaCDM0,double OmegaBaryon0); 64 64 protected: 65 double Oc_,Ob_,h100_;66 65 double kmin_,kmax_; 67 66 int interptyp_;
Note:
See TracChangeset
for help on using the changeset viewer.