The XXL Survey

Exploiting a sample of galaxies drawn from the XXL-North multiwavelength survey, we present an analysis of the stellar population properties of galaxies at 0 . 1 ≤ z ≤ 0 . 5, by studying galaxy fractions and the star formation rate (SFR)–stellar mass ( M (cid:63) ) relation. Furthermore, we exploit and compare two parametrisations of environment. When adopting a deﬁnition of “global” environment, we consider separately cluster virial ( r ≤ 1 r 200 ) and outer (1 r 200 < r ≤ 3 r 200 ) members and ﬁeld galaxies. We also distinguish between galaxies that belong or do not belong to superclusters, but never ﬁnd systematic di ﬀ erences between the two subgroups. When considering the “local” environment, we take into account the projected number density of galaxies in a ﬁxed aperture of 1Mpc in the sky. We ﬁnd that regardless of the environmental deﬁnition adopted, the fraction of blue or star-forming galaxies is the highest in the ﬁeld or least dense regions and the lowest in the virial regions of clusters or highest densities. Furthermore, the fraction of star-forming galaxies is higher than the fraction of blue galaxies, regardless of the environment. This result is particularly evident in the virial cluster regions, most likely reﬂecting the di ﬀ erent star formation histories of galaxies in di ﬀ erent environments. Also the overall SFR– M (cid:63) relation does not seem to depend on the parametrisation adopted. Nonetheless, the two deﬁnitions of environment lead to di ﬀ erent results as far as the fraction of galaxies in transition between the star-forming main sequence and the quenched regime is concerned. In fact, using the local environment the fraction of galaxies below the main sequence is similar at low and high densities, whereas in clusters (and especially within the virial radii) a population with reduced SFR with respect to the ﬁeld is observed. Our results show that the two parametrisations adopted to describe the environment have di ﬀ erent physical meanings, i.e. are intrinsically related to di ﬀ erent physical processes acting on galaxy populations and are able to probe di ﬀ erent physical scales.


