Changeset 3120 in Sophya for trunk/Cosmo/SimLSS/cmvobserv3d.cc


Ignore:
Timestamp:
Dec 21, 2006, 4:45:09 PM (19 years ago)
Author:
cmv
Message:

Suite de la mise dans la base cvs cmv 21/12/2006

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Cosmo/SimLSS/cmvobserv3d.cc

    r3115 r3120  
    1212#include "srandgen.h"
    1313#include "perandom.h"
     14#include "fabtwriter.h"
    1415
    1516#include "arrctcast.h"
     
    3132     <<" -z nz,dz : taille en z (npix,Mpc)"<<endl
    3233     <<" -Z zref : redshift median"<<endl
    33      <<" -s scale : sigma du bruit en Msol"<<endl
     34     <<" -s snoise : sigma du bruit en Msol"<<endl
    3435     <<endl;
    3536}
     
    163164 pkz.SetZ(zref);
    164165
    165  Histo hpkz (lkmin,lkmax,npt); hpkz.ReCenterBin();
     166 Histo hpkz(lkmin,lkmax,npt); hpkz.ReCenterBin();
    166167 FuncToHisto(pkz,hpkz,true);
    167168 {
     
    330331     <<rs2<<" -> "<<sqrt(rs2)<<endl;
    331332
     333 if(1) {
     334   cout<<"\n---Writing Cube to Fits file"<<endl;
     335   FitsImg3DWriter fwrt("!cmvobserv3dr.fits",FLOAT_IMG,5);
     336   fwrt.WriteKey("ZREF",zref," redshift");
     337   vector<long> n = fluct3d.GetNpix();
     338   fwrt.WriteKey("NX",n[0]," axe transverse 1");
     339   fwrt.WriteKey("NY",n[1]," axe transverse 2");
     340   fwrt.WriteKey("NZ",n[2]," axe longitudinal (redshift)");
     341   vector<r_8> d;
     342   d = fluct3d.GetDinc();
     343   fwrt.WriteKey("DX",d[0]," Mpc");
     344   fwrt.WriteKey("DY",d[1]," Mpc");
     345   fwrt.WriteKey("DZ",d[2]," Mpc");
     346   d = fluct3d.GetKinc();
     347   fwrt.WriteKey("DKX",d[0]," Mpc^-1");
     348   fwrt.WriteKey("DKY",d[1]," Mpc^-1");
     349   fwrt.WriteKey("DKZ",d[2]," Mpc^-1");
     350   fwrt.WriteKey("SNOISE",snoise," Msol");
     351   fwrt.Write(rgen);
     352 }
     353
    332354 cout<<"\n--- Add noise to HI Flux snoise="<<snoise<<endl;
    333355 fluct3d.AddNoise2Real(snoise);
     
    364386objaoper pkgen sliceyz 0
    365387
    366 n/plot hpkz.val%x x>0 ! "connectpoints"
    367 n/plot hpkgen.val%log10(x) x>0 ! "same red connectpoints"
    368 n/plot hpkgenf.val%log10(x) x>0 ! "same pink connectpoints"
    369 n/plot hpkrec.val%log10(x) x>0 ! "same blue connectpoints"
     388n/plot hpkz.val%x ! ! "nsta connectpoints"
     389n/plot hpkgen.val%log10(x) x>0 ! "nsta same red connectpoints"
     390n/plot hpkgenf.val%log10(x) x>0 ! "nsta same orange connectpoints"
     391n/plot hpkrec.val%log10(x) x>0 ! "nsta same blue connectpoints"
    370392
    371393set k pow(10.,x)
     
    379401rgensl 0
    380402
     403disp hmdndm
     404disp tirhmdndm
     405addline 0 1 20 1 "red"
     406
    381407 */
Note: See TracChangeset for help on using the changeset viewer.