{'fraction_non_alphanumeric': 0.04382458704030028, 'fraction_numerical': 0.025415108666064955, 'mean_word_length': 4.4699474962777215, 'pattern_counts': {'":': 0, '<': 169, '<?xml version=': 0, '>': 24, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
The Effects of Environment on the Evolution of the Galaxy Stellar Mass Function

We study the effects of galaxy environment on the evolution of the stellar-mass function (SMF) over 0.2<z<2.0 using the FourStar Galaxy Evolution (ZFOURGE) survey and NEWFIRM Medium-Band Survey (NMBS) down to the stellar-mass completeness limit, log M / Msun>9.0 (9.5) at z = 1.0 (2.0). We compare the SMFs for quiescent and star-forming galaxies in the highest and lowest environments using a density estimator based on the distance to the galaxies' third-nearest neighbors. For star-forming galaxies, at all redshifts there are only minor differences with environment in the shape of the SMF. For quiescent galaxies, the SMF in the lowest densities shows no evolution with redshift, other than an overall increase in number density (phi*) with time. This suggests that the stellar-mass dependence of quenching in relatively isolated galaxies is both universal and does not evolve strongly. While at z>~ 1.5 the SMF of quiescent galaxies is indistinguishable in the highest and lowest densities, at lower redshifts it shows a rapidly increasing number density of lower-mass galaxies, log M / Msun ~= 9-10. We argue this evolution can account for all the redshift evolution in the shape of the total quiescent-galaxy SMF. This evolution in the quiescent-galaxy SMF at higher redshift (z>1) requires an environmental-quenching efficiency that decreases with decreasing stellar mass at 0.5<z<1.5 or it would overproduce the number of lower-mass quiescent galaxies in denser environments. This requires a dominant environment process such as starvation combined with rapid gas depletion and ejection at z>0.5 - 1.0 for galaxies in our mass range. The efficiency of this process decreases with redshift allowing other processes (such as galaxy interactions and ram-pressure stripping) to become more important at later times, z<0.5.


INTRODUCTION
How galaxies quench their star-formation depends on the interplay between gas accretion, gas cooling, and the strength and timescales of feedback (see e.g., Somerville & Davé 2015;Feldmann et al. 2017). In the nearby and distant Uni- (Baldry et al. 2006;Peng et al. 2010), but in the more distant Universe, the evidence suggests otherwise (see Kovač et al. 2014;Balogh et al. 2016;Kawinwanichakij et al. 2017). It is important to quantify this evolution in the strength of mass quenching and environmental quenching because these constrain the mechanisms and timescales of the physical processes themselves.
If the strength of quenching depends on galaxy redshift, stellar mass, and environment, then this should be visible in the differential evolution of the stellar mass functions (SMFs) of galaxies. Observations of the galaxy SMF in the nearby Universe with the Sloan Digital Sky Survey (SDSS; at z ∼ 0.085, Baldry et al. 2006;Peng et al. 2010) show significant differences for star-forming and quiescent galaxies as a function of environment, including a steeper low-mass slope for quiescent galaxies in denser environments.
In the more distant Universe, measurements of the dependence of SMF on environment have yet to reach consensus. Most studies compare the SMF in massive groups and clusters to the field over 0 < z < 2. Some find no evidence for significant differences (once the brightest cluster galaxy is excluded; Vulcani et al. 2012Vulcani et al. , 2013Andreon 2013;van der Burg et al. 2013;Nantais et al. 2016, although see, Rudnick et al. 2012;Tomczak et al. 2017). Other studies find differences at relatively lower redshift (z 0.8), that disappear by z ∼ 1 (Bolzonella et al. 2010;Giodini et al. 2012;Mok et al. 2013;Etherington et al. 2017), at least for galaxies more massive than "M * " (the characteristic mass of the SMF). This is consistent with other studies of the SMF in denser environments such as in high-redshift (0.8 < z < 1) groups (e.g., Mok et al. 2013;Balogh et al. 2016;Tomczak et al. 2017) and high redshift (1 < z < 1.5) clusters (Andreon 2013;van der Burg et al. 2013;Nantais et al. 2016;Tomczak et al. 2017), where some have found a deficit of low-mass quiescent galaxies (and low-mass star-forming galaxies) compared to mass-matched field samples.
One complication is that many of the studies of groups and clusters compare to "field" surveys that include rich groups and clusters. For example, the 1.6 deg 2 UltraVISTA survey of the COSMOS field (Muzzin et al. 2013a) is a frequentlyreferenced field sample, but it covers a range of environmental densities and includes rich groups (or even poor clusters, e.g., Giodini et al. 2012). If environmental quenching or "preprocessing" occurs in low-mass group environments, then care must be made to ensure that the effects of environment do not bias the results from field samples. Studies that separate galaxies in field surveys into samples of high and low-density regions find stronger differences in the SMF at least to z < 1.3 (e.g., Tomczak et al. 2017), with no measurable difference at higher redshift (although studies report tentative evidence that the low-mass slope of the SMF is steeper for galaxies in higher density environments out to z ∼ 1.5; Mortlock et al. 2015).
Because we have yet to obtain good constraints on the evolution of the SMF of star-forming and quiescent galaxies in different environments, we have yet to constrain the dominant environmental quenching processes, and to determine if these processes change with time. Here we study the evolution of the galaxy SMF as a function of environment, star-formation activity, and redshift over 0.2 < z < 2.0 using two, homogeneous datasets that combine differing depth and area, the photometric-redshift FourStar Galaxy Evolution (ZFOURGE) survey (Straatman et al. 2016) and the NEWFIRM Medium-Band Survey (Whitaker et al. 2011, NMBS). Both surveys provide very accurate photometric redshifts, able to resolve structures on scales of <4000 km s −1 . This allows for the identification of rich galaxy overdensities (e.g., Spitler et al. 2012;Forrest et al. 2017) and minimizes inaccuracies associated with environmental measures derived from photometric redshift surveys with larger redshift errors (see, e.g., Cooper et al. 2005;Malavasi et al. 2016). Recently, Kawinwanichakij et al. (2017) used these ZFOURGE data to measure the environmental quenching efficiency. They quantified the excess quenching as a function of increasing galaxy overdensity (environment) and showed this must decrease with stellar mass for galaxies at high redshifts to account for the relatively low fraction of quenched galaxies in any environment at high redshift. Here, we use these data to study how and when the environment affects the build-up of the number density of low-mass quiescent galaxies.
Following Kawinwanichakij et al. (2017), we measure the local galaxy density as a proxy for environment using a Bayesian-motivated measure of the distance to the thirdnearest neighbor (3NN), introduced by Ivezić et al. (2005) (see also Cowan & Ivezić 2008). Muldrew et al. (2012) find that the Nth-nearest neighbor technique best probes the local environment on scales internal to galaxy halos for lower values of N. Kawinwanichakij et al. demonstrate that quantifying galaxy density with 3NN recovers physical structures and robustly identifies galaxies in the highest and lowest regions of the density distribution using the same datasets used here. In addition, we argue that using a lower value of N (here N=3) to select overdensities is appropriate to this work as it will allow us to identify both rich groups and clusters (see, e.g., Muldrew et al. 2012;Shattow et al. 2013). This allows us to identify a more complete range of structures at higher redshift that will collapse to cluster-sized objects at z = 0. For example, using a set of simulations, Shattow et al. (2013) show that selecting overdensities with the Nth nearest neighbor (for N ≤ 10) identifies a range of overdensity covering a 2-3 dex range at z = 2 that become very overdense at z = 0 (with typical z = 0 halo masses log(M h /M ⊙ ) ∼ 14.5, with a spread of about 0.5 dex). In the present work, we select galaxies in the highest and lowest density quartiles based on the 3NN density measurements, and we compare the evolution of the SMF for star-forming and quiescent galaxies in these regions.
Following literature conventions (see, e.g., Peng et al. 2010;Davies et al. 2016;Kawinwanichakij et al. 2017), we refer to two kinds of quenching, that which correlates with galaxy stellar mass ("mass quenching"), and that which correlates with galaxy overdensity ("environmental quenching"). Here, "mass quenching" is any process that acts internally to a galaxy, and "environmental quenching" is any process that is related to the local environment. These may both be manifestations of the same physics: e.g., they may be related to quenching due to processes associated with galaxy halo mass ("halo quenching", e.g., Dekel & Birnboim 2006;Cattaneo et al. 2008). Mass quenching would then correspond to the quenching of central galaxies, where their stellar mass scales approximately with halo mass. Environmental quenching would result from processes that act as galaxies become satellites, and also be related to the halo mass of the central galaxy. Nevertheless, in this work we differentiate quenching that correlates with stellar mass (mass quenching) from quenching that correlates with overdensity (environmental quenching) as this ties the measurements as closely as possible to observables.
The outline of this paper is as follows. § 2 discusses the datasets and sample selection. § 3 describes our estimate of the galaxy environment. § 4 presents the galaxy SMFs for these samples, including the SMF for quiescent and starforming galaxies as a function of redshift and environment. § 5 discusses the implications for environmental quenching processes, and how these impact the evolution of the shape of the galaxy SMF. Throughout, the majority of the emphasis is on the evolution of the SMF of quiescent galaxies, and Appendix A discusses the (lack of) evolution in the shape of the SMF for star-forming galaxies.
Throughout we use a cosmology with Ω M = 0.3, Ω Λ = 0.7, and h=0.7, where H 0 = 100 h km s −1 Mpc −1 consistent with the recent constraints from Planck (Planck Collaboration et al. 2016) and the local distance scale of Riess et al. (2016). We also assume a universal Chabrier IMF for the derivation of galaxy stellar masses. All magnitudes are in "absolute bolometric" (AB) units (Oke & Gunn 1983).

DATA AND SAMPLE SELECTION
We use data from the ZFOURGE and NMBS public catalogs Straatman et al. 2016). For ZFOURGE, we used the v3.4 K s -band-selected catalog reaching K s = 25.5 − 26.0 mag (80% completeness) in the three fields (CDF-S, COSMOS, and UDS) covering a total of about 300 arcmin 2 (Straatman et al. 2016). For NMBS, we use the K s -band catalogs for the Cosmic Evolution Survey (COSMOS) and All-wavelength Extended Groth strip International Survey (AEGIS) fields, which cover a larger area (≈1500 arcmin 2 ) but to shallower depth, K s = 22.1 − 22.5 mag (Whitaker et al. 2011, 90% completeness). Both the ZFOURGE and NMBS catalogs include colors measured from medium-band imaging, which provide accurate photometric redshifts, ∆z/(1 + z) ≃ 1 − 2%, and rest-frame (U −V ) 0 and (V − J) 0 colors. From the photometric catalogs and redshifts, both ZFOURGE and NMBS provide stellar masses, where the ZFOURGE dataset achieves limiting stellar masses of log M * /M ⊙ >9.5 at z=2.0, reaching to low-mass galaxies (1 dex below M * ). We refer the reader to Whitaker et al. (2011) andStraatman et al. (2016) for details.
We classify galaxies as quiescent or star-forming based on their rest-frame (U − V ) 0 and (V − J) 0 colors, where quiescent galaxies are red in (U − V ) 0 and relatively blue in (V − J) 0 compared to mass-matched star-forming galaxies (e.g., Labbé et al. 2005;Wuyts et al. 2007;Williams et al. 2009;Whitaker et al. 2011;Papovich et al. 2015). We select quiescent galaxies that satisfy, where star-forming galaxies lie outside this region. Here, we use (A, B) = (1.2, 0.20) and (0.88, 0.65) for ZFOURGE (Kawinwanichakij et al. 2016) and NMBS ), respectively. The values for A and B depend on the specifics of each dataset, and exhibit a possible dependence on redshift. The slope, A, is chosen to run parallel to the sequence of red galaxies, and the intercept, B, is chosen to place the dividing line at the local minimum between the sequences of quiescent and star-forming galaxies. This has the effect of minimizing uncertainties in the sample selection arising from scatter in the galaxies' rest-frame colors (see discussion in Kawinwanichakij et al. 2016). While different color selection limits change the sample somewhat, this is not a dominant effect as it affects relatively few galaxies for sensible choices of A and B. For example, adopting the NMBS values for A and B would decrease the number of quiescent galaxies in ZFOURGE by ≃6% (and vice versa). This is smaller than the expected fractional error from other effects, such as stellar mass uncertainties (∼10% statistically for quiescent galaxies, although systematics can be factors of ∼2, e.g., Papovich et al. 2006;Marchesini et al. 2009;Muzzin et al. 2009;Brammer et al. 2011) and rest-frame color uncertainties (∼0.1 mag, e.g., Whitaker et al. 2011).

