IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 39748


Ignore:
Timestamp:
Oct 13, 2016, 12:51:32 PM (10 years ago)
Author:
eugene
Message:

fix solar motion model construction : distance was in pc, not kpc; bump up density of Gaia objects to something realistic

Location:
branches/czw_branch/20160809/Ohana/src/fakeastro/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/czw_branch/20160809/Ohana/src/fakeastro/src/args.c

    r39743 r39748  
    128128  }
    129129
    130   MAX_MAG_GAIA = 16.0;
     130  MAX_MAG_GAIA = 21.0;
    131131  if ((N = get_argument (*argc, argv, "-gaia-limit"))) {
    132132    remove_argument (N, argc, argv);
  • branches/czw_branch/20160809/Ohana/src/fakeastro/src/make_fake_stars_catalog.c

    r39743 r39748  
    117117
    118118    // XXX TEST
    119     dDsee = dRsee = 0.0;
     119    // dDsee = dRsee = 0.0;
    120120
    121121    double dRoff = (dRpm + dRsee) / 3600.0;
  • branches/czw_branch/20160809/Ohana/src/fakeastro/src/make_fakestars.c

    r39739 r39748  
    3535      // we can generate a distribution which is uniform on the sky, in which case
    3636      // we can limit to the selected patch analyically
     37
     38      // note: r & z are generated in parsec
    3739      r = pow(drand48(), 0.33333) * FAKEASTRO_RGAL;
    3840      z = 0.0;
     
    4850      int inPatch = FALSE;
    4951      while (!inPatch) {
     52        // note: r & z are generated in parsec
    5053        z = ohana_gaussdev_rnd (0.0, FAKEASTRO_ZGAL);
    5154        r = sqrt(drand48()) * FAKEASTRO_RGAL;
     
    6871    // double y = r*sin(L);
    6972
     73    // distance here is in parsec
    7074    double distance = sqrt (SQ(r) + SQ(z));
    7175
     
    7478
    7579    double uL_sol, uB_sol;
    76     SolarMotionModel_radians(&uL_sol, &uB_sol, Lrad, Brad, distance);
     80    SolarMotionModel_radians(&uL_sol, &uB_sol, Lrad, Brad, distance / 1000.0);
     81    // note: SolarMotionModel wants distance in kpc
    7782
    7883    double uL = uL_gal + uL_sol;
  • branches/czw_branch/20160809/Ohana/src/fakeastro/src/make_gaia_measures.c

    r39743 r39748  
    4242
    4343    // make a crude G-i color for now:
    44     double G_PS1 = secfilt[i*Nsecfilt + Nsec].M + 1.0; // make all stars have G-i = 1.0
     44    double G_PS1 = secfilt[i*Nsecfilt + Nsec].M; // make all stars have G-i = 1.0
    4545    if (G_PS1 > MAX_MAG_GAIA) continue; // only generate GAIA detections for objects with G_PS1 < 21.0
    4646
     
    7878
    7979    // uR,uD in linear arcsec
    80     double dRsee = ohana_gaussdev_rnd (0.0, 1.0 / SN);
    81     double dDsee = ohana_gaussdev_rnd (0.0, 1.0 / SN);
     80    double dRsee = ohana_gaussdev_rnd (0.0, 0.01 / SN);
     81    double dDsee = ohana_gaussdev_rnd (0.0, 0.01 / SN);
    8282
    8383    // XXX TEST
    84     dDsee = dRsee = 0.0;
     84    // dDsee = dRsee = 0.0;
    8585
    8686    double dRoff = (dRpm + dRsee) / 3600.0;
Note: See TracChangeset for help on using the changeset viewer.