Introduction
Observational studies aiming at understanding the processes that affect galaxy properties and determining the evolution of galaxies have been focussing more and more on the role played by both the environment in which a galaxy was formed and that in which it is embedded for most of its lifetime (Oemler 1974;Dressler 1980;Balogh et al. 2004b;Kauffmann et al. 2004;Baldry et al. 2006;Poggianti et al. 2009).In particular, galaxies that are gathered together and/or hosted in the potential well of dark matter haloes, together with those accreted from the cosmic web into bigger structures, undergo a variety of physical processes that may influence the timescale of star formation and stellar mass assembly.These processes are usually connected to the interaction between galaxies and the hot gas permeating the dark matter haloes of groups and clusters, or to galaxy-galaxy interactions (e.g., Boselli &Gavazzi 2006, 2014, andreferences therein).
One of the biggest challenges in observational studies aiming at describing the interplay between galaxies and their environment is the definition of the environment itself (Haas et al. 2012;Muldrew et al. 2012;Etherington & Thomas 2015).Its parametrisation is commonly performed following two different strategies, which are able to probe different physical scales and have intrinsically different physical meanings.The first approach is based on the potential well of dark matter haloes, and thus relies on physical properties of the cosmic structures such as the virial masses and radii, X-ray luminosity, and dynamical masses.
According to this definition, which is commonly referred to as "global" environment, going from the largest scale (i.e. the most massive haloes) in the cosmic web down to the scales of single galaxies we can define superclusters, clusters, groups, filaments, field, and voids.
The second description of environment is based on the computation of the projected over-density of galaxies and is referred to as "local" environment.Several methods have been explored for computing the local (projected) density of neighbouring galaxies, either based on computing the area enclosing the Nth neighbour with respect to a central one or counting the number of galaxies enclosed within a fixed aperture.It has been shown that the latter methodology is closer to the real over-density measured in 3D space, more sensitive to high over-densities, less biased by the viewing angle, and more robust across cosmic times than the former (Shattow et al. 2013).For this reasons, we adopt this method to quantify the local environment.
Whatever the definition of environment, its strong connection with the observed properties of galaxies has been extensively demonstrated, both in terms of the average stellar age (e.g.Thomas et al. 2005;Smith et al. 2006) and the last episode of star formation (and thus a lower fraction are continuing to form stars; e.g.Lewis et al. 2002;Baldry et al. 2004;Balogh et al. 2004a,b;Kauffmann et al. 2004).
Focussing on the intermediate redshift regime (0.25 ≤ z ≤ 1.2), colour fractions have been found to depend strongly on the global environment; the incidence of blue galaxies is system-atically higher in the field than in groups (Iovino et al. 2010) and clusters (Muzzin et al. 2012) and decreases with increasing absolute magnitude.Similarly, also the mean star formation rate (SFR), specific-SFR (sSFR) and star-forming fraction are always higher in field galaxies than in clusters, decrease from the outskirts to the cluster central region (Treu et al. 2003;Poggianti et al. 2006;Raichoor & Andreon 2014;Haines et al. 2015) and depend on stellar mass in a given environment (Muzzin et al. 2012).Similar results have been found both in the local Universe (e.g.Balogh et al. 2004b) and at higher redshifts.Linking the star formation activity of galaxies with their cold molecular gas reservoir, Noble et al. (2017) discovered a population of massive cluster galaxies having higher gas fractions compared to the field, indicating a stronger evolution of massive haloes at high redshifts; a depletion of the cold gas reservoir emerges instead in a sample of z∼0.4 cluster galaxies in Jablonka et al. (2013) with respect to field galaxies of the same stellar mass, with further decreasing trends towards the centre of the structures.
Considering instead the local density (LD) parametrisation, the colour and star-forming fractions have also found to be lower in denser environments, both in the local Universe (e.g, Balogh et al. 2004a;Baldry et al. 2006) and at intermediate redshifts (e.g., Cooper et al. 2008;Cucciati et al. 2006Cucciati et al. , 2010Cucciati et al. , 2017)).However, Darvish et al. (2016) found that in the star-forming population the median SFR and sSFR are similar at different values of the local density, regardless of redshift and galaxy stellar mass up to z∼3, and Elbaz et al. (2007) even advocated the increase of the SFR of galaxies at z∼1 in denser environments.
The effect of global or local environment on galaxy properties has also been investigated in terms of the relation between the SFR and galaxy stellar mass.The existence of a tight relation of direct proportionality between SFR and galaxy stellar mass (SFR-M ) and sSFR-M has been established from z=0 out to z>2, with a roughly constant scatter of ∼0.3 dex out to z∼1 (Brinchmann et al. 2004;Daddi et al. 2007;Noeske et al. 2007;Salim et al. 2007;Rodighiero et al. 2011;Whitaker et al. 2012;Sobral et al. 2014;Speagle et al. 2014).Star-forming galaxies lie on the so-called main sequence, whereas the quenched population occupy a locus with little or non-detectable SFR.
The representation of the SFR-M plane is necessary to understand the characteristics of the star-forming population of galaxies in different environments and to analyse whether the process leading to the shutting down of the star formation activity in a galaxy (and thus its transformation into a passive galaxy) proceeds similarly in different environments and whether the definition of the environment itself plays a role.In fact, fast quenching processes would leave the cluster/high-density regions SFR-M relation unperturbed with respect to the field/lowdensity regions, leaving the median SFR in agreement at all stellar masses.In contrast, slow quenching mechanisms would increase the number of galaxies with reduced SFRs shifting the overall distribution of SFRs towards lower values than those of main sequence galaxies of similar mass.
When inspecting the SFR-M relation in different global environments, a population of low star-forming galaxies in a transition stage between the main sequence and the quenched population (hereafter "transition" galaxies) has been observed in clusters at all redshfits up to z<0.8 (Patel et al. 2009;Vulcani et al. 2010;Paccagnella et al. 2016).This population is missing in the field.In particular, Paccagnella et al. (2016) found that at 0.04< z <0.07 galaxies in transition are preferentially found within the virial radius (R 200 ), and their incidence increases at distances < 0.6R 200 .These galaxies are older and present redder colours than galaxies in the main sequence and show re-duced mean SFRs over the last 2-5 Gyr, regardless of their stellar mass.Moreover, using spatially resolved observations from SDSS-IV MaNGA, Belfiore et al. (2017) associated the transition population with a population of galaxies having central low ionisation emission-line regions, resulting from photoionisation by hot evolved stars, and star-forming outskirts.These galaxies are preferentially located in denser environments such as galaxy groups and are undergoing an inside-out quenching process.
On the contrary, studies on galaxy samples based on a local parametrisation of environment do not find differences in the SFR-M of galaxies at different densities (Peng et al. 2010;Wijesinghe et al. 2012, but see Popesso et al. 2011 at high z).
It is important to stress however that different results in the literature obtained by adopting different parametrisations of the environment are hard to compare, either because of the different selection criteria on the samples or custom definitions used to define, for example, the local galaxy over-density.
The aim of this work is to study the star formation properties and colours of galaxies adopting different definitions of environment, to acquire a general understanding of the phenomena that characterise and influence the observed properties of galaxies at different epochs and in different conditions.The main questions we want to address are: 1) How do the star-forming and blue fractions depend on environment?2) Are there differences in the star-forming population in different environments?Namely, are star-forming galaxies in clusters or dense environments as starforming as galaxies in the field or lower density environments?3) How does the definition of the environment itself affects these tracers?
We characterise galaxies in three redshift bins from z=0.1 up to z=0.5, in X-ray massive groups and clusters (1.13 × 10 13 ≤ M 200 /M1 ≤ 9.28 × 10 14 , hereafter simply clusters) observed in the XXL Survey.This survey (Pierre et al. 2016, hereafter XXL Paper I), is an extension of the XMM-LSS 11 deg 2 survey (Pierre et al. 2004), consisting of 622 XMM pointings covering two extragalactic regions of ∼ 25 deg 2 each, one equatorial (XXL-N) and one in the southern hemisphere (XXL-S).The survey reaches a sensitivity of ∼ 6 × 10 −15 erg s −1 cm −2 in the [0.keV band for point sources.
This study is focussed on computing the fraction of starforming and blue galaxies and the SFR-M relation, in the field versus clusters, also distinguishing between structures belonging or not to superclusters, and as a function of LD.The paper is organised as follows: in Section 2 we present the catalogues of clusters and galaxies, the tools used to compute galaxy stellar population properties and the computation of the spectroscopic incompleteness weights; in Section 3 we characterise different galaxy populations on the basis of their SFR and colours; in Section 4 we explore the dependence of the stellar population properties on global environment, performing a detailed analysis on galaxy fractions (Sect.4.1) and on the SFR-M relation (Sect. 4.2 and 4.3); in Section 5 we analyse the galaxy population properties as a function of local environment, following the same scheme as Sect.4. In section 6 we discuss our results obtained with the two parametrisations of environments regarding the galaxies in transitions (Sect.6.1) and the ratio of star-forming to blue fractions (Sect.6.2).Finally, we present our conclusions in Sect.7.

Catalogue of structures
Our environmental study is grounded in X-ray selected clusters from the XXL survey (XXL Paper I).The selection of the cluster candidates starting from X-ray images was presented by Pacaud et al. (2016) (hereafter XXL Paper II).
By means of the Xamin pipeline (Pacaud et al. 2006), each structure is assigned to a specific detection class on the basis of the level of contamination from point sources.Class 1 (C1) clusters are the highest surface brightness extended sources, which have no contamination from point sources; Class 2 (C2) clusters are extended sources that are fainter than those classified as C1 and have a 50% contamination rate before visual inspection.Contaminating sources include saturated point sources, unresolved pairs, and sources strongly masked by CCD gaps, for which not enough photons were available to permit reliable source characterisation.Class 3 (C3) are (optical) clusters associated with an X-ray emission that is too weak to be characterised, and whose selection function is therefore undefined.
The spectroscopic confirmation and redshift assignment of cluster candidates are presented in Adami et al. (2018) (hereafter XXL Paper XX, but see also Guglielmo et al. 2018a, hereafter XXL Paper XXII).The procedure is similar to that already used for the XMM-LSS survey (e.g., Adami et al. 2011), and is based on an iterative semi-automatic process.The final catalogue of spectroscopically confirmed extended sources contains 365 clusters, 207 (∼ 56%) of which are classified as C1, 119 (∼ 32%) as C2 and the remaining 39 (∼ 11%) are C3.For the reasons explained above, C3 clusters are not included in the current work.A larger subsample of objects with respect to the first data release (Giles et al. 2016, XXL Paper III) underwent a direct X-ray spectral measurement of luminosity and temperature, down to a lowest flux of ∼2 ×10 −15 erg s −1 cm −2 in the [0.keV band and within 60 arcsec (235 clusters).
To have homogeneous estimates for the complete sample, and as already performed in Guglielmo et al. (2018a,b) (hereafter XXL Paper XXX), we used the cluster properties derived through scaling relations 2 starting from the X-ray countrates.The method is presented in XXL Paper XX, from which (Table F.1) we extracted the values of the X-ray temperature (T 300kpc,scal ), r 500,scal 3 , M 500,scal 4 .The luminosity in the 0.5-2.0keV range (L XXL 500,scal ) was not published in Paper XX but is available internally to our collaboration.XXL Paper XXII derived the virial mass M 200 from M 500,scal using the recipe given in Balogh et al. (2006), and computed the velocity dispersion (σ 200 ) through the relation given in Poggianti et al. (2006), based on the virial theorem.
In XXL Paper XX, 35 superclusters were identified in both XXL-N and XXL-S fields in the 0.03≤z≤1.0redshift range, by means of a friend-of-friend (FoF) algorithm characterised by a 2 All the cluster quantities derived through scaling relations are therefore named using the suffix "scal". 3r 500,scal is defined as the radius of the sphere inside which the mean density is 500 times the critical density ρ c of the Universe at the cluster redshift. 4M 500,scal derives from r 500,scal and is defined as 4/3π500ρ c r 3 500,scal In this work we focus on clusters observed in the XXL-N region at 0.1≤z≤0.5.The sample is composed of 111 clusters that are fully characterised in terms of X-ray luminosities, temperatures, virial masses, and radii.Of these structures, 68 (∼ 60%) belong to superclusters, thus it is possible to study the impact of the large-scale structure on galaxy properties.To do so, we treat separately galaxies that belong or do not belong to a supercluster, and call these "(S)" and "(NS)", respectively.Taking as a reference the nomenclature adopted in XXL Paper XX, the superclusters considered in this work are reported in Table 1.
Figure 1 shows how M 200 and L XXL 500 vary with redshift within the sample, for clusters within and outside superclusters.As already mentioned in XXL Paper XXII, selection effects emerge: at z > 0.4 the survey detects only the most massive clusters (M 200 ≥ 10 14 M ).Nonetheless, no systematic differences are detected between (S) and (NS) clusters.

Galaxy catalogue
We made use of the galaxy properties included in the spectrophotometric catalogue presented in XXL Paper XXII.As for the catalogue of structures, we focussed on the XXL-N region and on the redshift range 0.1≤z≤0.5.
The photometric and photo-z information in XXL-N were mainly taken from the CFHTLS-T0007 photo-z catalogue in  013,022,024,027,028,070,088,104,140,148,149,150,083,084,085,086,092,093,107,155,172,095,112,118,138,162,176,111,117,161,049,053,143,050,087,091,123,010,023,086,142,144,137,180,043,189,199,067,132 the W1 Field (8 • × 9 • , centred at RA=34.5000 • and DEC=-07.0000• ).The data cover the wavelength range 3500Å< λ < 9400Å in the u * , g , r , i , and z filters.Photometric data for a number of galaxies in the spectroscopic database that did not have any correspondence in the CFHTLS catalogue were taken from Fotopoulou et al. (2016).This catalogue contains aperture magnitudes in the g , r , i , z , J , H , and K bands that have been converted into total magnitudes using a common subsample of galaxies with the CFHTLS-T0007 W1 field catalogue (see XXL Paper XXII).All magnitudes are Sextractor MAG_AUTO magnitudes (Bertin & Arnouts 1996) in the AB system corrected for Milky Way extinction according to Schlegel et al. (1998).The error associated with photo-z in the magnitude range we are probing in this work (r<20.0,see XXL Paper XXII and below) is redshift dependent, and according to the CFHTLS-T0007 data release document, is σ/(1 + z) ∼ 0.031.Spectroscopic redshifts are hosted in the XXL spectroscopic database that is included in the CeSAM (Centre de donnéeS Astrophysiques de Marseille) database in Marseille.5 As described in XXL Paper XXII, the database collects spectra and redshifts coming from different surveys covering the XXL pattern (mainly GAMA, SDSS, VIPERS, VVDS, VUDS, and XXL dedicated spectroscopic campaigns, see Table 2 in XXL Paper XXII), and the final spectroscopic catalogue was obtained by removing duplicates using a careful combination of selection criteria (the socalled priorities) and accounting for the quality of the spectra (i.e. the parent survey) and of the redshift measurement.Overall, the uncertainties on the galaxy redshift in the database vary from 0.00025 to 0.0005, as computed from multiple observations of the same object; we consider the highest value in this range as the typical redshift error for all objects.We note that the spectroscopic catalogue did not undergo any preselection or flag assignment to identify active galactic nuclei (AGN), and thus our sample may be contaminated by the presence of such peculiar sources.We address this point in more detail and quantify the contribution of AGNs later in this paper.
The final galaxy sample is obtained from the crossmatch between the photometric and spectroscopic sample.Figure 2 shows the distribution of galaxies and clusters in the coordinates plane, for the magnitude limited sample that is presented below.

Tools
The stellar population properties of galaxies were derived relying on either their photometric or spectroscopic data.In the first case, we made use of the spectral energy distribution (SED) fitting code LePhare6 (Arnouts et al. 1999;Ilbert et al. 2006) to compute absolute magnitudes, and therefore rest-frame colours, as described in XXL Paper XXII.In the second case, we fit galaxy spectra via SINOPSIS7 (SImulatiNg OPtical Spectra wIth Stellar population models), a spectrophotometric fitting code fully described in Fritz et al. (2007Fritz et al. ( , 2011Fritz et al. ( , 2017) ) and already largely used to derive physical properties of galaxies in many samples (Dressler et al. 2009;Vulcani et al. 2015;Guglielmo et al. 2015;Paccagnella et al. 2016Paccagnella et al. , 2017;;Poggianti et al. 2017).Among the outputs of the model, we considered SFRs and galaxy stellar masses (M * ), defined as the mass locked into stars, both those which are still in the nuclear-burning phase, and remnants such as white dwarfs, neutron stars, and stellar black holes.
While LePhare could be applied to the whole spectrophotometric sample of galaxies (provided that the catalogue contains magnitudes at least in two filters for each objects), SINOPSIS was run on the subsample of galaxies that have either SDSS or GAMA spectra, which are flux calibrated and have the best available spectral quality.As discussed in Fritz et al. (2014), in the lowest resolution spectra of this work, i.e.GAMA spectra, emission lines can be measured down to a limit of 2 Å, while any emission measurement below this threshold is considered unreliable.In terms of sSFR, this sets a lower limit of 10 −12.5 yr −1 .
The final sample is composed of galaxies with reliable outputs coming from both LePhare and SINOPSIS.Fig. 3: Colour-magnitude diagrams in the magnitude limited sample in the three redshift bins analysed, with increasing redshift from left to right as indicated in the labels.Single galaxies are plotted as blue dots, while galaxies in higher density regions are grouped together and plotted as rectangles colour-coded according to their number density as indicated in the colour bar located on the side of each panel.The magenta dotted line shows the separation between red and blue objects using the (g-r) rest− f rame colour.

Samples and spectroscopic completeness
In what follows, we consider galaxies in three redshift bins, 0.1 ≤ z < 0.2, 0.2 ≤ z < 0.3, 0.3 ≤ z ≤ 0.5 and study both magnitude and mass limited samples.As detailed in XXL Paper XXII, magnitude completeness limit was set to an observed magnitude of r = 20.0 at all redshifts, and is converted into a different mass completeness limit at each redshift.To determine this limit, at each redshift we converted the observed magnitude limit into a rest-frame magnitude limit and computed the mass of an ideal object having the faintest magnitude and the reddest colour in that redshift bin.Following XXL Paper XXII, the stel-lar mass limit of each redshift bin is that corresponding to the lowest limit of each interval; i.e. at 0.1≤z<0.2 is the stellar mass limit corresponding to z=0.1.We therefore adopted the following values: The galaxy magnitude complete sample includes 18399 galaxies, the mass complete sample includes 13857 galaxies.Table 2 reports the number of galaxies in the different redshift bins Table 2: Number of galaxies above the magnitude and mass completeness limits in three redshift bins.The quantities in parentheses refer to the number of galaxies weighted for spectroscopic completeness.Values of M lim are given in the main text.3 5438 (11601)  7490 (7803)  0.3 ≤ z ≤ 0.5  4777 (7902)  3352 (5593)  all  18399 (30929) 13857 (21303) for both samples.Both raw numbers and those corrected for incompleteness are given.The method used to compute the spectroscopic completeness is described in Appendix A. Briefly, as the spectroscopic sample spans a relatively wide redshift range, we sliced the sample into different redshift bins and quantified the number of galaxies that fall/are expected to fall into that given redshift bin, based on both spectroscopic and photometric redshifts.As already performed in XXL Paper XXII, we accounted for the change in the spectroscopic sampling of different surveys by dividing the sky into 22 cells (shown in Fig. 2), and in intervals of 0.5 r-band magnitude within each cell.The completeness curves resulting from this computation were converted into completeness weights which are attributed to each galaxy given its redshift, astrometry, and magnitude.

Galaxy subpopulations
In our analysis we characterised separately the star-forming properties and rest-frame colours of galaxies in different environments and at different redshifts.We therefore need to define two different criteria to separate star-forming/blue galaxies from passive/red galaxies.First, we considered as "star forming" those galaxies with sSFR = SFR/M > 10 −12 yr −1 and "passive" the remaining galaxies.We point out that this sSFR threshold is the same in the three redshift bins considered, which is justified by the scarce evolution in the sSFR-stellar mass plane in this redshift range (see e.g.Whitaker et al. 2012).
Then, we considered as "blue" galaxies those whose restframe colour is bluer than a certain threshold, and "red" the rest.To identify such threshold in colour, we investigated the relation between the (g − r) rest−frame colour and absolute magnitude M r , in the three redshift bins separately.Figure 3 shows the restframe colour-magnitude diagram (CMD) in each redshift bin.To define the slope of the colour-magnitude cut, we focussed on the lowest redshift bin, which has a sufficiently wide magnitude range.We considered five 0.6 absolute magnitude bins and plot the (g − r) rest−frame histogram of each subpopulation (Fig. 4).We then fit the histogram with a double-Gaussian curve and determined the minimum of the distribution between the two peaks.We computed the line interpolating the (g−r) rest−frame colours just found in the five magnitude bins and used it to divide the galaxy population as shown in Fig. 3 (magenta dashed line).At higher redshift, the magnitude range is too small to apply the same procedure.As no significant evolution is expected in the slope of the relation, but only in the zero point, we fixed the slope to that of the lowest z bin and computed the appropriate zero points with the same method outlined above (Fig. 5): we considered one magnitude bin at each redshift, we drew the (g − r) rest−frame colour histogram and fit the distribution with a double-Gaussian curve, finding the local minimum between the two peaks.To conclude, at 0.1≤z<0.2galaxies were assigned to the blue sequence if their colour obeys (g − r) rest− f rame < −0.019M r + 0.192, at 0.2≤z<0.3 the zero point is 0.177 and 0.176 at 0.3≤z≤0.5.
As a comparison between the two criteria just described we note that, considering all the redshift bins together, blue galaxies have a median sSFR∼ 10 −9.7 yr −1 (and 90% of galaxies have sSFR 10 −10.45 yr −1 ).Conversely, star-forming galaxies have a median (g − r) rest− f rame ∼ 0.58 (and 90% of galaxies have (g − r) rest− f rame < 0.725).
It is important to bear in mind that the two tracers used to characterise the galaxy populations have a different physical meaning and refer to different timescales.While the SFR is an instantaneous measure of the rate at which a galaxy is forming stars at the epoch it is observed, colours are the result of longer processes tracing the predominant stellar population of a galaxy, whose colour is sensitive to its past history and to its current star formation activity.Moreover, colour is also influenced by other characteristics, such as the metallicity and the presence of dust.In addition, the methodologies adopted to compute SFR and colours are different.The ongoing SFR is a product of the full spectral fitting analysis performed on the spectra, while restframe colours are derived by means of SED fitting on the photometry.Therefore, it is important to investigate the two quantities separately and study the incidence of each population over the total, as we do in the next sections.

Results I: Galaxy population properties as a function of the global environment
In this section, we study the fractions and star-forming properties of galaxies in different global environments.We consider galaxies in the following environments.
-Cluster virial members are galaxies whose spectroscopic redshift lies within 3σ from the mean redshift of their host cluster, where σ is the velocity dispersion of their cluster and whose projected distance from the cluster centre is < 1 r 200 .-Cluster outer members are galaxies whose spectroscopic redshift lies within 3σ from the mean redshift of their host cluster, and whose projected distance from the cluster centre is between 1 and 3 r 200 .-Galaxies in the field are all galaxies that do not belong to any cluster.
We note that all galaxies belonging to a structure are always included in the same redshift bin.For example, if a cluster is located at the edge of a redshift bin and its members spill over another bin, these are all included in the redshift bin of their host cluster, regardless of their actual redshift.
We also treat separately virial and outer members that belong or do not belong to a supercluster.Table 3 reports the number of galaxies in the different environments and redshift bins.For all of these subsamples, numbers are given for the magnitude limited and mass limited samples.At 0.1 ≤ z < 0.2 our sample includes three superclusters, at 0.2 ≤ z < 0.3 three superclusters, and at 0.3 ≤ z ≤ 0.5 six superclusters.

Fraction of blue and star-forming galaxies
Figure 6 shows the fraction of blue and star-forming galaxies, separately, in the different global environments and in the three redshift bins, both for the magnitude limited and mass limited samples.Error bars are computed using a bootstrap method.For galaxies in the field, we include in the error budget both the bootstrap error and the uncertainty due to the cosmic variance.Following Marchesini et al. (2009), we sliced our field into nine right ascension subregions and we computed the fraction of starforming and blue galaxies of each region separately; the contribution to the error budget from cosmic variance is then the standard deviation of the newly computed fractions divided by the number of subregions considered.
Overall, at all redshifts, both considering the star formation and colours as tracers, fractions are similar within and outside the superclusters, suggesting that neither additional quenching processes nor triggering of the star formation are associated with the presence of superclusters.
At 0.1≤z<0.2(top left), both in the magnitude and in the mass limited samples, the star-forming fraction strongly depends on environment.Virial members have the lowest fraction of starforming galaxies (55-60%).This fraction increases when considering outer members, where ∼ 80% of galaxies are star forming.Finally, the percentage of star-forming galaxies in the field is the highest (86±1%).The same trends are recovered when considering galaxy colours, even though fractions are systematically lower: ∼ 16% of virial members are blue, as are ∼ 40% of outer members and 57% of field galaxies.Similarly to the star-forming fractions, results in the magnitude and mass limited samples are similar, except for the field value, where they differ by ∼ 10%; the mass limited sample shows a lower fraction than the magnitude-limited sample.
At 0.2≤z<0.3(middle panels of Fig. 6), in both samples, virial members still show a significantly lower fraction of starforming galaxies than the other environments (∼ 55 − 60%), while outer members and field galaxies present very similar fractions (∼ 85%/75% in the magnitude/mass limited samples).Considering colour fractions, the same trends are detected in the magnitude limited sample, where blue galaxies are ∼ 17% in virial members, ∼42% in outer members and in the field.In the mass limited samples, the difference between outer members and the field is much smaller: the fraction of blue galaxies in these environments is always < 20%.
We recall that this redshift bin contains the XLSSsC N01 supercluster, separately discussed in XXL Paper XXX, and that contributes to the (S) cluster population with 11 out of 20 clusters, corresponding to ∼ 65% of the cluster population.In that supercluster an enhancement of the star formation activity of outer members with respect to the virial population and the field was observed.Nonetheless, general trends are maintained within the errors.
At 0.3≤z≤0.5 (bottom panels of Fig. 6), both in the mass and magnitude limited samples, virial members have the lowest star-forming fraction (45-50%), but differences with the other environments are reduced: in outer members and in the field the star-forming fractions are ∼ 65% in the magnitude limited Table 3: Number of galaxies in the different environments (clusters in superclusters (S), clusters not in superclusters (NS), and field) and above the magnitude and mass completeness limits, in three redshift bins.Galaxies in clusters are further subdivided into virial and outer members.The quantities in parentheses refer to the number of galaxies weighted for spectroscopic completeness.8577) 6911 ( 10808) 4615 ( 7181) 4502 ( 7405) 3125 ( 5180) 16558 ( 28006) 12251 ( 20938) sample and ∼ 55 − 60% in the mass limited sample.Considering colours, in the magnitude limited sample we still detect the usual differences between virial members and galaxies in other environments, while in the mass limited sample all fractions are lower than 15% and no variation with environment is detected.
As our cluster sample spans a wide range of X-ray luminosity (see Fig. 1), we repeat the analysis separating the clusters in bins of X-ray luminosity, but find no significant additional trends (plot not shown).
To summarise, at all redshifts, field galaxies have the highest incidence of star-forming/blue galaxies, while virial members exhibit a noticeable suppression of both star-forming and blue fractions with respect to the other environments.Outer members exhibit a significant suppression of the star-forming/blue fractions with respect to the field only at 0.1≤ z <0.2, while at higher redshift they present similar fractions.No significant differences are detected between galaxies within and outside superclusters.However, fractional differences within and outside of superclusters do not follow a common trend at all redshifts, likely reflecting the variation of properties of individual supercluster structures at different redshifts.The choice of a mass or magnitude limited sample only marginally affects the starforming fractions, while it strongly alters those based on colours at z > 0.2.
Overall, star-forming and blue fractions are never consistent within the errors: this is a probe that the two quantities, even though strictly related, are actually reflecting different aspects of the evolution of the galaxies.We note that in our sample no reasonable and physically motivated cut could be adopted to reconcile the fractions of star-forming and blue galaxies.
In principle, the difference in the star-forming and blue fractions could be due to the presence of AGNs; for example, lowionisation nuclear emission-line regions (LINERS) identified as red star-forming galaxies.These AGNs would increase the number of galaxies pertaining to the star-forming population without enhancing the fraction of blue galaxies.To test this, we removed broad-and narrow-line AGNs from our galaxy sample, as described in detail in Appendix B, and we computed again the star-forming/blue fractions.The fractions are substantially unchanged (plot not shown), indicating that our results are not driven by the possible presence of AGNs.
We stress that comparisons across the different redshift bins are not possible, as magnitude and mass values used to define the sample are different.Furthermore, we point out that the decrease of the blue/star-forming fraction with increasing redshift is simply an artefact due to the galaxy mass range probed at different redshifts.

SFR-mass relation
We focus in this section only on the star-forming population and investigate the correlation between the SFR and galaxy stellar mass (SFR-M ).For this analysis we only rely on the mass limited sample.Indeed, in contrast with the magnitude limited sample, applying a mass limit ensures completeness, i.e. to include all galaxies more massive than the limit regardless of their colour or morphological type.This ensures that we do not bias the results because of the absence of galaxies which are undersampled or missed by selection effects, as might happen when considering a magnitude limited sample.As in the previous section we did not detect any significant difference between galaxies within and outside superclusters, in what follows we do not distinguish between the two subgroups.
Figure 7 compares the distribution of galaxies in different environments and in different redshift bins in the SFR-M plane (left and middle panels).Roughly, at all redshifts, galaxies located in the different environments share a common region on the plane, excluding strong environmental effects at play.Comparing the galaxies at different redshifts, we find a decline in SFR with time at fixed stellar mass, in agreement with many previous literature results (e.g.Noeske et al. 2007;Vulcani et al. 2010).
To probe the apparent lack of environmental effects on a statistical ground, we proceed by first performing a linear regression fit to the relation by considering all the different environments together and then compare the median values of SFR in different mass bins for the various environments to this fit.The values of the best-fit slope, intercept and 1σ are given in Table 5. Error bars on the medians are computed in each stellar mass bin as 1.253σ/ √ n, where σ is the standard deviation of the SFR distribution in the bin and n is the number of objects considered in the bin.
The fit to the SFR-M relation is dominated by field galaxies, whose median trends closely follow the fitting line at all redshifts.In contrast, cluster virial members show hints of lower median SFR with respect to the latter in all the redshift bins; some statistical oscillations are due to the lower number of galaxies at 0.3≤z≤0.5.Furthermore, in this case the limited mass range could also affect the reliability of the fit.The median SFR of outer members closely follows the field trend at z≤0.2 and is compatible within the error bars with both the field and virial members at higher redshift.We do not plot these values for the sake of clarity.
The right-hand panels of Fig. 7 report the distribution of the differences between the SFR of each galaxy and the value derived from the global fit given the galaxy mass (∆SFR), for any given environment.Positive values of ∆SFR correspond to re-Fig.6: Fraction of star-forming (left) and blue (right) galaxies in different environments and different redshifts, as indicated in the panels.Cluster members are divided into four subsamples: virial and outer members that belong or do not belong to a supercluster.Values obtained using the magnitude limited sample are represented with filled symbols and solid errors, those obtained using the mass limited sample are represented by empty symbols and dashed error bars.A horizontal shift is applied for the sake of clarity.Errors are derived by means of a bootstrap method.
duced SFR with respect to the expected value.At all redshifts, it is immediately clear that the shape of distribution of ∆SFR of virial members differs from that of the field population, whereby the former presents a tail of reduced SFR values with respect to the latter.A Kolmogorov-Smirnov (KS) test is able to de-tect differences between virial members and field galaxies at all redshifts (P(KS) ≤ 0.05); outer members instead have statistically different distributions with respect to the field only at 0.3≤z≤0.5 (P(KS)<0.02),and with respect to virial members only at 0.1≤z<0.2(P(KS)<10 −3 ).Nonetheless, at all redshifts, Fig. 7: Left and middle panels.SFR-M relation for galaxies in the field and cluster virial and outer members (grey 2D histogram and density contours, orange diamonds, and black stars, respectively) in the mass limited sample.Panels in different lines refer to different redshift bins.The field population is represented with a 2D histogram whose values are given in the colour bar included in the middle panel, and grey contours trace the density levels of the data points.The vertical red dashed line shows the stellar mass limit at each redshift, while the oblique red dashed line sets the limit to the star-forming population, i.e. sS FR = 10 −12 yr −1 .The blue line is the linear fit to the SFR-M relation including all the environments at each redshift, and the dashed blue lines correspond to 1σ errors on the fitting line.The parameters of the fit and the values of σ are given in Table 5.The gold diamonds/stars and cyan dots represent the median SFR values computed in mass bins of 0.2 dex width, for the virial/outer members and field population, respectively.Error bars on the medians are computed assuming a normal distribution of the data points as 1.253σ/ √ n, where σ is the standard deviation of the distribution and n is the number of objects in the considered stellar mass bin.Right panels.Histograms of the differences between the expected SFR computed using the main sequence fitting line at the stellar mass of any given galaxy in our sample and its actual SFR (∆SFR).Positive values of ∆SFR indicate reduced SFR compared to the SFR main sequence of star-forming galaxies.The median values of the distributions are also shown with vertical dashed lines and different environments are colour coded as written in the legend.median values are compatible within the errors among the different samples, indicating that the tail, although present in virial and outer members, is not able to affect the whole SFR distribution significantly.

Galaxies in transition
The presence of a non-negligible number of galaxies with reduced SFR among the cluster population motivates a more detailed investigation on the presence of the so-called galaxies in transition, i.e. star-forming galaxies which are slowly decreasing their SFR and are detected as an intermediate population migrating from the star-forming main sequence down to Table 4: Fraction of galaxies in transition in different environments in the three redshift bins.Numbers are weighted for spectroscopic incompleteness and are computed above the stellar mass completeness limit of each redshift bin; the values in parenthesis refer to the highest stellar mass limit to allow comparisons at different redshifts.Errors are computed by means of bootstrapping.The last two lines of the table correspond to the values computed in two bins of LD and are analysed in Sect. 5.  the quenched population.To identify the galaxies in transition we follow Paccagnella et al. (2016), and select galaxies with (sSFR) > 10 −12 yr −1 and SFR below 1σ from the SFR-M fitting line.The transition fraction is computed as the ratio of this population to the number of star-forming galaxies in each environment.We note that, by definition, the percentage of galaxies below a 1σ cut of the SFR-M relation should be ∼15-17%, therefore the identification of a population of galaxies in transition is measured as an excess of galaxies compared to this statistical value.
The fractions of galaxies in transition as a function of environment for different redshift bins are presented in Fig. 8 and given in Table 4.We compute these fractions also dividing virial/outer cluster members residing or not in superclusters.
The incidence of the population of galaxies in transition depends on environment.As shown in Fig. 8, the fraction of transition galaxies in the field and outer members is (within the errors) almost half of that observed in cluster virial members at z≤0.3.At higher redshift instead, the fractions are similar within the error bars in all environments, likely owing to the high stellar mass limit considered.
Considering separately clusters within and outside superclusters, no clear trends are observed in the transition fractions, suggesting again that differences among superclusters are most likely statistical.In this context, we note that at 0.2≤z<0.3 the fraction of galaxies in transition in the virial and outer regions of (S) clusters is in agreement with the trends found for the XLSSsC N01 supercluster (XXL Paper XXX).The transition fractions are ∼ 10% lower in both (S) virial and outer members compared to their (NS) counterparts, as in the XLSSsC N01 supercluster where the percentage of galaxies with reduced SFR was <20% in all the environments.
We also tested whether the X-ray luminosity played a role in the determination of the number of galaxies in transition in clus-ters, and we did not find any clear correlation in the luminosity range probed by our cluster sample.
As a general understanding, environmental effects seem to dominate within the cluster virial radii: the substantial difference in the number of galaxies with reduced SFR among cluster virial members compared to the field population is responsible for detection of tails in the ∆SFR distributions, shown in the right panels of Fig. 7.

Results II: Galaxy population properties as a function of the local environment
The availability of a large spectrophotometric sample of galaxies enables the parametrisation of environment also in terms of projected LD of galaxies.In this section we consider together the galaxies in all the aforementioned environments and divide these sources into the usual three redshift bins.For each galaxy, we compute the projected LD as the number of galaxies enclosed into a fixed radial aperture of 1 Mpc at the redshift of the galaxy and within a given redshift range around the centre galaxy.We describe the computation of LD in detail in Appendix C. Figure 9 shows the LD distribution in the three redshift bins in logarithmic units, along with the 15th, 50th, and 85th percentiles, which will be used to define the LD bins used in Sect.5.2.It is evident that going from low-to high-z the peak (i.e. the median) of the LD is shifted towards higher densities, as previously found in other samples (Poggianti et al. 2010).

Fraction of blue and star-forming galaxies
Figure 10 shows the fraction of blue (right) and star-forming (left) galaxies as a function of the projected LD, in the three redshift bins, separately, for both the magnitude and mass limited samples.Error are derived by means of bootstrapping.At 0.1 ≤ z < 0.2 (top panels), both in the magnitude and in the mass limited samples, the fraction of both star-forming and blue galaxies decreases monotonically with increasing LD.The starforming fraction is close to 90% at low densities and then decreases of a factor 1.5 in a LD range of 2.0 dex; the blue fraction is ∼ 80% at low densities and decreases of almost four times; the values drop to ∼0.2 at the highest densities.
At 0.2 ≤ z < 0.3 (middle panels of Fig. 10), the star-forming fractions are much less dependent on density, both in the mass and magnitude limited samples.Values range between 80 and 60%, at low and high density, respectively.In contrast, in the  magnitude limited sample, the blue fraction still shows a significant decrease with LD, ranging from 50% at low densities to 20% at the highest.In the mass limited sample the blue fraction is always 20%, regardless of density.
In the highest redshift bin (bottom panels of Fig. 10), both in the magnitude and mass limited samples the star-forming fractions seem first to increase with density, reach a plateau and then decrease at the highest values.Overall, values range between 50 and 70% in the magnitude limited sample, 40% to 60% in the mass limited sample.Such increase with LD is also noticeable in the colour fractions: in the magnitude limited sample at low density the fraction is ∼ 25%, reaches 40% at intermediate densities and falls down to 30% at the highest density.In the mass limited sample, the fraction of blue galaxies is always < 20%, but shows a statistically meaningful increase from the lowest to the highest densities.
To summarise, the star-forming/blue fraction of galaxies decreases at densities higher than the LD median at each redshift (see Fig. 9).At densities lower than the median, we notice a steady decrease of the fractions at 0.1≤z<0.2,opposed to an initial increase at z≥0.2.Furthermore, the overall decrease of the star-forming/blue fractions going from the low to high densities is much more pronounced at lower than at higher redshifts.As it was previously found in Sect.4.1, considering either the magnitude limited sample or the mass limited sample lead to substantial differences only in the fraction of blue galaxies at z>0.2.Finally, differences in the absolute values of star-forming and blue fractions are again noticeable and are further investigated and discussed in Sect.6.2.

SFR-mass relation and galaxies in transition
We now study the SFR-M relation of galaxies in two extreme bins of LD representative of the lowest and highest LD environments.With reference to the histrograms represented in Fig. 9, we selected two percentiles that allowed us to seize the wings of Fig. 10: Fraction of star-forming galaxies in different bins of LD, computed with the sSFR (left panels) and rest-frame colour (right panels).Three redshift bins from z=0.1 up to z=0.5 are represented, and the redshift increases from top to bottom panels as indicated in each panel.A sigma-clipping has been performed on the parent LD distributions to remove outliers and bins with a non-statistically representative number of objects.Panels and symbols are shown as in Fig. 6. the distribution (having previously removed outliers), considering its narrow shape.The selected percentiles are 15th and 85th.
In Figure 11 we report the SFR-M relation of galaxies in the low-and high-LD regimes.We proceed as before and compute the median SFR in stellar mass bins of 0.2 dex width in the low-and high-LD regimes.The median values of the SFR computed in bins of stellar mass show little variation with LD (yellow diamonds versus cyan stars), whose values that are always consistent within the error bars.Differences arising at the highest stellar mass values at z≥0.3 may be mostly driven by the low sample statistics, and therefore should be taken with caution.
The right-hand panels of Fig. 11 show the ∆SFR with respect to linear fit to the SFR-M relation used in Sect.4.2, computed as previously done for the global environment.The median ∆SFR values are very similar in the high-and low-LD regimes at all redshifts, and the statistical similarity between the two samples is further confirmed by the outcome of the KS test: P(KS)>>0.05at all redshifts.
Finally, we also compute the fraction of transition galaxies in the two extreme LD bins (see Tab. 4), finding no differences within the error, at all redshifts.Histograms of the differences between the expected SFR computed using the main sequence fitting line at the stellar mass of any given galaxy in our sample and its actual SFR (∆SFR).Median values of the distributions are shown with vertical dashed lines and colour coded as written in the legend.

Discussion
In this paper we have adopted two definitions of environment.The first is based on the X-ray selection of virialised structures; the second is based on the local galaxy number density.We are now in the position of contrasting the results, and we aim to understand whether the different parametrisations lead to similar conclusions.
In the literature, the environmental dependence of the galaxy properties was previously investigated by many authors, adopting either a global or local parametrisation, but hardly ever directly contrasting the two in homogeneous samples.Nonetheless, as discussed by Vulcani et al. (2011Vulcani et al. ( , 2012Vulcani et al. ( , 2013) ) and Calvi et al. (2018), the two definitions are not interchangeable and can give opposite results, highlighting that different processes dominate at the different scales probed by the different definitions.
As far as galaxy fractions are concerned, we find that regardless of the environmental definition adopted the fraction of blue/star-forming galaxies is systematically higher in the field/least dense regions than in the virial regions of clusters/highest densities.This effect is less significant in the highest redshift bin analysed.Our results are overall in line with what was previously found in the literature, both considering the global (e.g.Iovino et al. 2010;Muzzin et al. 2012) and local (e.g.Balogh et al. 2004a;Cucciati et al. 2017) environments.Similarly, the overall SFR-M relation also seems not to depend on the parametrisation adopted, which agrees with numerous literature results that claim the invariance of SFR-M relation on environment (e.g Peng et al. 2010).
Nonetheless, the two definitions of environment lead to different results when we analysed the fraction of galaxies in transition.In fact, using the local environment the fraction of galaxies below the main sequence is similar at low and high density, whereas in clusters (and especially in their virial regions) a population with reduced SFR with respect to the field is observed.This population is most likely in a transition phase of star formation and, although clearly detected, it is not able to affect the whole SFR-M relation because it constitutes a small fraction of all galaxies, as shown in Tab. 4.

Galaxies in transition in the different environments and their evolution with redshift
The presence of a population of galaxies in transition from being star forming to passive was already detected in galaxy clusters by several works at low and intermediate redshifts (Patel et al. 2009;Vulcani et al. 2010;Paccagnella et al. 2016), and has been interpreted as an evidence for a slow quenching process preventing a sudden relocation of galaxies from the star forming to the red sequence.
In the previous sections, it was not possible to investigate the evolution of the incidence of transition galaxies, as a different mass complete limit was adopted at each redshift.Now we consider instead the same mass limit, to allow for fair comparisons.We adopt the most conservative value, that is the mass completeness limit in the highest redshift bin.Fractions are given in parenthesis in Tab. 4.
Figure 12 shows the fraction of galaxies in transition in the redshift range 0.1≤z≤0.5 considering the global and local environments.
The upper panel shows that in the case of global environment the overall fraction of transition galaxies with log(M /M ) > 10.8 does not significantly vary with cosmic time, remaining around ∼ 15%, both in the field and among outer members.In contrast, virial members present higher transition fractions with a tentative increase as time goes by, although uncertainties prevent us from drawing solid conclusions.
The same Figure also compares our results to those obtained at low redshift (z 0.1) by Paccagnella et al. (2016), when the subsample of their cluster galaxies within 1r 200 and with stellar masses M ≥ 10 10.8 M is considered.The resulting transition fraction weighted for incompleteness is 0.30 +0.04 −0.03 , that is consistent with our results within the error bars and point towards the aforementioned increase in the transition fractions at more recent epochs.
In contrast, the lower panel of Fig. 12 shows no dependence of the transition fraction with redshift for galaxies located at different local densities, further demonstrating that the local environment does not affect the incidence of such population.Evidently, the two parametrisations are able to probe different physical conditions for galaxies, determining different timescales in the star formation process and quenching timescales.

Star-forming versus colour fractions in the different environments
In the previous sections we have separately analysed the dependence of the star-forming and blue galaxy fractions on the global and local environments.In both analyses a difference between the star-forming and blue fractions emerged, wherein the former is systematically higher than the latter.We stress that this difference is not likely to be due to the definition we adopted for determining the two populations: as previously described in Sect.3, the sSFR and colour threshold adopted for defining the star-forming and blue populations are physically motivated by the distribution of the galaxy samples in the sSFR-M plane and by the rest-frame colour distribution at different redshifts.
We further explored whether a choice of different cuts either on the sSFR and on the (g-r) rest-frame colour led to more similar galaxy fractions and concluded that the resulting sSFR and/or colour threshold to apply to the population in order to reconcile the fractions were totally non-physical.As already anticipated in Sect.3, the two quantities present intrinsic differences related to the tracers they are based on: the SFR is derived from the measure of the flux of emission lines sensitive to the short-lived massive stars, while avoiding as much as possible contributions from evolved stellar populations.It is basically able to probe the presence of newly or recently formed stars on timescales of ∼10-100 Myr.On the contrary, galaxy integrated colours are more sensitive to the integrated star formation history and in particular to the stellar populations dominating the galaxy light, and are further influenced by the dust content and metallicity of the galaxy.With this in mind, we can expect a good agreement between galaxy rest-frame colours and SFR indicators when the galaxy is actively forming stars at a steady rate on the main sequence or, conversely, when it is quiescent and has been passively evolving for some Gygayear.Differences between the two tracers may be expected for example when the galaxy suddenly interrupts its star formation activity as a consequence of the interactions with external physical mechanisms (e.g.environmentally related phenomena).
We are now in the position of directly comparing the fraction of star-forming and blue galaxies with the intent of obtaining some clues regarding the physical processes occurring in the different environments.
Figure 13 shows the ratio of the number of star forming to that of blue galaxies as a function of global (top panel) and local (bottom panel) environment, above the stellar mass completeness limit of each redshift bin.In the upper panel of the figure, a strong dependence of the F S Fing /F blue ratio on the global environment emerges.At 0.1≤z≤0.3,this ratio is highest in the virial regions of clusters, while it decreases in the other environments with little difference found between cluster outskirts and the field.Moving towards higher redshift, uncertainties prevent us from drawing solid conclusions, but still a hint of a higher F S Fing /F blue ratio within the virial radii of clusters than the other environments is visible.
In principle, this result might be contaminated by the presence of AGNs, and in particular LINERS, that could be misclassified as red star-forming galaxies.The dashed lines in Fig. 13 show the F S Fing /F blue ratios after AGNs have been removed (see Appendix B) and that this population cannot be responsible for the observed trends.
Our results suggest that in the innermost regions of clusters, besides the suppression of the star formation activity, further environmentally related physical processes come into play to produce a population of galaxies with a non-negligible SFR that however is not coupled with (blue) rest-frame colours.
This decoupling is most likely due to the different star formation histories that characterise galaxies in the different global environments.Indeed, Guglielmo et al. (2015) found that the star formation history of low-redshift star-forming galaxies has been decreasing since z∼2, and in particular the rate at which stars were produced in galaxies in clusters at high-z is higher than in the field, regardless of their stellar mass.This implies that, on average, star-forming galaxies in clusters formed the bulk of their stellar mass at older epochs than their counterparts in the field.Thus these star forming galaxies host older stellar populations which have redder colours, although these galaxies still are forming stars at the epoch of observation.
Alternatively, the presence of a population of red starforming galaxies may be also associated with a dust obscured star formation phase.Gallazzi et al. (2009) quantified that nearly 40% of the star-forming galaxies in a supercluster at z∼0.17 (Abell 901/902) had red optical colours at intermediate and high densities.These red systems have sSFR similar to or lower than blue star-forming galaxies, thus they are likely undergoing gentle mechanisms that perturb the distribution of gas inducing star formation (but not a starburst) and at the same time increase the gas/dust column density.
The incidence of the red star forming population is instead less dependent on the local environment: the lower panel of Fig. 13 shows no strong trends of the F S Fing /F blue ratio with LD at any redshift, also because of the large uncertainties, especially at higher redshifts.
These trends prove, once again, that the two environmental parametrisations are probing galaxies in different physical conditions, and that they cannot be used interchangeably.Indeed, there is no constant direct correspondence between the cluster cores and the highest LD regions and, similarly, between the lowest LD regions and the field.

Conclusions
In this work, we have conducted a study on the stellar population and star formation properties of galaxies in the range 0.1 ≤ z ≤ 0.5, by making use of two definitions of environment.When considering the global environment, we divided galaxies into cluster virial and outer members and the field.We also distinguished between clusters that belong or do not belong to a supercluster.When considering the local environment, we characterised galaxy properties as a function of the projected LD.
The main observables we considered for investigating galaxy properties in different environments are the fraction of starforming/blue galaxies, defined on the basis of the sSFR and colour, respectively, and the correlation between the SFR and stellar mass.The main results can be summarised as follows.
Fraction of star-forming and blue galaxies Considering the global environment, both in the magnitude and in the mass limited samples, cluster virial members reveal a deficiency of star-forming/blue galaxies with respect to all other environments at all redshifts, while field galaxies are the most starpopulation at all redshifts.Outer members exhibit a significant suppression of the star-forming/blue fractions with respect to the field only at 0.1≤ z <0.2, while at higher redshift they present similar fractions.Overall, no significant differences are detected between galaxies within and outside superclusters.
Considering the LD instead, the star-forming/blue fraction steadily decreases with increasing density only at 0.1≤z<0.2.At higher redshift, the fractions show a qualitatively similar dependence on density for log(LD[M pc −3 ]) 3, while at lower densities the trends slightly increase.
Regardless of the parametrisation of the environment, starforming and blue fractions are never consistent within the errors, probing that the two quantities reflect different aspects of the evolution of the galaxies.The star-forming to blue ratio is much higher in the cluster virial regions than in the field, most likely because of the different star formation histories of the galaxies in the different global environments.

SFR-Mass relation
Above the mass completeness limit, at all redshifts and considering both parametrisation of environment, galaxies in the virial/densest regions and galaxies in the field/less dense regions occupy the same locus of the plane, indicating no strong environmental effects at play.Comparing the galaxies at different redshifts, at fixed stellar mass we recover the well-known decline in SFR with time.At any given redshift, the median SFR as a function of mass is similar in all environments.Nonetheless, an important difference emerges between the global and local parametrisations.When using the former, a population of galaxies with reduced SFR compared to the expected value given their stellar mass is detected in the cluster virial regions.These are likely to be in transition from star forming to passive.Their incidence increases going from the higher towards lower redshifts.Such a population is not detected when comparing the SFR-mass relation of galaxies in two extreme bins of LD.This dichotomy emerging in the galaxy properties when investigated in either a global or local environment framework are intrinsically related to the different physical meaning of the two parametrisations.The potential well of X-ray groups and clusters must enhance physical processes related to the presence of the dark matter halo and the hot intra-cluster medium on one side, whereas high-LD regions select associations of galaxies which are physically close and thus more prone to interactions and encounters with other galaxies.
Whether these two definitions insinuate differences in the star formation histories of the involved galaxy populations will be investigated in detail in Guglielmo et al. (in preparation).In fact, the availability of full spectral fitting results on the galaxy sample explored in this paper enables us to follow a complementary approach, and trace the histories of individual galaxies to examine how the SFH proceeded in X-ray clusters, in the field and in high-/low-local overdensities of galaxies.This technique was already exploited in Guglielmo et al. (2015) in a low-redshift sample of galaxies in clusters and in the field, which can then be used as basis for comparison with the local Universe population.also include normal galaxies with high SFRs, making the AGN contribution evaluated in this work an upper limit.
Having classified and flagged broad-and narrow-line AGN, we crossmatch the catalogue of spectra with our spectrophotometric catalogue and compute their upper limit fraction with respect to the number of star-forming galaxies in the three usual redshift bins and in the magnitude complete sample (similar fractions are also found in the mass limited sample): -0.1≤z<0.2:762/5026=15.2%-0.2≤z<0.3:1166/5817=20.04%-0.3≤z<0.5:372/3047=12.2%

Appendix C: Local density
We compute the LD of galaxies in the spectrophotometric sample taking as a reference the photo-z sample used in the spectroscopic completeness computation, and considering one redshift bin at a time.The LD around each galaxy is given as the ratio of the number of galaxies in the parent photometric-redshift sample per unit of projected comoving area on the sky.Our method proceeds through the following different phases: -Computation of the observed magnitude limit used to select galaxies in the sample as a function of redshift.To perform the same sample selection, we apply the same absolute magnitude cut in all the redshift slices.The value is selected in order to balance the error in the photo-z estimate, which increases towards fainter magnitudes, and the propagation of the observed magnitude down to redshift 0.1, and thus to minimise the loss of galaxies occurring with brighter observed magnitude cuts.We consider as observed magnitude limit r=23.0 at z=0.5 and compute the corresponding absolute magnitude as follows: where r is the observed r-band magnitude and D L is the luminosity distance in pc.The value K corr is the K-correction that takes into account that the same photometric filter samples different spectral ranges when applied to the SED of galaxies at different redshifts and is taken from Poggianti (1997), assuming the typical value of an intermediate type galaxy (Sab) in r band at the selected redshift.The application of this formula leads to an absolute magnitude of M r = -19.89,which is then converted into an observed magnitude limit as a function of redshift by means of the inverse formula, where the D L is computed at the redshift of the considered galaxy, K corr is a function of redshift, and P.E.(z) is the passive evolution of galaxies, which becomes redder with decreasing redshift as a consequence of the ageing of their stellar population; the correction for passive evolution is 0.1 mag each ∆z=0.1 (Poggianti et al. 2008).
-Computation of the number of galaxies in the spectrophotometric sample within a comoving circle of 1 Mpc radius at the redshift of the galaxy in the centre and within a redshift range of ±0.05 with respect to the redshift of the same galaxy.To account for uncertainties in the photo-z measurements, we estimate the expected number of galaxies in the photo-z sample in the considered redshift range around the selected galaxy with the same method used for the spectroscopic completeness.We define the fractions f 1 and f 2 given in equations A.1 and A.2 in the spectrophotometric sample and use them to weight the photo-z sample and compute N exp .This value represents the correct number counts within the comoving projected area of 1 Mpc radius around the galaxy.The area of the circle is then computed and the LD is defined as the ratio of the two quantities.
-Correction for edge effects in the field.For galaxies located at the edges of the XXL-N field, we correct the circular area for the fraction of area effectively covered by the data points, and therefore remove empty circular sectors.We adopt a numerical solution based on a Monte Carlo simulation method.We generate a circular homogeneous distribution of data points by populating a circle with a sufficiently high number of points (100000) and compute the zone of exclusion with respect to the edge conditions of the field as the ratio of the number of points falling outside the edges to the total number of points included in the circle.The area of the circle in physical units that has to be considered in the LD calculation is then the total comoving area multiplied by the fraction of area included in the field, f in = 1 − f out , where f out is the fraction of area falling outside the galaxy field.
The LD is finally expressed as the logarithm of the quantity computed in the procedure outlined above, with dimension [LD]=Mpc −2 .
Figure C.1 reports the spatial distribution of galaxies in the spectrophotometric sample colour coded for the LD measures.Each panel also reports the circle of 3r 200 radius of the clusters in each redshift bin; as expected, in most of the cases, galaxies within the circles are characterised by high LD values.

Fig. 1 :
Fig. 1: M 200 (top), L XXL 500 (bottom) versus redshift for the 111 XXL-N C1+C2 clusters at 0.1≤z≤0.5.Clusters that belong to superclusters are represented by red stars, cluster that do not belong to any superclusters are represented by green points.

Fig. 2 :
Fig. 2: Spatial distribution in the XXL-N area of galaxies in the spectrophotometric sample (yellow dots) and of X-ray confirmed clusters.The clusters in superclusters are reprensented with red stars and the clusters outside superclusters with green points.The region is divided into 22 cells (named as indicated inside each cell), used to compute the spectroscopic completeness (see details in Appendix A).

Fig. 4 :
Fig. 4: Rest-frame (g-r) colour distributions in five absolute magnitude bins for galaxies at 0.1 ≤ z < 0.2.The red curve shows the double-Gaussian fit performed on the distributions and the single Gaussians are represented with the black dashed line.The magenta vertical lines indicate the local minima in the valley between the two Gaussian peaks, and define the separation between the red sequence and blue cloud.

Fig. 5 :
Fig. 5: Rest-frame (g-r) colour distributions performed in one representative absolute magnitude bin in the two highest redshift bins indicated in each panel.Curves and colours are shown as in Fig. 4.

Fig. 8 :
Fig. 8: Fraction of galaxies in transition in the mass limited sample in the three redshift bins.Filled dots represent galaxies in the different environments, as written in the x-axis.The (S) and (NS) contribution to the virial and outer member populations are also represented with empty symbols and dashed error bars.Error bars are computed via bootstrapping.

Fig. 9 :
Fig. 9: Distributions of the logarithm of the LD in the three redshift bins, as indicated in the labels.Histograms are drawn after a sigma-clipping has been performed on the parent distributions.The red dashed vertical lines represent the 15th, 50th and 85th percentiles, respectively.

Fig. 11 :
Fig. 11: Left panels.SFR-M relation for galaxies in two regimes of LD, corresponding to the wings of the LD histograms shown in figure 9. Panels and lines are shown as Fig. 7. Cyan stars and the gold diamonds represent the median values of the SFR computed in 0.2 dex stellar mass bins, for the low-and high-LD regimes respectively.Error bars are computed as in Fig. 7. Right panels.Histograms of the differences between the expected SFR computed using the main sequence fitting line at the stellar mass of any given galaxy in our sample and its actual SFR (∆SFR).Median values of the distributions are shown with vertical dashed lines and colour coded as written in the legend.

Fig. 12 :
Fig. 12: Fraction of galaxies in transition at 0.1≤ z ≤ 0.5 considering the global (top) and local (bottom) parametrisation Fractions are computed for log M/M ≥ 10.8, the stellar mass completeness limit at 0.3≤z≤0.5.Error bars on the fractions are computed via bootstrapping.In the top panel, the blue star represents the fraction of transition galaxies in the local universe, adapted from Paccagnella et al. (2016).

Fig. 13 :
Fig. 13: Ratio of the fraction of star-forming (F S Fing ) to blue (F blue ) galaxies in the mass limited sample in the three redshift bins and in different global (top) and local (bottom) environments.Dashed lines in the top panel show trends when AGNs are removed form the sample as explained in the Appendix B. In both panels, error bars are computed by propagating the asymmetric errors on the single fractions by means of the statistical error propagation.

Fig
Fig. A.1: Completeness curves computed in three redshift bins and in different RA-DEC cells in the sky, as explained in the main text.From the top to the bottom panel, the represented redshift ranges are respectively 0.1 ≤ z < 0.2, 0.2 ≤ z < 0.3, 0.3 ≤ z ≤ 0.5.

Fig
Fig. C.1: Spatial distribution in the sky of the spectrophotometric magnitude limited sample.Data points are colour coded according to their log(LD), after a sigma-clipping has been performed on the parent distribution.From the top to bottom panel the represented redshift bins are 0.1 ≤ z < 0.2, 0.2 ≤ z < 0.3, 0.3 ≤ z ≤ 0.5, respectively.Each panel contains the 3r 200 extensions of the clusters at the redshift of the bin, represented with black empty circles.

Table 1 :
List of superclusters detected in XXL Paper XX and included in our sample.The first column is the name of the supercluster according to XXL Paper XX nomenclature, the second and third columns are the centroid coordinates (J2000.0equinox) the fourth column is the mean redshift, and the last column is the list of clusters belonging to each supercluster.

Table 5 :
Best-fit parameters of the linear fit to the SFR-M relations shown in Fig.7, in three redshift bins.The fit is performed on the sample including all the environments together, and the fitting line has the following general equation: Log(SFR)= aLog(M )+b.