ESTIMATE OF ENVIRONMENT
We use the local surface density of galaxies, Σ, as an estimator of the local environment of each galaxy, as derived by Kawinwanichakij et al. (2017). This approach is based on the projected distance to the Nth-nearest neighbor, d N , where the local galaxy surface density is then Σ N = N(πd 2 N ) −1 . As discussed by Ivezić et al. (2005), the precision of this approach can be improved (by a factor of order 2) using a Bayesian estimator that includes the distances of all neighbors up to the Nth-nearest neighbor. Kawinwanichakij et al. (2017) use this estimator based on work of Cowan & Ivezić (2008), where the local surface density of galaxies is where d i is the distance to the ith-nearest neighbor and C is chosen such that Σ ′ N matches the density of a uniform grid of points. As in Kawinwanichakij et al. (2017), we use N=3, which provides the best compromise between recovering the highest-and lowest-density regions and minimizing lineof-sight projections. Using this (relatively low) value, N=3, makes our measurement more sensitive to halos of L * -sized galaxies and groups (log M h /M ⊙ 12.5), with relatively low contamination of galaxies in poor environments of lowermass halos with few satellites (e.g., Muldrew et al. 2012). This is advantageous as many of the environmental effects are expected to manifest in such regions (see § 1, and discussion in Kawinwanichakij et al. 2017).
For this work we contrast the properties of galaxies in the top quartile of the density distribution (D4, i.e., the highest density quartile) with those in the bottom quartile of the density distribution (D1, i.e., the lowest density quartile), similar to the work of Peng et al. (2010). As in Kawinwanichakij et al. (2017), we determined these quartiles using a non-parametric quantile regression method (specifically, the COnstrained B-Splines (COBS) linear regression method, Ng & Maechler 2007;Feigelson & Babu 2012) applied to the ZFOURGE and NMBS data. For the ZFOURGE stellar-mass limit and our choice of redshift binning, the surface densities dividing the quartiles are roughly constant with redshift (using a redshift window of ∆z = 0.05(1 + z phot ) when identifying neighboring galaxies; see Figure 2 of Kawinwanichakij et al. 2017). In this redshift interval, to our stellar mass limit, the median surface density of galaxies is approximately 30 arcmin −2 , independent of redshift (Kawinwanichakij et al. 2017). The limiting surface density for the highest (D4) density quartile is roughly Σ ′ 3 > 43 galaxies arcmin −2 , and for the lowest density quartile (D1) it is roughly Σ ′ 3 <13 galaxies arcmin −2 , both mostly independent of redshift (see Kawinwanichakij et al. 2017).

