diff options
author | Aaron LI <aly@aaronly.me> | 2019-01-17 15:19:44 +0800 |
---|---|---|
committer | Aaron LI <aly@aaronly.me> | 2019-01-17 15:19:44 +0800 |
commit | d2bebaa1f91c9b3e46297c51e64b50aa93563f3a (patch) | |
tree | 2191277714421d52086a3b1bdb6469bdccfd48c3 /fg21sim/extragalactic/clusters/main.py | |
parent | 576bdca6372710bdd52107e57e944d843bd89a11 (diff) | |
download | fg21sim-d2bebaa1f91c9b3e46297c51e64b50aa93563f3a.tar.bz2 |
clusters/main: Account for baryon fraction in _simulate_mergers()
Diffstat (limited to 'fg21sim/extragalactic/clusters/main.py')
-rw-r--r-- | fg21sim/extragalactic/clusters/main.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fg21sim/extragalactic/clusters/main.py b/fg21sim/extragalactic/clusters/main.py index 52e179c..8affc6c 100644 --- a/fg21sim/extragalactic/clusters/main.py +++ b/fg21sim/extragalactic/clusters/main.py @@ -225,13 +225,14 @@ class GalaxyClusters: logger.info("Simulating merger histories for each cluster ...") num = len(self.catalog) num_hasmerger = 0 + fdm = 1 - COSMO.baryon_fraction for i, cdict in enumerate(self.catalog): ii = i + 1 if ii % 100 == 0: logger.info("[%d/%d] %.1f%% ..." % (ii, num, 100*ii/num)) z0, M0, age0 = cdict["z"], cdict["mass"], cdict["age"] zmax = COSMO.redshift(age0 - self.time_traceback) - clform = ClusterFormation(M0=M0, z0=z0, zmax=zmax, + clform = ClusterFormation(M0=M0*fdm, z0=z0, zmax=zmax, merger_mass_min=self.merger_mass_min) clform.simulate_mtree(main_only=True) mergers = clform.mergers() @@ -239,8 +240,8 @@ class GalaxyClusters: num_hasmerger += 1 cdict.update([ ("merger_num", len(mergers)), - ("merger_mass1", [ev["M_main"] for ev in mergers]), - ("merger_mass2", [ev["M_sub"] for ev in mergers]), + ("merger_mass1", [ev["M_main"]/fdm for ev in mergers]), + ("merger_mass2", [ev["M_sub"]/fdm for ev in mergers]), ("merger_z", [ev["z"] for ev in mergers]), ("merger_age", [ev["age"] for ev in mergers]), ]) |