def assign_dis(self, c, H0, Omega_M, Omega_L): """ Function that calculates the angular diameter distance for a Z_bin instance. """ self.dcmv = cosmo.dcomvoldz(self.z, Omega_M, Omega_L) self.da = (c / H0) * cosmo.angdidis(self.z, Omega_M, Omega_L)
def assign_dis(self, c, H0, Omega_M, Omega_L): """ Function that calculates the angular diameter distance for a Z_bin instance. """ self.dcmv = cosmo.dcomvoldz(self.z, Omega_M, Omega_L) self.da = ((c / H0) * cosmo.angdidis(self.z, Omega_M, Omega_L))
def __init__(self, id, z): """ Function that initialises a Z_bin instance. """ self.id = id self.z = z self.count = 0 self.r_ref = 0 self.dcmv = cosmo.dcomvoldz(z, opts.Omega_M, opts.Omega_L) self.link_z = opts.link_z / (1 + self.z) self.da = ((opts.c / opts.H0) * cosmo.angdidis(self.z, opts.Omega_M, opts.Omega_L))
def __init__(self, data, number): """ Function that initialises a Galaxy instance. """ self.num = number self.id = data[opts.id_col - 1] self.ra = float(data[opts.ra_col - 1]) self.dec = float(data[opts.dec_col - 1]) self.z = float(data[opts.z_col - 1]) self.dz = float(data[opts.dz_col - 1]) self.v = self.z / (1 + self.z) self.da = ((opts.c / opts.H0) * cosmo.angdidis(self.z, opts.Omega_M, opts.Omega_L)) self.x, self.y = astro.radec2xy(self.ra, self.dec, self.da)
def __init__(self, data, number): """ Function that initialises a Galaxy instance. """ self.num = number self.id = data[opts.id_col - 1] self.ra = float(data[opts.ra_col - 1]) self.dec = float(data[opts.dec_col - 1]) self.z = float(data[opts.z_col - 1]) self.dz = float(data[opts.dz_col - 1]) self.v = self.z / (1 + self.z) self.da = ((opts.c / opts.H0) * cosmo.angdidis(self.z, opts.Omega_M, opts.Omega_L)) self.x = math.sin(astro.deg2rad(90 - self.dec)) * math.cos(astro.deg2rad(self.ra)) * self.da self.y = math.sin(astro.deg2rad(90 - self.dec)) * math.sin(astro.deg2rad(self.ra)) * self.da self.photoz_bins = []
def __init__(self, data, number): """ Function that initialises a Galaxy instance. """ self.num = number self.id = data[opts.id_col - 1] self.ra = float(data[opts.ra_col - 1]) self.dec = float(data[opts.dec_col - 1]) self.z = float(data[opts.z_col - 1]) self.dz = float(data[opts.dz_col - 1]) self.v = self.z / (1 + self.z) self.da = ((opts.c / opts.H0) * cosmo.angdidis(self.z, opts.Omega_M, opts.Omega_L)) self.x = math.sin(astro.deg2rad(90 - self.dec)) * math.cos( astro.deg2rad(self.ra)) * self.da self.y = math.sin(astro.deg2rad(90 - self.dec)) * math.sin( astro.deg2rad(self.ra)) * self.da self.photoz_bins = []
def assign_dis(self, c, H0, Omega_M, Omega_L): """ Function that calculates the angular diameter distance for a Galaxy instance. """ self.da = (c / H0) * cosmo.angdidis(self.z, Omega_M, Omega_L)
def assign_dis(self, c, H0, Omega_M, Omega_L): """ Function that calculates the angular diameter distance for a Galaxy instance. """ self.da = ((c / H0) * cosmo.angdidis(self.z, Omega_M, Omega_L))