THE DEPENDENCE OF THE STELLAR MASS FUNCTION ON ENVIRONMENT
To construct the SMFs, we sub-divided the galaxies into bins of redshift and star-formation activity (quiescent and star-forming), and as a function of environment using the lowest-density (D1) and highest-density quartiles (D4) as described above ( § 2). The SMFs are then where m = log M * /M ⊙ is the base-10 logarithm of the stellar mass, and the sum is over all N galaxies with (log) stellar mass between m and m + ∆m. V c is the comoving volume and depends on the redshift bounds that mark the sample, and geometry of the survey. Figure 1 shows these SMFs compared to the total galaxy SMFs from ZFOURGE in bins of redshift, from z = 0.5 to 2.0. 1 Note that we have not corrected any of the SMFs for incompleteness in stellar mass (in which case V c is the same for all galaxies in a given redshift bin), but we denote the stellar masses where the SMFs become incomplete using values derived in Kawinwanichakij et al. (2017). We furthermore have not corrected the environmental measures for "edge effects" (see Kawinwanichakij et al. 2017). Figure 1 shows the SMFs we derived from ZFOURGE at 0.5 < z < 2.0, and NMBS 0.2 < z < 0.5 for quiescent and star-forming galaxies as a function of overdensity. The figure also shows SMFs from SDSS at z < 0.1 taken from Baldry et al. (2006) for red-and blue-sequence galaxies (akin to the quiescent and star-forming galaxies studied here) in regions of high (log Σ = 1.0), moderate (log Σ = 0), and low (log Σ = −1.1) overdensity scaled to match the number density of our SMFs in NMBS at 0.2 < z < 0.5.
From Figure 1 we draw our first two conclusions regarding the dependence of the SMF with environment and starformation activity. First, for star-forming galaxies there is little environmental dependence in the shape of the SMF. At all redshifts from z ∼ 0 to 2 the shape and normalization of the SMF of star-forming galaxies in D1 and D4 are approximately indistinguishable. However, at z > 0.5 the SMF of star-forming galaxies in the highest densities does show an excess in the number density of log M * /M ⊙ ≃ 10.5 galaxies compared to that at lowest densities. This may indicate the propensity of more massive star-forming galaxies to be found in richer environments at higher redshifts (e.g., Quadri et al. 2012;Kawinwanichakij et al. 2017). This excess declines (or even reverses) at z < 0.5 (see also Peng et al. 2010). Figure 1. Evolution of the Stellar Mass Function (SMF) for quiescent and star-forming galaxies from the ZFOURGE survey (0.5 < z < 2.0) and NMBS (0.2 < z < 0.5). All panels show the total galaxy SMF (solid black line) as a function of redshift, as labeled. The top row of panels shows the evolution of the SMF for all quiescent galaxies, and for quiescent galaxies in the highest density quartile (D4) and lowest density quartile (D1), as labeled. The bottom row of panels shows the evolution of the SMF for all star-forming galaxies and for star-forming galaxies in D4 and D1, as labeled. Light-gray shaded points and lines show where the data fall below the stellar mass completeness for the redshifts of each panel. Error bars correspond only to Poissonian uncertainties using the number of galaxies in each data point. The right-most panels in each row show SMFs from SDSS at z < 0.1 derived in high densities, moderate densities, and low densities (Baldry et al. 2006), scaled to match the normalization of our SMFs derived from the NMBS at 0.2 < z < 0.5 (see text). The SMF for quiescent galaxies shows a dependence on density while there is no such strong dependence for the SMF of star-forming galaxies.
Second, for quiescent galaxies the shape of the SMF depends strongly on environment and redshift. At all redshifts, the normalization of the SMF is higher in denser environments. The shape of the SMF also evolves with redshift: there is a rapid increase in the number density of quiescent galaxies in higher density environments with decreasing redshift, particularly at lower stellar masses. These differences become more pronounced at lower redshifts (z 1), and the trend continues from our ZFOURGE dataset at z > 0.5, to the NMBS dataset over 0.2 < z < 0.5, and down to z < 0.1 in SDSS (see also Baldry et al. 2006;Peng et al. 2010).
Upon further scrutiny, the shape of the SMF of quiescent galaxies in the lowest density (D1) quartile shows no evidence of any evolution over the entire redshift range, 0.2 < z < 2.0. Figure 2 shows the relative differences in the quiescent galaxies SMF in D1 and D4, compared to that in the NMBS data at 0.2 < z < 0.5 (where we have normalized each SMF to have the same number density at log M * /M ⊙ =10.6). The right panel of Figure 2 shows that the SMFs of quiescent galaxies in the lowest density quartiles are consistent with no evolution in redshift (within the uncertainties). This suggests that in the lowest densities, the (stellar) mass dependence of quenching in relatively isolated galaxies does not evolve with time, at least down to our mass-completeness limit (log M * /M ⊙ > 9.0 − 9.5, consistent with the suggestion by Peng et al. 2012). This is not to say that there is no environmental quenching in such systems. For example, even relatively isolated L * galaxies (including the Milky Way Galaxy) show high fractions of quenched satellites, particularly at lower stellar masses (log M * /M ⊙ 8.5, Geha et al. 2012;Slater & Bell 2014;Wetzel et al. 2015;Davies et al. 2016;Geha et al. 2017), which show environmental processes are Figure 2. Relative evolution of the SMF for quiescent galaxies as a function of environment. The left panel shows the ratio of the SMF for quiescent galaxies in the highest density quartile (D4) in each redshift bin to the SMF for quiescent galaxies in the highest density quartile at 0.2 < z < 0.5 (the constant C acts to normalize each SMF to the same number density at log M * /M⊙=10.6). The right panel shows the same for quiescent galaxies in the lowest density quartile (D1) The gray-shaded points and lines show data below the stellar mass completeness limit. There is no evidence that the shape of the SMF evolves for quiescent galaxies in the lowest-density quartile. In contrast, in the highest density quartile, there is rapid redshift evolution in the SMF, particularly in the relative number density of low-mass quiescent galaxies. at work. Rather our result implies that the stellar-mass dependence of quenching (either mass or environmental) does not evolve in these low-density environments over the range of galaxy stellar masses considered here.
For quiescent galaxies in the highest density environments, Figure 2 shows that the shape of the SMF evolves strongly with mass and redshift. The effect is most pronounced at low stellar masses 9 < log M * /M ⊙ < 10.3, where there is rapid evolution from 1.5 < z < 2.5 to 0.5 < z < 1.0, with less change in the SMF shape from 0.5 < z < 1.0 to 0.2 < z < 0.5. This is important as there is nearly twice as much cosmic time from z = 1.0 to 0.2 (5.4 Gyr) as from z = 2.5 to 1.0 (3.2 Gyr), implying environmental quenching must act on timescales much shorter than this (Quadri et al. 2012;Balogh et al. 2016;Guo et al. 2017). In contrast, for starforming galaxies, there is no evidence for evolution in the shape of the SMF, see Appendix A.
To support these conclusions, we have applied nonparametric statistical tests to the distribution of stellar masses of the galaxies in the different subsamples. Specifically, we used the Kolmogorov-Smirnov (KS) and Mann-Whitney-Wilcoxon (MWW) tests (see Feigelson & Babu 2012) as implemented in R to test the hypothesis that the (unbinned) distributions of stellar mass for the different galaxy subsamples are drawn from the same parent distribution. In all cases we consider the distribution of stellar masses for galaxies down to the stellar-mass completeness limit at each redshift. We also consider only the evolution of the stellar-mass distributions within ZFOURGE to minimize systematics (as all quantities are derived internally from the same dataset) and because it is at z > 0.5 within the ZFOURGE data that the impact of environment is most apparent (see figures 1 and 2). Table 1 lists results (the p-values) of the KS and MWW tests comparing the different galaxy stellar-mass distributions.
Here we focus on the results for quiescent galaxies. Results for star-forming galaxies are described in Appendix A.
We first compared the unbinned stellar-mass distribution of quiescent galaxies in the highest environmental density quartile (D4) at 0.5 < z < 1.0 to the stellar-mass distributions of quiescent galaxies in D4 at higher redshift, 1.0 < z < 1.5 and 1.5 < z < 2.0 (for completeness, we also compare the stellar-mass distributions between the galaxies at 1.0 < z < 1.5 and those at 1.5 < z < 2.0, and in all cases find consistent results). Comparing the stellar-mass distribution of the 0.5 < z < 1.0 galaxies to that at 1.0 < z < 1.5, the KS test gives p = 6.6 × 10 −5 and the MWW test gives p = 8.3 × 10 −4 . Comparing the stellar-mass distribution of the 0.5 < z < 1.0 galaxies to that at 1.5 < z < 2.0, the KS test gives p = 1.0 × 10 −5 and the MWW test gives p = 4.6 × 10 −6 . In all cases we would reject the hypothesis that these stellar mass distributions are drawn from the same parent distribution at >99.9% significance. This supports the claim that there is strong evolution in the shape of the distribution of stellar masses with redshift for quiescent galaxies in the highest environmental densities.
In contrast, comparing the unbinned stellar-mass distribution of quiescent galaxies in the lowest density quartile (D1) at 0.5 < z < 1.0 to the stellar mass distribution of these galax-  (1) Either quiescent or star-forming galaxies, using the definition in § 2.
(2) Environmental density quartile, where D4 is the highest density quartile and D1 is the lowest density quartile (see § 3). (3) The redshift ranges of the galaxy subsamples compared in the tests. (4) The p-value from the KS test. (5) The p-value from the MWW test. The p-value is a likelihood that the samples are drawn from the same parent distribution. A low p-value implies greatly likelihood for differences in the stellar-mass distributions between the galaxy subsamples.
ies 1.0 < z < 1.5 the KS test gives p = 0.05 and the MWW test gives p = 0.17. This provides very weak evidence that they are drawn from different parent distributions (equivalent to ≈ 1.5σ assuming a Gaussian distribution), but could imply some evolution in the shape of the SMF if confirmed by larger datasets. Comparing the stellar-mass distribution at 0.5 < z < 1.0 to the distribution at 1.5 < z < 2.0, the KS test gives p=0.52 and the MWW test gives p=0.81. These tests support the conclusion that there is very little measurable evidence for redshift evolution in the shape of the distribution of stellar masses for quiescent galaxies in the lowest environmental densities.
To quantify the evolution in the SMFs, we fit them with Schechter (1976) functions, defined as × exp(−10 (m−m * ) ) dm, where again for convenience we define m = log 10 M * /M ⊙ as the logarithm of the stellar mass, and m * = log 10 M * /M ⊙ as the logarithm of the characteristic stellar mass. For the fitting, we only included data where the SMFs are complete in stellar mass for quiescent galaxies using the values from Kawinwanichakij et al. (2017). We fit using a Markov Chain Monte Carlo (MCMC) similar to Foreman-Mackey et al.
(2013) and adapted to IDL by R. Russell (2015, private communication). Figure 3 shows example results of the Schechter-function fits to the SMFs for quiescent galaxies from NMBS and ZFOURGE out to z < 1 (see below for discussion of results for higher redshifts). The panels show that out to z < 1 the SMF for quiescent galaxies in the highest density regions (D4) has (1) a higher characteristic mass (log M * ), accompanied by a higher normalization (φ * ), and (2) a steeper lowmass slope (α), relative to the quiescent galaxies in the lowest density regions (D1). These results are significant at >99% confidence (i.e., there is a <1% likelihood that log M * and α are identical). The fact that the results are the same from the two independent datasets, NMBS at 0.2 < z < 0.5 and ZFOURGE at 0.5 < z < 1, increases this significance. This makes the prediction that future surveys, covering more area to our depth will reinforce this conclusion. Figure 4 shows the redshift evolution of the fitted parameters (φ ⋆ , M * , α) of the SMFs for the quiescent galaxies in the highest and lowest density quartiles. We noted above that the shape of the SMF of quiescent galaxies in the lowest density quartile is consistent with no evolution. Figure 4 shows that this is quantitatively true: the quiescent galaxies in the lowest density regions show no evidence of evolution in M * or α over the entire redshift range, 0.2 < z < 2.0, nor is there (statistically) any indication that the parameters change between the independently processed NMBS and ZFOURGE datasets. (In Appendix A we show there is no evidence for evolution in M * or α for star-forming galaxies.) In fact, the evolution in the shape of the of the SMF of quiescent galaxies in the highest density environments tracks that of the total quiescent-galaxy SMF. Tomczak et al. The top-left panel shows the SMF for quiescent galaxies at 0.2 < z < 0.5 in the NMBS. The lines show the best-fitting Schechter model for the SMF for all quiescent galaxies, and for quiescent galaxies in the highest and lowest density quartiles, as labeled. The top-right panel shows the 68% and 95% confidence regions on the characteristic stellar mass (M * ) and the low-mass slope (α) for galaxies in the highest and lowest density quartiles. The bottom panels show the same information for quiescent galaxies in the ZFOURGE (ZF) survey at 0.5 < z < 1.0. In both samples there are significant differences in the model fits for the SMF of quiescent galaxies in the highest and lowest densities, particularly in the low-mass slope.
(2014) showed that the shape of the quiescent galaxy SMF evolves over this redshift range, and here we show this is due to evolution in overdense regions, presumably from evolution in environmental quenching. Figure 4 shows that M * and α evolve strongly for the quiescent galaxies in the highest density regions (D4), and these match the observed evolution in the total quiescent galaxy SMF measured independently (though with an earlier version of the ZFOURGE dataset, Tomczak et al. 2014). The figure also shows that there is an overall increase in the normalization (φ * ) of the SMF in all environments, as expected as structure grows in all cosmic densities (e.g., Springel et al. 2005).
To summarize these findings, (1) there is no evidence that the SMF of star-forming galaxies depends strongly on environment at any redshift (with some difference in the number density of massive star-forming galaxies); (2) the SMF of quiescent galaxies does depend strongly on environment; (3), while there is no evidence that the shape of the SMF of quiescent galaxies in the lowest density regions (D1) from z = 2.5 to 0.2, we do see strong evolution in the highest density regions (D4). This latter point suggests that the observed evolution in the SMF for the full population of quiescent galaxies is limited to densities where environmental effects are prominent. Figure 4. Evolution of the SMF model parameters for quiescent galaxies as a function of redshift and galaxy density. The panels show the evolution with redshift for the characteristic stellar mass (M * )), the low-mass slope (α), and the normalization (φ * ) from the fits to SMF of quiescent galaxies in NMBS and the ZFOURGE survey. The symbols correspond to the same SMFs in each panel, as labeled. For comparison, the small open, black squares show the evolution of model parameters for the total SMF of quiescent galaxies measured by Tomczak et al. (2014). In the top panels, the gray-shaded region shows the mean range of mean values for M * and α for the low-density environments, which is consistent with no evolution in redshift. The quiescent galaxies in the highest density quartile track the evolution in the total quiescent galaxy SMF. By contrast there is no evidence for any evolution in the shape of the SMF for quiescent galaxies in the lowest-density quartile (defined by log M * and α), down to the ZFOURGE stellar mass limit, other than an overall increase in number density (φ * ).

The Dependence of the Stellar Mass Function on
Environment One of our main conclusions is the rapid increase in the number density of lower mass (log M * /M ⊙ ≃ 9 − 10) quiescent galaxies in denser environments over the redshift range from z ≃ 1.5 to z ≃ 0.2. Previous studies have made similar claims (e.g., Bolzonella et al. 2010;Vulcani et al. 2012;Quadri et al. 2012;van der Burg et al. 2013;Davidzon et al. 2016;Nantais et al. 2016;Etherington et al. 2017). Many of these studies have been restricted by their stellar mass limits to log M/M ⊙ 10, where our results are complete to stellar masses to log M/M ⊙ ≃ 9 − 9.5. This provides better constraints in the SMF fitting (particularly for the M * and α pa-rameters) as the ZFOURGE data are complete to more than ≈1 dex below the characteristic stellar mass, M * . Our results are consistent with the suggestion from Mortlock et al. (2015), who found tentative evidence for a higher number density of quiescent low mass galaxies in denser environments in this redshift range. Balogh et al. (2016) reported a possible lower number density of lower mass quiescent galaxies in groups at 0.8 < z < 1.0, while the SMF of quiescent galaxies in rich clusters at z ∼ 1 showed no difference to the SMF in the field (similar to the findings of van der Burg et al. 2013, using the same data). However, both studies (and others) compared their SMF of cluster galaxies to "field" galaxies from the COSMOS/UltraVISTA data covering 1.6 deg 2 (Muzzin et al. 2013b). As discussed in §1, this poses a complication as UltraVISTA includes many overdense regions similar to the ones in the higher-density quartiles in our analysis. One of our findings is that quiescent galaxies in highest-density regions in such ("field") survey data dominate the shape of the total quiescent galaxy SMF, and this could explain the lack of difference between the cluster and field SMF, and may compromise studies that compare clusters/groups to "field" data that includes such structures. Furthermore, it suggests that the dominant environmental effects driving the evolution of the quiescent galaxy SMF are apparent in overdensities similar to group environments, before the galaxies are accreted into clusters (see also McGee et al. 2009;Fossati et al. 2017). Therefore, we predict that if one restricts the analysis of "field" surveys (such as COSMOS/UltraVISTA) to only regions of lower-than-mean density, one would find results consistent with those we report here.
At the high stellar-mass end, there is also evidence for evolution in the shape of the quiescent galaxy SMF with environment, particularly at z < 1. Figure 4 shows this as the evolution of the characteristic mass, M * , from the parametric fits to the SMFs. Beginning at the highest redshifts, 1.5 < z < 2.0, the characteristic masses of the SMF in the highest and lowest density quartiles are consistent with each other. Differences develop over time (decreasing redshift), where at z < 1.5 we find that M * is larger in the highest density regions compared to the lowest density regions, reaching a difference of ∼0.5 dex (factor of order 3) by z ∼ 0.5. The fact that this is observed in our analyses of the independent NMBS and ZFOURGE datasets reinforces the significance of this result (this is also consistent with the findings of Mortlock et al. 2015).
Remarkably, in the lowest-density regions, there is no indication that the shape of the SMF evolves for quiescent galaxies. This is seen in Figure 4 as a lack of observed evolution in M * or α for quiescent galaxies in low densities. This means that any mass growth for quiescent galaxies appears to be isolated to higher density regions. The lowest density environments continue to produce quiescent galaxies, as we do observe an increase in φ ⋆ with decreasing redshift. This can be explained by a universal process that continuously quenches galaxies, producing new quiescent galaxies, and acts in all density regions (e.g., this may be related to halo quenching of all galaxies above a mass threshold, Dekel & Birnboim 2006;Cattaneo et al. 2008).
Much of the growth in quiescent galaxies is expected to occur through non-dissipative ("dry") mergers (e.g., Oser et al. 2010;van Dokkum et al. 2010). Our findings therefore suggest that these mergers occur only rarely for galaxies in low density regions (or we would expect evolution in M * ). In contrast, we do observe strong M * evolution for quiescent galaxies in higher density regions, starting at z 1 (Fig-ure 4). This is consistent with studies that advocate for enhanced or accelerated growth of quiescent galaxies in highdensity regions at high redshifts (e.g., Papovich et al. 2012;Rudnick et al. 2012;Andreon 2013;Bassett et al. 2013;Newman et al. 2014). Furthermore, the differences in M * for quiescent galaxies as a function of environment appear at the epoch when we expect rapid collapse of groups and clusters (e.g., z ∼ 1 − 1.5, see Muldrew et al. 2015), and we may be witnessing enhanced mergers as galaxies in these structures coalesce (e.g, Lotz et al. 2013). At lower redshifts z < 1, this trend continues, and quiescent galaxies in higher density regions continue to grow, likely through mergers between satellites and centrals (as has been measured in some studies of cluster/group galaxies, e.g., Tran et al. 2005;Bundy et al. 2009;Lidman et al. 2012;Tomczak et al. 2017), or through major mergers of more massive star-forming galaxies that also occur more frequently in denser environments (e.g., Hopkins et al. 2010;Davies et al. 2016). These merger events may be nearly non-existent for quiescent galaxies in low-density environments.
For star-forming galaxies, there is no measurable difference in the evolution of the SMF with environment over the range 0.2 < z < 2.0 (e.g., Figure 1). This is consistent with previous findings from 0.02 < z < 1.3 that the shape of the SMF for star-forming galaxies is mostly independent of environment (Peng et al. 2010;Giodini et al. 2012;van der Burg et al. 2013;Davidzon et al. 2016). Other studies at redshifts z 0.2 counter this with evidence that the SMF of star-forming galaxies shows a higher normalization or shift to higher characteristic stellar masses in denser environments (X-ray groups and clusters) compared to the field (Giodini et al. 2012;Mok et al. 2013;Davidzon et al. 2016;Tomczak et al. 2017). A reason for these differences may be differences in the definition of environment, as here we use the relative overdensity rather than quantities that scale with halo mass (such as X-ray luminosity or velocity dispersion) as used in the other studies. To rectify this possible difference will require a critical comparison of the results from both methods applied to the same datasets, which is beyond the scope of this work. Regardless, in our study environment appears to play at most a very small role in shaping the SMF of star-forming galaxies, except perhaps in the highest densities of richer clusters than we probe here.

Implications for the Environmental Quenching
Efficiency One contentious point in the literature is whether the effects of mass quenching (quenching associated with processes internal to the galaxy that scale with stellar mass) and environmental quenching (quenching associated with changes in the average galaxy density) are separable (i.e., non-covariant; § 1). If they are, then it implies that the same environmental effect(s) act on all galaxies independent of their stellar mass, and this in turn constrains the dominant environmental process(es). While there is strong observational evidence that the effects are separable at lowredshifts (e.g., Peng et al. 2010), there is growing evidence that the environmental quenching includes a dependence on galaxy stellar mass at high redshifts (Balogh et al. 2016;Kawinwanichakij et al. 2017).
Previous studies quantify the mass quenching and environmental quenching in terms of the quenching efficiency. The mass-quenching efficiency is then defined as the excess quenching with increasing stellar mass, holding environment (overdensity) fixed; the environmental-quenching efficiency is the excess quenching with increasing galaxy overdensity, holding stellar mass fixed (e.g., Peng et al. 2010, and other references in § 1). 2 Using ZFOURGE data, Kawinwanichakij et al. (2017) measured an environmental quenching efficiency from the fraction of quenched galaxies as a function stellar mass and overdensity. They showed that at higher redshift, z 0.5, the environmental quenching efficiency must decline with decreasing stellar mass to account for the low fraction of lower mass quiescent galaxies. Our results for the evolution of the galaxy SMF requires an environmental quenching efficiency that both (1) evolves with time and (2) depends on stellar mass. If this were not the case (and the environmental quenching efficiency was constant with stellar mass), then the shape of the quiescent galaxy SMF in high density environments would appear quite different from the one observed. The reason for this is that the low-mass slope of the star-forming galaxy SMF is very steep, α ∼ −1.2 to −1.5, identical in high density and low density regions (Figure 1), and nearly unchanging with redshift ( Figure 1; see also Tomczak et al. 2014). If the environmental quenching efficiency were constant (mass-invariant), then the low-mass end of the quiescent galaxy SMF should show a similarly (steep) low-mass slope, which is not supported by the data. Figures 5 and 6 illustrate this point with a simple experiment. At both 0.5 < z < 1.0 and 1.0 < z < 1.5 we model the quiescent galaxy SMF in the highest density regions (D4) by summing the quiescent galaxy SMF in the lowest density regions (D1) with a fraction of the SMF of star-forming galaxies. This simple model represents the sum of those galaxies that have been quenched by mass only (argued to be the case for D1) with the fraction of star-forming galaxies recently quenched by their environment, represented by the environmental quenching efficiency. Note that this ex-periment excludes other effects, such as merging between galaxies, which could change the relative number of lowmass and high-mass galaxies (see discussion above and, e.g., Tomczak et al. 2017). Specifically, for the case of a massconstant environmental quenching efficiency (dǫ/dM * =0) we take, where φ(M * ) Q,D4 is the modeled quiescent galaxy SMF in the highest density regions, φ(M * ) Q,D1 is the measured quiescent galaxy SMF in the lowest density regions, φ(M * ) SF is the star-forming galaxy SMF (in either the highest or lowest density regions as they are so similar), and ǫ = ǫ const is a mass-invariant environmental quenching efficiency. Figure 5 shows this substantially overproduces the number density of low-mass quiescent galaxies in the highest density regions derived from the data at 0.5 < z < 1.0. Figure 6 shows this effect is more pronounced at 1.0 < z < 1.5 where the lowmass end of the quiescent galaxy SMF is even shallower and quenching of star-forming lower-mass galaxies would have even more impact. In contrast, Figures 5 and 6 show that an environmental quenching efficiency that increases with stellar mass reproduces the quiescent galaxy SMF in the highest density regions. For this calculation, we use where all variables are the same as in Equation 5 except the environmental quenching efficiency ǫ(M * ) now varies with stellar mass, where we have taken the measurements from Kawinwanichakij et al. (2017). Figure 5 shows that this environmental quenching efficiency that decreases with decreasing stellar mass qualitatively reproduces the quiescent galaxy SMF in the highest density regions. 3 The implication is that at 0.5 < z < 1.0 and 1.0 < z < 1.5 the environmental quenching efficiency must depend on the stellar mass of the galaxies. There are reasons that our result is seemingly at odds with some previous studies. At z < 0.2 the measured environmental quenching efficiency is nearly constant with stellar mass (Peng et al. 2010;Wheeler et al. 2014). At higher redshift, 0.4 < z < 0.7, some studies argued for a similarly (mass-invariant) constant environmental quenching efficiency (Peng et al. 2010;Kovač et al. 2014). However, these conclusions are limited to relatively moderate stellar masses, log M * /M ⊙ > 10.3 at z = 0.7, where our analysis shows that a Figure 5. Simple experiments of the evolution of the stellar-mass function (SMF) of quiescent galaxies at 0.5 < z < 1.0 in different environments. The models demonstrate that the environmental quenching must be dependent on the stellar mass to reproduce the SMF of quiescent galaxies in different environments. The panels demonstrate an "equation", with some fraction of star-forming galaxies being quenched by the environment and added to the quiescent-galaxy SMF in the lowest density quartile (D1) to represent the quiescent-galaxy SMF in the highest density quartile (D4), as described in Eq. 5 and 6. The left panels show the measured SMF and Schechter-model fit for quiescent and star-forming galaxies in the lowest overdensity quartile (D1) and the highest overdensity quartile (D4), as labeled. The right-hand panels show results derived by adding quenched star-forming galaxies using different environmental quenching efficiencies. The lower row of panels show an environmental quenching efficiency that depends on stellar mass from Kawinwanichakij et al. (2017), and the upper panels show results derived using an environmental quenching efficiency that is constant with stellar mass (with values from Peng et al. 2010;Kovač et al. 2014). A mass-independent environmental quenching efficiency would greatly overproduce the number density of low-mass, quiescent galaxies in high overdensities at z > 0.5. The environmental quenching efficiency must decline with decreasing stellar mass at these redshifts. constant environmental quenching efficiency is able to reproduce observed evolution in the SMF (see Figure 5). It is only by probing to lower stellar masses (where with ZFOURGE we are complete to log M * /M ⊙ ≃ 9 at z = 2: nearly 1 dex below the characteristic stellar mass, M * ) that the massdependence of the environmental quenching efficiency becomes apparent. Indeed, Kovač et al. (2014) acknowledge this possibility, where they stated that they "cannot exclude the existence of a cross term in mass and environment, but this must be within [the] uncertainties". Our results show evidence for such a cross term exists at lower stellar masses (log M * /M ⊙ 10.3).
The environmental quenching efficiency likely also increases in richer environments. This is true at low redshifts (z < 0.2, Peng et al. 2010;Wheeler et al. 2014), and at high redshift (z ∼ 1 − 1.5) where Balogh et al. (2016) and Nantais et al. (2017) reported evidence that the environmental efficiency in clusters is higher than in groups or in the field. As discussed above ( § 3), the environments (halos) of objects in our high density regions likely correspond to groups (with few, if any "clusters"). This suggests that the physical processes that produce the high environmental quenching efficiency act in such group-sized environments (see also Fossati et al. 2017). At high redshifts this means the environmental quenching efficiency depends on both stellar mass and environment (i.e., the halo mass). For example, at fixed stellar mass, e.g., log(M * /M ⊙ ) ≃ 10.5, the environmental quenching efficiency that we require for the evolution of the SMF, ǫ ≃ 0.2 − 0.3, is consistent with that found in groups by Balogh et al.. At lower stellar masses, Balogh et al. find tentative evidence that the environmental quenching efficiency declines, similar to what we require to account for the evolution of the SMF.
Alternatively, one must consider that the evolution we attribute to a mass-dependent environmental quenching efficiency is somehow connected to our use of photometric redshifts. We argue that this is not the case. Our analysis of the relative and absolute uncertainties in the ZFOURGE photometric redshifts show they are are low (σ z /(1 + z) ∼ 0.01 − 0.02) for galaxies to our stellar mass limit (Kawinwanichakij et al. 2014;Tomczak et al. 2014), with no significant differences for quiescent and star-forming galaxies (Straatman et al. 2016). These uncertainties are consistent with comparisons to spectroscopic redshifts (for Figure 6. Same as Figure 5 but for galaxies at 1.0 < z < 1.5. Because the low-mass end of the star-forming galaxy SMF is so steep, an environmental quenching efficiency that is constant in stellar mass would greatly overproduce the number density of low-mass, quiescent galaxies in high overdensities, even more dramatically at this redshift than at 0.5 < z < 1.0. emission-line sources at 1 z 2, Nanayakkara et al. 2016). This redshift accuracy is sufficient to identify regions of high and low density (e.g., Spitler et al. 2012;Malavasi et al. 2016). This is consistent with the analysis of Kawinwanichakij et al. (2017) who showed that with such precise photometric redshifts, one recovers accurately galaxies in the highest and lowest density quartiles compared to densities measured with typical errors of spectroscopic redshifts. Therefore, we do not expect the use of the photometric redshifts to be a dominant driver of our results, but this must be tested by large spectroscopic datasets that include redshifts for quiescent (absorption-line) galaxies down to the magnitude limit of our stellar mass limit (K s ∼ 25 mag; see Straatman et al. 2016).

Implications for the Environment Quenching
Process(es) Our results show the evolution of the quiescent galaxy SMF requires an environmental quenching efficiency that depends on stellar mass at redshifts z > 0.5. In contrast, results at z < 0.2 show that the correlations between stellar mass and environment on quenching are separable (Peng et al. 2010;Wheeler et al. 2014). This suggests that the efficiency of at least one of the physical processes responsible for environmental quenching changes with time. At present, it might then be a cosmic coincidence that the environmental quenching efficiency appears mass invariant, or it could indicate that environmental quenching at present is dominated by a process that is mostly independent of stellar mass. We consider physical processes that would explain these observations. Models for environmental quenching fall broadly into two classes, those that depend on the mass of the halo (and are related to the dynamical time of the satellite galaxy and the halo mass of the central) and those that depend on the properties of the satellite galaxy (and are related to the satellite's stellar or halo mass). In addition, reality may require a combination of the two that depend on both the stellar and halo masses of the central and satellite.
Environmental physical processes that depend on the mass of the halo include gas stripping of both the gaseous halo and/or the interstellar medium of the satellite (e.g., Gunn & Gott 1972;Dekel & Birnboim 2006;McCarthy et al. 2008;Tonnesen & Bryan 2009), or tidal interactions and galaxy mergers (e.g., Farouki & Shapiro 1981;Dekel et al. 2003;Deason et al. 2014). The magnitude of these environmental processes depends on the mass of the central galaxy's halo, and the amount of time a galaxy spends as a satellite, with a weaker dependence on the satellite's stellar mass. It is difficult to estimate the impact of the environmental quenching mechanisms theoretically. For example, models generally have difficulty reproducing the star-formation distribution of observed satellites Weinmann et al. 2010;McCarthy et al. 2011), but they can account for quenching in lower-mass satellites that are more susceptible to effects such as gas stripping and strangulation (Wetzel et al. 2015). Dynamical friction may also cause massive galaxies to segregate toward the center of the potential well of a group, where merging episodes are more likely to occur (see discussion in Giodini et al. 2012). This may explain the strong redshift evolution in the characteristic mass of quiescent galaxies in the highest density regions (Figure 4).
Indirectly, the environmental processes such as strangulation and starvation, where a galaxy's supply of cold gas is cut off, and/or the hot gaseous halo is removed as the galaxy becomes a satellite (Larson et al. 1980;Balogh et al. 2000;Feldmann et al. 2011), can lead to a dependence on the stellar mass of the satellite. In a process dubbed "overconsumption", McGee et al. (2014) demonstrated that the combination of star formation and star-formation-driven outflows in satellites leads to shorter gas depletion timescales. A satellite then quenches rapidly if the halo of the central prevents the accretion of additional gas (Dekel & Birnboim 2006). This process of overconsumption is more efficient at high redshifts where galaxy star-formation rates (SFRs) are generally higher, and it leads to faster quenching in more massive star-forming galaxies (Noeske et al. 2007;Tomczak et al. 2016), because they have shorter gas-depletion timescales (e.g., Genzel et al. 2015;Papovich et al. 2016;Tacconi et al. 2017). McGee et al. show this leads to a predicted environmental quenching efficiency that rises with stellar mass for star-forming satellite galaxies. Our results support a model like overconsumption as they require such a relation between stellar mass and environmental quenching. Balogh et al. (2016) argue overconsumption produces the distribution of quenching and consumption times as a function of satellite mass in both groups and clusters at high redshifts. Our results require that the effects of overconsumption affect galaxies in (poorer) groups (not only rich clusters), as even the galaxies in our highest density regions are most likely associated with such lower-mass structures (see Fossati et al. 2017, and discussion above). Furthermore, overconsumption can easily act in group environments at z > 1, as it requires only that halo of the central be of sufficient mass to prevent gas accretion (M h ∼ 10 12 M ⊙ , Dekel & Birnboim 2006). And most massive structures at z > 1 are galaxy groups, as clusters are still mostly in the act of collapsing (Muldrew et al. 2015;Nantais et al. 2017). In their analysis of groups at 0.5 < z < 3.0, Fossati et al. (2017) advocate for environmental processes where satellites exhaust their gas combined with an absence of gas accretion (akin to the "starvation" and "overconsumption" of McGee et al. 2014). Even for clusters at z ∼ 1.5, Nantais et al. (2016) show that the environmental quenching efficiency of galaxies has little dependence on the cluster-centric distance out to 4 (projected) Mpc (see also Bassett et al. 2013). This further argues for processing of galaxies in groups or cluster outskirts at these redshifts, which is consistent with the interpretation of our results here.
We conclude that a model such as overconsumption has the requisites to be an effective quenching process for galax-ies with stellar masses, log M * /M ⊙ > 9, at redshifts, z > 0.5. At z < 0.5, the fact that there is zero (or only a small) "cross term" between environmental quenching efficiency and mass quenching efficiency (e.g. Peng et al. 2010;Kovač et al. 2014) compared to our results at higher redshift argues that the strength of environmental processes are also evolving with time. This is likely through a combination of effects. The strength of "overconsumption" is expected to be weaker at low redshifts due to two factors (see also McGee et al. 2014). First, satellite SFRs are lower (Madau & Dickinson 2014), and gas-depletion times longer (Genzel et al. 2015), which lengthens the timescale for galaxy starvation. Second, the dynamical time of the halos of central galaxies become shorter relative to the Hubble time (and shorter than the gas-depletion timescales). This allows at late times for alternative environmental processes to act that are associated with the dynamical time of the centralgalaxy halo (such as ram pressure stripping), and the time a galaxy spends as a satellite (and indeed, there is evidence for longer quenching timescales for satellites at z ∼ 0.5 compared to satellites at z ∼ 1 and longer still at z ∼ 0, Guo et al. 2017, and see also, e.g., Tinker & Wetzel 2010). This evolution in the timescales associated with gas-depletion and dynamical time explains both the qualitative redshift evolution and dependence on the stellar mass for the environmental quenching efficiency that we require to explain the evolution of the SMF.
Other environmental processes themselves may also evolve with time. For example, the model proposed by Davies et al. (2016) for galaxies at z < 0.1 include different dominant environmental quenching processes that depend on the satellite stellar mass. Interactions and mass quenching dominate in the most massive galaxies (log M * /M ⊙ > 10), starvation dominates in moderate mass galaxies (log M * /M ⊙ ≃ 8 − 10), and ram-pressure stripping dominates in lower mass galaxies (log M * /M ⊙ < 8 Fillingham et al. 2016). Our results point to redshift evolution to this model, where the effects of starvation (combined with shorter gas-depletion timescales) are more efficient in quenching galaxies at higher redshifts, leading to an environmental quenching efficiency that increases with stellar mass.

SUMMARY
We studied the evolution of the galaxy SMF over 0.2 < z < 2.0 as a function of galaxy activity -quiescent compared to star-forming galaxies -and environment, using density measures derived from a Bayesian-motivated distance to the third-nearest neighbor using data from ZFOURGE and NMBS. Our results extend to lower masses (log M * /M ⊙ > 9.2 [9.5] at z = 1.5 [2.0]) than previously possible. The main results of our study can be summarized as follows.
For star-forming galaxies, there is no evidence the galaxy SMF depends strongly on environment over the redshift range 0.2 < z < 2.0 for the stellar mass range of galaxies in our study. The exception is that there is some evidence for an excess number density of massive (log M * /M ⊙ ≃ 10.5) star-forming galaxies in higher density regions. This may indicate the propensity of more massive star-forming galaxies to be found in richer environments as has been reported in some previous studies.
For quiescent galaxies in the lowest density environments, the shape of the SMF of quiescent galaxies shows no evidence of evolution over the redshift range 0.2 < z < 2.0 to our mass completeness limit, other than an overall increase in number density (φ * ) with time. This means that the massdependence of the non-environmental quenching processes (i.e. mass quenching) does not evolve strongly with redshift, and that arguably mass-quenching is the only mechanism for producing quiescent galaxies of mass log M * /M ⊙ 9 in lowdensity regions out to z < 2.
For quiescent galaxies in the highest density environments, the SMF at z 1.5 is indistinguishable from that in the lowest densities. Differences grow with decreasing redshift, and at z 1 the SMF for quiescent galaxies in the highest density quartile shows higher number densities compared to the SMF in the lowest density quartile, particularly at low masses (log M * /M ⊙ ≃ 9 − 10). Moreover, the evolution in the shape of the quiescent galaxy SMF in the highest density environments (defined by M * and α of the Schechter function) closely tracks that of the total quiescent galaxy SMF. Because the M * and α for the quiescent galaxies in the lowest density environments -where environmental processes are expected to be minimal -shows no apparent evolution, we argue that environmental processes are responsible for the evolution in the shape of the total quiescent galaxy SMF. This evolution in the quiescent galaxy SMF requires that the environmental quenching efficiency that depends on stellar mass, such that the environmental quenching efficiency decreases with decreasing stellar mass for 0.5 < z < 1.5. We show with a simple model that if this were not the case (and the environmental quenching efficiency were constant with stellar mass) then it would overproduce the number of quiescent low-mass galaxies in denser environments.
We conclude that environmental processes that depend on galaxy stellar mass (such as "overconsumption"), where galaxies quench as they become satellites through a combination of rapid gas-consumption and gas-ejection timescales combined with the cessation of gas accretion from the intergalactic medium, dominate environmental quenching in galaxies with log M * /M ⊙ > 9 at redshifts z > 0.5. The fact that the environmental quenching efficiency shows no dependence on stellar mass at z < 0.5 argues that the relative strengths of environmental processes evolve with time, and this is required to account for the observed evolution in the galaxy SMF. A physical explanation for the evolution of the environmental processes is that at fixed stellar mass, satellite SFRs decrease with decreasing redshift (and gas-depletion times increase), making processes such as overconsumption less efficient. At the same time, the dynamical times of satellites in the halos of central galaxies become shorter relative to the Hubble time, which allows more time for environmental quenching processes such as ram-pressure stripping to act.
One prediction from this work is that at z > 0.5, satellite quenching times should remain short, but should scale with the stellar mass of the satellite and halo mass of the central. Indeed there is some evidence for this (Balogh et al. 2016). Future studies using large-area homogeneous datasets probing environments from rich clusters to the field, combined with the analysis of N-body simulations will enable a detailed study of how the satellite quenching times depend on these masses and how they evolve with redshift, which will help address the physics of the environmental quenching mechanism.
The authors thank all their past and current collaborators on the ZFOURGE survey, whose efforts made this work possible. The authors are grateful to Russell Ryan for sharing his MCMC code in advance of publication. The authors also acknowledge fruitful discussions and conversations with colleagues, especially Avishai Dekel, Sandra Faber, Steven Finkelstein, and Yicheng Guo. The authors also thank the anonymous referee and editor, whose comments and suggestions improved the quality and clarity of this work. This work is supported by the National Science Foundation through grants AST 1410728, 1413317, and 1614668. KG acknowledges support for ARC Discovery Projects DP130101460 and DP130101667. This paper includes data gathered with the 6.5 meter Magellan Telescopes located at Las Campanas Observatory, Chile. Australian access to the Magellan Telescopes was supported through the National Collaborative Research Infrastructure Strategy of the Australian Federal Government. We acknowledge generous support from the George P. and Cynthia Woods Institute for Fundamental Physics and Astronomy at Texas A&M University. This research has made use of NASA's Astrophysics Data System. Software: Interactive Data Language (IDL) v8.6, R (R Development Core Team 2008) Figure 7. Relative evolution of the SMF for star-forming galaxies as a function of environment (similar to Figure 2 above). The left panel shows the ratio of the SMF in the highest density quartile (D4) in each redshift bin to the SMF of star-forming galaxies in the highest density quartile at 0.2 < z < 0.5 (the constant C acts to normalize each SMF to the same number density at log M * /M⊙=10.6). The right panel shows the same in the lowest density quartile (D1) The gray-shaded points and lines show data below the stellar mass completeness limit. There is no evidence that the shape of the SMF evolves for quiescent galaxies in the lowest-density quartile, except possibly at the lowest masses and highest redshifts where we observe an excess in the highest density quartiles (and a corresponding deficit in the lowest density quartiles).

APPENDIX A. EVOLUTION OF THE SMF OF STAR-FORMING GALAXIES AS A FUNCTION OF ENVIRONMENT
The emphasis of this Paper is on the differential evolution of the SMF of quiescent galaxies between low-density and highdensity environments. For completeness, we also discuss here the differential evolution of the SMF of star-forming galaxies as a function of environment. Figure 1 shows the SMFs for star-forming galaxies in the highest (D4) and lowest (D1) quartiles. Figures 2 and 4 above showed that the change in the shape of the quiescent galaxy SMF results from evolution in the highdensity environments. Here we show similar plots for star-forming galaxies. Figure 7 shows the ratio of the SMF for star-forming galaxies in the highest-density quartile and lowest-density quartile from ZFOURGE at higher redshift compared to SMF for starforming galaxies at redshift 0.2 < z < 0.5 from NMBS. There is no indication for evolution, with some evidence of an excess of low-mass galaxies at high galaxy overdensity at high redshifts, and a deficit of low-mass galaxies at low galaxy overdensity. These occur below the nominal stellar mass completeness, so we do not attempt to interpret them in great detail. However, if this is real, then it would suggest that lower-mass star-forming galaxies are preferentially found in regions of higher overdensity, but only at the highest redshifts (z ≫ 1).
To quantify the differences in the SMF of star-forming galaxies, we have applied the non-parametric KS and MWW statistical tests to the distribution of galaxy stellar masses in the different subsamples, similar to the analysis of quiescent galaxies in § 4. Table 1 presents the results (p-values) of these tests comparing the different stellar-mass distributions.
We compared the unbinned stellar-mass distributions of star-forming galaxies in the highest environmental density quartile (D4) at 0.5 < z < 1.0 to the stellar mass distributions of quiescent galaxies in D4 at higher redshift. Comparing the stellar-mass distribution of the 0.5 < z < 1.0 galaxies to that at 1.0 < z < 1.5, the KS test gives p = 0.074 and the MWW test gives p = 0.27. This could indicate very weak evidence that the distributions are drawn from different parent distributions, which may indicate weak evolution (and consistent with evolution in the shape of the total SMF reported for star-forming galaxies, see, Tomczak et al. 2014). However, comparing the stellar-mass distribution of the 0.5 < z < 1.0 star-forming galaxies to those at 1.5 < z < 2.0, the KS test and MWW test show no evidence they are drawn from different parent populations, with p-values of 0.23 and 0.82, respectively. (Comparing the 1.0 < z < 1.5 with the 1.5 < z < 2.0 populations shows no evidence for differences either).
Similarly, the stellar-mass distributions of star-forming galaxies in the lowest environmental density quartile (D1) show no convincing evidence they change with redshift. Comparing the stellar-mass distribution of the 0.5 < z < 1.0 galaxies to that at 1.0 < z < 1.5, the KS test gives p = 0.027 and the MWW test gives p = 0.30. Comparing the stellar-mass distribution of the 0.5 < z < 1.0 galaxies to that 1.5 < z < 2.0, the KS test gives p = 0.12 and the MWW test gives p = 0.74 (with no additional insight by comparing the 1.0 < z < 1.5 galaxies to those at 1.5 < z < 2.0). Again, there is no strong evidence that the distribution Figure 8. Evolution of the SMF model parameters for star-forming galaxies as a function of redshift and galaxy density (similar to Figure 4 above for quiescent galaxies). The panels show the evolution with redshift for the characteristic stellar mass (M * ), the low-mass slope (α), and the normalization (φ * ) from the fits to SMF of star-forming galaxies in NMBS and the ZFOURGE survey. The symbols correspond to the same SMFs in each panel, as labeled. For comparison, the small open, black squares show the evolution of model parameters for the total SMF of star-forming galaxies measured by Tomczak et al. (2014). There is no indication that the values of the characteristic mass, M * , or low-mass slope, α for the low-density environments, evolve with redshift or environment. of stellar mass is evolving strongly (with the possible exception for evolution at z < 1.0 in both the D1 and D4 populations, but the evidence is weak).
As with the quiescent galaxy SMF, we also fit Schechter functions to the star-forming galaxy SMFs at each redshift and overdensity. Figure 8 shows the evolution of the values of the characteristic mass, M * , low-mass slope, α, and normalization, φ * , for the star-forming SMFs as a function of redshift and overdensity. In contrast to quiescent galaxies (cf. Figure 4), there is no evidence of evolution in the shape of the SMF of star-forming galaxies over the stellar-mass range and redshift range studied here: the values of M * or α are consistent across redshift and overdensity for the SMF of star-forming galaxies.