Ages and metallicities of stellar clusters using S-PLUS narrow-band integrated photometry: the Small Magellanic Cloud

The Magellanic Clouds are the most massive and closest satellite galaxies of the Milky Way, with stars covering ages from a few Myr up to 13 Gyr. This makes them important for validating integrated light methods to study stellar populations and star-formation processes, which can be applied to more distant galaxies. We characterized a set of stellar clusters in the Small Magellanic Cloud (SMC), using the $\textit{Southern Photometric Local Universe Survey}$. This is the first age (metallicity) determination for 11 (65) clusters of this sample. Through its 7 narrow bands, centered on important spectral features, and 5 broad bands, we can retrieve detailed information about stellar populations. We obtained ages and metallicities for all stellar clusters using the Bayesian spectral energy distribution fitting code $\texttt{BAGPIPES}$. With a sample of clusters in the color range $-0.20<r-z<+0.35$, for which our determined parameters are most reliable, we modeled the age-metallicity relation of SMC. At any given age, the metallicities of SMC clusters are lower than those of both the Gaia Sausage-Enceladus disrupted dwarf galaxy and the Milky Way. In comparison with literature values, differences are $\Delta$log(age)$\approx0.31$ and $\Delta$[Fe/H]$\approx0.41$, which is comparable to low-resolution spectroscopy of individual stars. Finally, we confirm a previously known gradient, with younger clusters in the center and older ones preferentially located in the outermost regions. On the other hand, we found no evidence of a significant metallicity gradient.


INTRODUCTION
Populations of star clusters are excellent tools for understanding the formation and evolution of galaxies, as we can derive age, metal-★ E-mail: gabriel.fabiano.souza@usp.brlicity, and kinematics.Star clusters in distant galaxies can be studied using integrated light when it is not possible to resolve stars.Local Group galaxies can be studied in more detail, and be used as a laboratory to understand the regime of application of integrated light techniques that are used to analyze more distant galaxies.In this context, the Small Magellanic Cloud (SMC), is a satellite of the Milky Way (MW) that constitutes a valuable laboratory for calibrating stellar cluster characterization methods.Among the reasons that establish the importance of the SMC, we summarize a few: • It is close enough (∼60 kpc, Gieren et al. 2018) to have stellar content spatially resolved, allowing stellar parameter determination of individual stars; • It has hundreds of stellar clusters, covering ages ranging from a few million years to about 10 billion years, but with an agemetallicity relation different from the one found in the Milky Way (Leaman et al. 2013;Parisi et al. 2022); • In particular, the SMC has massive clusters (>10 4  ⊙ ), younger than 5 billion years and with sub-solar metallicities (e.g.NGC 330, Usher et al. 2017), a combination non-existent in and, thus, complementary to the Galaxy; • The trio Large Magellanic Cloud (LMC), SMC, and MW is heavily interacting with each other and leaving traces in their stellar populations (e.g.Niederhofer et al. 2018;Zivick et al. 2019;De Leo et al. 2020;Dias et al. 2022).
• The SMC star cluster population has a growing number of objects fully characterized in terms of ages and metallicities with detailed analysis that serve as a reference for direct comparison and calibration of integrated-light based studies.
For the last few decades, in several studies, ages from isochrone fitting in deep color-magnitude diagrams (CMDs, Kerber et al. 2007;Goudfrooĳ et al. 2014;Dias et al. 2016;Milone et al. 2023) and metallicities from stellar spectroscopy (Parisi et al. 2014(Parisi et al. , 2015(Parisi et al. , 2016;;Song et al. 2021;Parisi et al. 2022;Dalessandro et al. 2016;Mucciarelli et al. 2023) have been determined.Besides, there are also integrated photometry studies of stellar clusters in the Magellanic Clouds (MCs; Hunter et al. 2003;Goudfrooĳ et al. 2006;de Grĳs & Goodwin 2008;Pandey et al. 2010;Asa'd & Hanson 2012;Popescu et al. 2012), allowing a compilation of a sample of MCs clusters with well-known properties.Such a sample is important for extragalactic studies since it allows accurate calibration of integrated light models of simple stellar populations based on spectra (González Delgado & Cid Fernandes 2010;Asa'd et al. 2016Asa'd et al. , 2022;;Usher et al. 2017;Gonçalves et al. 2020) and broadband photometry (Popescu et al. 2012).In many cases, the age-metallicity degeneracy (Worthey et al. 1994) is also present in integrated light.Although integrated spectroscopy and resolved photometry are capable of reducing the degeneracy, they are observationally much more expensive than techniques using integrated photometry.An intermediate path between the two approaches above can be provided by photometric studies based on a photometric system with narrow filters centered on important spectral characteristics that allow us to study these stellar populations.The path taken by this paper will be the use of the intermediate approach in order to determine ages and metallicities for a large sample of SMC clusters.
The goal of this work is two-fold.The first is to use the SMC as a test case, for which we devised a technique to obtain cluster ages and metallicities from their integrated light, using multi-band photometry and assuming a proper calibration.The second goal is to provide first-time measurements of the ages and metallicities of a number of SMC clusters and analyze them as a population to understand the SMC chemical evolution.In the future, the same tool can be used for obtaining cluster parameters for more distant galaxies, where no resolved photometry will be available.To achieve our goals, we used integrated photometry from the Southern Photo-metric Local Universe Survey (S-PLUS1 , discussed in Section 2.1, Mendes de Oliveira 2019).
We note that S-PLUS resolved CMDs for these SMC clusters, unfortunately, could not be used for double-checking the integrated photometry results.This is due to crowding in the cores of clusters, which makes resolved stars available only in their outskirts, limiting the number of sources usable for, e.g., an isochrone-fitting approach.Moreover, the photometric depth is not enough to reach the main sequence turnoff.However, we were able to validate our results with ages and metallicities from deep and resolved CMD from the Hubble Space Telescope (Mighell et al. 1998;Dolphin et al. 2001) and the VISCACHA Survey (Maia et al. 2019) for some of our sample.Future analysis using spatially resolved deeper data from Rubin Observatory (Vera C. Rubin Observatory LSST Solar System Science Collaboration et al. 2020) may be able to check our results based on stellar cluster integrated photometry and may further validate the technique devised here for cases when spatially resolved photometry is not available.
The paper is organized as follows.In Section 2 we describe how the data is obtained.In Section 3 we present the method used in this work.The results and discussions are in Section 4, and conclusions are in Section 5.

S-PLUS
The S-PLUS is an astronomical mapping of the southern hemisphere which, when complete, will cover about ∼9300 square degrees of the sky.The S-PLUS uses the Javalambre system of 12 optical filters, five broad and seven narrow, designed by Marín-Franch et al. (2012) and originally used by the Javalambre Photometric Local Universe Survey (J-PLUS2 , Cenarro 2019).This filter system represents a great opportunity to characterize the stellar clusters of the Magellanic Clouds.In Figure 1 we present the transmission curves of the filters used in S-PLUS, together with the images of NGC 458 cluster in all 12 bands.In order to study SMC star clusters, we analyzed images of 2 deg 2 from S-PLUS, the only survey with multiple narrow-band filters covering this region of the sky.The SMC was observed with a typical seeing of 1.5 ′′ -better than 2 ′′ in any case, air mass values between 1.4 and 1.6 and exposure times ranging from 3 × 33 to 3 × 290 seconds (depending on the filter), as described in Table 5 of Mendes de Oliveira (2019).In Figure 2 we show examples of some of the stellar clusters studied in this work, with combined images of the 12 bands using the S-PLUS cloud3 .In this figure, it is clear that the resolved photometry of stars in the cluster cores is heavily limited by the seeing.In this paper, we chose to not compute the resolved photometry of stars not only due to confusion in the cores but also due to the depth of the S-PLUS survey (typically 20 AB mag in the narrow-band filters and 20.5 AB mag in the sloan-like filters).Besides that, the pixel scale of SPLUS is 0.55 arcsec pixel −1 (Mendes de Oliveira 2019), therefore, even a better seeing would not allow a resolved photometric analysis of the crowded cluster cores as we can see in Figure 3, a zoom of the NGC 121 star cluster.S-PLUS images at the distance of the SMC are not suitable to reach the main sequence turnoff to fit an isochrone to the color-magnitude diagram of the stars.

Stellar Clusters reference catalog
Since the Magellanic Clouds are very close to our Galaxy, they have many stellar clusters with parameters well determined in the literature.A recent effort to put all the best determinations of these parameters for SMC clusters in a single catalog can be found in Bica et al. (2020).This list includes stellar clusters, associations, and extended objects related to stellar populations.We can, then, use this catalog to validate the method that uses integrated photometry of the clusters with S-PLUS and apply it to obtain new results.Only objects from the catalog classified as stellar clusters were used for this work.From this catalog, values of ages, metallicities (when available), spatial coordinates of the centers, and sizes were extracted.In cases where there was more than one reliable age determination, the catalog itself included the geometrical averages between the values, resulting in a single value for each object.As for metallicity, the catalog prioritized results following the order: calcium triplet and other high-resolution spectroscopy of red giants, isochrone fitting of CMDs, integrated spectroscopy, and integrated photometry taken from Bica et al. (1986).This order was chosen to give priority to the most reliable methods of metallicity determination.

Photometry using photutils package
In order to obtain the integrated magnitudes of the clusters, we used the Python package photutils (Bradley et al. 2020).This package allows obtaining the flux in circles centered on the stellar clusters.The radii were chosen from the maximum value between the two semi-axes, taken from Bica et al. (2020).An example of using the package is shown in Figure 4; white circles indicate the aperture used to obtain the cumulative flux of the object, while the outer ring of red circles represents the apertures chosen to obtain the background flux level, which must be subtracted from the measurement of the flux of the object.The inner radius of the background was chosen using the aperture of the cluster plus a value of 0.15 arcminutes.For the width of the ring used to determine the background, we used an arbitrary fixed size of 0.6 arcminutes for all clusters, which was considered a sufficient width to obtain a good measure of the background.To determine the background value, a median sigma clipping was used.Using this method to calculate the background value is important since it excludes outliers such as very bright stars in the field, meaning that only pixels with flux values within a range of 3 of the average value are kept.This is particularly important for images of the Magellanic Clouds since the fields in which the studied stellar clusters are located have a high concentration of objects.To obtain the final magnitude values, it was necessary to transform the fluxes into magnitudes.Zero points were obtained using the techniques in Almeida-Fernandes et al. (2022), which describes the second data release of S-PLUS (SPLUS DR2).The extinction coefficients were calculated according to Section 2.4.The reddening values used will be described in Subsection 2.5.The  final equation used for the magnitude, corrected for zero point and extinction, is: where   is the final magnitude in each band ,   is the total flux in .   is the zero point for the given band in the S-PLUS field in which the cluster is located, obtained using the techniques described in Almeida-Fernandes et al. (2022).The zero-point converts the measured instrumental magnitude to AB-calibrated magnitudes at the top of the atmosphere.This value accounts for the transformation to the AB-magnitude system, also taking into account the efficiency of the instruments, atmospheric conditions and the airmass at the time of the observation.The AB-calibrated magnitudes are still affected by the interstellar medium (ISM) extinction, which is corrected by subtracting   ×  (  − ) from the instrumental magnitudes.  is the extinction coefficient, related to the S-PLUS filter system, calculated using the transmission curves of the survey's passbands.The color excess,  (− ) , is a measurement of the reddening in the direction of the cluster.In this work, we use the color excess maps provided by Górski et al. (2020).Throughout this work, the magnitude names   will be replaced with , to indicate the magnitude in a given band.The uncertainty   of each magnitude was determined from 1% of the magnitude value in the respective band.This choice was made considering all possible sources of errors: calibration and image.The faint end of our sample is ≈ 17 mag, so this turns out to be a pretty conservative error.

ISM Extinction coefficients
As mentioned before, in order to correct the reddening of the clusters, the extinction coefficients (  ) were calculated using the ex-tinction law proposed by Schlafly et al. (2016) with   = 3.1.These coefficients were calculated using the central wavelength values of each of the S-PLUS bands, obtained from Mendes de Oliveira (2019).The values used for the central wavelength (  ), FWHM, and   are presented in Table 1.Since the central wavelengths of the S-PLUS filter system are slightly different from those of the J-PLUS system, we also have a difference between the values of   when comparing the values obtained in López-Sanjuan et al. (2019).

Reddening maps
The extinction coefficient of each band is associated with the reddening value  ( −) of the stellar cluster.Such an effect is caused by the interstellar dust of the Milky Way and the MCs themselves.For this work, the reddening maps of Górski et al. (2020) were used.The values were calculated from the difference between the intrinsic and the observed color in clumps of stars in the red giant branch.To assign reddening values to each of the studied clusters, we performed an interpolation of the maps as a function of R.A. and Decl., then calculated the reddening at the central coordinates.

Inspection of the u and r bands
Performing integrated photometry of stellar clusters in crowded fields can be a challenge.Problems, such as contamination by bright field stars that are not members of the cluster, led us to double-check the obtained photometry.For this purpose, we visually inspected the S-PLUS images in the u and r bands for all clusters.The flux growth curve of each cluster was analyzed in order to check if there was convergence to the total magnitude, or if there was contamination from neighboring sources.We excluded the cases where no convergence was reached.We present an example of this exercise's results in Figure 4 for the cluster NGC 458.
Figure 5 shows the sample after this visual inspection.The stellar population models used in this work were compared to our data.Black circles show the models used in BAGPIPES (see Section 3.1 for more details), while the blue, green, and red circles represent the data.As can be seen in the figure, not all stellar clusters have a good agreement with the models.There are two main regions, one with small  −  (< − 0.20, blue circles) and the other with higher values of  −  (> + 0.35, red circles), with the largest number of clusters with photometry different from what was expected from the models.There can be numerous reasons for the disagreement between the photometry and the models, such as the presence of Be stars or H ii emissions, which can cause the clusters to appear bluer, but we did not check any further.Therefore, we decided to exclude these two regions from our sample, being restricted to where the grid is densest (green clusters, where −0.20 ≤  −  ≤ 0.35), and to avoid extrapolating beyond the model grid.After all the procedures, the sample of this work contains 88 stellar clusters, 11 with no age and 65 with no metallicity determinations from the Bica et al.

BAGPIPES
BAGPIPES is a code that allows one to create galaxy SEDs from parametric models of star formation histories, as well as adjust spectra and photometry for cases without sufficient resolution.The models include both the stellar continuum and the emission lines produced by the ionized gas from star-formation regions, the latter being estimated with the photo-ionization modeling software Cloudy (Ferland et al. 2017).Both the continuum and the emission lines are subject to attenuation by dust and gas present along the line of sight.Differential attenuation effect is also considered, in which young stars are immersed in their parent molecular cloud as well as behind a curtain of interstellar dust.Thus, young stellar populations are subject to more attenuation than old ones (Charlot & Fall 2000).Being able to take all these parameters into account makes BAGPIPES a potentially great tool for analyzing unresolved stellar populations in S-PLUS as well as other similar surveys.
The code works under several assumptions that must be taken into consideration.To begin with, the spectrum of a galaxy can be modeled as a sum of simple stellar populations (SSPs), whose combination is directly dependent on the galaxy's star-formation history (SFH), in addition to the transmission functions of the ionized and neutral interstellar medium.From this, it is possible to find the galaxy luminosity, which, once calculated, is converted to flux density, using the distance and the transmission function of the intergalactic medium (see Conroy 2013 for a review).The SSPs used in this code are from the 2016 version of Bruzual & Charlot (2003) constructed using an initial mass function from Kroupa & Boily (2002).For the SFH, we account for the stellar mass formed for each period during the SFH.For this task, we considered the full range of possible choices provided by BAGPIPES, but always with one parametric form of SFH behavior.Since we are using a galaxy-fitting code for stellar clusters, we adopted a single burst SFH considering that all stars of the cluster were formed at the same time with the same metallicity.
All of these parameters are taken into account to perform the fitting: The code uses Bayesian inference, using as priors the stellar population parameters and other free parameters, checking and updating their probabilities at each realization.In Table 2, we have the free and fixed parameters used in this work with the upper limit for age being 15 Gyr.The redshift was set in the range of the known SMC redshift (McConnachie 2012), from 0 to 0.001, and the mass range from 0 to 13 (log(/ ⊙ )).We tested the mass range and found that it has no influence on the determination of the metallicities and ages.In fact, mass and distance will not change the shape of the spectrum and therefore will not affect the derived parameters.Lastly, all the dust-related parameters were fixed as zero since the clusters were already dereddened.Figures 6 and 7 represent the BAGPIPES results for NGC 458, confirming the correlation between age and metallicity seen in the literature (e.g.(Bica et al. 1986)).

Comparison with the literature
To apply the method to new stellar clusters, it was necessary to validate the method for clusters with previously known parameters.For this, we compared the results of this work with results from Bica et al. (2020) for clusters with known age and metallicity.The metallicity values from BAGPIPES have the format   ⊙ with  ⊙ = 0.02, where  ⊙ is the mass-fraction solar metallicity.To compare to most of our literature, we are multiplying the output value of the code by 0.020 0.0152 ≈ 1.316, since we are adopting  ⊙ = 0.0152.We approximate the [Fe/H] values using [Fe/H]≡ log(   ⊙ ).
In Figure 8, we have our clusters with ages and metallicities already known and we compare the literature values with the ones obtained using BAGPIPES.For age, there is a good agreement with the reference, with a larger dispersion for clusters with age < 10 8.6 yr when compared to the rest of the test sample.We encountered a residual when compared to the literature values of around 0.31 for log() and 0.41 dex for [Fe/H].These values were calculated using a bi-weight scale (Beers et al. 1990), which diminishes the effects of outliers.From the results obtained with BAGPIPES, metallicities comparable to those obtained through low-resolution spectroscopy of individual stars were determined (≳ 0.2 dex, Yanny 2009).In the case of metallicity, it is also clear that there is an offset of 0.21 dex, which means that BAGPIPES is overestimating the metallicities.Even though we are not able to derive accurate metallicities for individual clusters, patterns regarding the metallicity distribution of the SMC can still be detected.
We can also assess the distributions of ages and metallicities to verify if our obtained parameters are in agreement with the literature.The two panels of Figure 9 show the probability density distributions using kernel density estimators (KDEs).The age distributions of our work have a first peak near log() = 8.5, which is close to the literature, and a second peak log() ∼ 9.5.As for metallicity in BAGPIPES, we have a much higher concentration of clusters with [Fe/H] around −0.4 and a second less pronounced peak at [Fe/H]= −1.0.The peak at [Fe/H]= −1.0 is similar to the peak found in the literature.
To account for the number of peaks the age and metallicity distributions have and their positions, we can fit Gaussian Mixture Models (GMM, Muratov & Gnedin 2010) to the distributions of ages and metallicities obtained.After testing different numbers of components for each parameter, we selected the model with the lowest Bayesian Information Criterion (Schwarz 1978), value as the best GMM fitted.In the case of age, the bimodal distribution with peaks at log(age) = 8.3 ± 0.5 and log(age) = 9.6 ± 0.1 was better fitted, which is linked to the large number of young clusters found in the center of the Small Magellanic Cloud.For metallicity, the best fit was found using the bimodal distribution, with peaks at −0.3 ± 0.1 dex and −0.8 ± 0.4 dex.These fits were also done for the literature sample with 314 ages and 62 metallicities, resulting in an unimodal distribution for the age (8.4 ± 0.6) and a bimodal for the metallicity (−0.1 ± 0.1 dex and −0.8 ± 0.4 dex).Recent literature on stellar populations in the SMC indicates that there is a metallicity peak at −0.7 dex for young populations (Karakas et al. 2018) and between −0.8 dex and −1.0 dex a peak for red giants (D'Onghia & Fox 2016).We can also compare the unimodal and bimodal metallicity peaks found with those in Parisi et al. (2022), obtained through the spectroscopy of red giant stars using the Calcium Triplet.This work states that the greater the number of stellar clusters, the less significant the bimodality is, compared to Parisi et al. (2015), where there were fewer stellar clusters in the sample.Later, De Bortoli et al. (2022) showed that this possible bimodality happens when we consider two different regions of the SMC (inner and outer region).Although BAGPIPES results provided a bimodal shape to the metallicity distribution, one of the peaks is much higher than expected.

Spatial distributions
We, now, look at the derived ages and metallicities as a function of the spatial coordinates (Figure 10).We found that the core regions of this galaxy are predominantly occupied by young clusters,  while its outskirts contain mostly older ones.This result is, perhaps, not unexpected given that the young clusters are associated with star-forming regions found in the center of SMC.However, we now confirm this expectation with a larger sample of clusters with homogeneously derived parameters than ever before.We also note the existence of some young clusters at the edges of the SMC associated with the Magellanic Bridge (Piatti et al. 2015).In order to quantify this observation, we analyzed the evolution of the R.A. and Decl.dispersions in bins of log (age) (Table 3).We found 1 evidence for older clusters (log () ≥ 9) being more spatially diffuse than young ones (log (age) < 9).Interestingly, despite this clear existence of an age gradient, we found no evidence for a metallicity gradient from our cluster data in the SMC (Table 4).Indeed, the metallicity gradient in the SMC is estimated to be quite small, at the level of −0.031 ± 0.005 dex/kpc (Choudhury et al. 2018) and our BAGPIPES values might not be precise enough to probe it.Another way we can investigate these gradients is by relating the stellar parameters to the projected distance of a given stellar cluster.This projected distance is the semi-major axis of the ellipse around the center of the SMC, concentric to the LMC main body outline, which passes through the cluster (Piatti et al. 2007;Dias et al. 2014Dias et al. , 2016;;Parisi et al. 2016).Then, we can compare directly with Figure 8 from Bica et al. (2020).As we have stellar clusters only at ≲ 3 degrees from the SMC's cen, they are mostly contained within the main body of the SMC, thus we do not see any inversion in the correlation between the parameters and the projected distance to the center, as it only happens at a 4-5 degrees.However, we were still able to confirm that the age/metallicity variations prior to 3 degrees are not large both in age and metallicity.

Age-metallicity relation
The With this new set of parameters for SMC stellar clusters at hand, we are also able to compare it with the AMR of our Galaxy.For this, we utilize the sample of globular clusters (GCs) from Kruĳssen et al. (2019).This compilation includes both in-situ GCs, born in the Milky Way itself, as well as ex-situ ones, which were accreted over the course of the Galaxy's hierarchical assembly history (e.g., Massari et al. 2019).The most prominent ex-situ population consists of GCs brought into the Milky Way's halo alongside the infall of the Gaia-Sausage/Enceladus (GSE; Belokurov et al. 2018, Haywood et al. 2018, and Helmi et al. 2018), the dwarf galaxy associated with the last significant merger experienced by the Galaxy.Additionally, we compare our results to ages and metallicities of Galactic open clusters (gray squares) from Dias et al. (2021).
The most note-worthy feature of Figure 11 is that, at a given age, our results predict lower metallicities in comparison to the GSE model (black line) of Limberg et al. (2022, see also Forbes 2020and Callingham et al. 2022).This behavior is naturally explained by means of the mass-metallicity relation (e.g., Kirby et al. 2013), given that the GSE progenitor is expected to be more massive than the SMC (Feuillet et al. 2020;Naidu et al. 2020Naidu et al. , 2021) ) and that the SMC has been much less efficient in star formation as expected for a galaxy with this mass (Nidever et al. 2020).Moreover, this result is also consistent with chemical-evolution studies based on stellar abundances for both the GSE and the SMC (Hasselquist et al. 2021).The obvious limitation regarding this conclusion is that our results account for all star clusters in our S-PLUS SMC sample, while the available GSE models available can only account for old GCs.However, in comparison with Galactic open clusters, SMC ones are also more metal-poor at any given age.Therefore, it is reassuring that our result is consistent with expectations from standard galaxyevolution assumptions and well-known previous literature models of the SMC.
The age-metallicity relation of this work also corroborates with  2023) analyzed the chemical abundances of field stars and found a similar conclusion in the sense that the chemical evolution and metallicity distribution of the main body and bridge are similar.In summary, the results from this work are revealing the chemical evolution of the host galaxy when we analyze the star clusters as a population, even if individual cluster ages and metallicities have larger uncertainties with respect to CMD results for example, and prove the power of this technique and of the S-PLUS multi-wavelength photometry.

SUMMARY AND CLOSING COMMENTS
In this work, we present a method to estimate the ages and metallicities of SMC stellar clusters from integrated photometry of S-PLUS.
We apply the new methodology to the SMC as a test case.In the future, the technique developed here might be applied to other external galaxies even outside the local group.The color interval −0.20 ≤  −  ≤ 0.35 was defined as the one with the most reliable density of models to cover all of our data.This interval contains 88 SMC clusters, 11 with ages and 65 with metallicities not previously determined in the literature.
• We obtained residuals compared to literature values with BAGPIPES at the level of Δ log() = 0.31 for age and Δ[Fe/H]= 0.41 dex for metallicity.
• The distribution of ages obtained was compatible with the literature distribution, with a peak for ages of ∼100 Myr.However, our BAGPIPES metallicities had a higher concentration of clusters at [Fe/H] ≈ −0.5 and a smaller peak near [Fe/H]∼ −0.9.We utilized a GMM method to identify one single peak for ages, at log() = 8.6 ± 0.6, related to a large number of young clusters in the sample.For metallicities, we found a more metal-rich peak at [Fe/H]= −0.4± 0.2 and a more metal-poor one at [Fe/H]= −0.9 ± 0.2.
• We managed to reproduce the previously known projected age gradient at the 1 level, where older clusters are in the outermost regions of the galaxy and younger clusters are closer to the center.On the other hand, we were not able to find any significant projected metallicity gradient.
• We were able to compare our stellar clusters with the exsitu Milky Way GCs that stem from the GSE dwarf galaxy.When compared to the AMR from the GSE, we confirmed that the SMC contains stellar clusters with lower metallicity values, as expected given the difference between the masses of each galaxy and the known lower star formation efficiency of the SMC.
• Our research findings are in line with the discoveries made by other studies regarding the correlation between age and metallic-ity in SMC Wing/Bridge.It indicates a small dip in metallicity at a log(age) of 9, which confirms consistency between the Wing/Bridge and the central regions of SMC, which is consistent with the formation scenario of the Magellanic Bridge.
The strength of our method is not to derive accurate parameters for individual clusters, our main goal is, instead, to detect patterns in the stellar age and metallicity distribution throughout the SMC by analyzing the star clusters as a population.Although parameters estimated from the tools presented here still carry significant uncertainties, we were able to provide, for a large sample and in a homogeneous way, ages and metallicities for SMC clusters and provide constraints to the SMC chemical and dynamical evolution history.As they are important to study the formation history of galaxies through stellar clusters, the methods presented in this paper can be applied to stellar clusters in other galaxies both within and outside the local group in S-PLUS as well as other similar surveys.

Figure 1 .
Figure 1.Main panel: Transmission curves of the S-PLUS filters, based on laboratory measurements after considering the sky transmission curve, mirror reflectivity, and quantum efficiency of the detector (Mendes de Oliveira 2019).The panels above and to the right are the images of NGC 458 in the 12 filters.

Figure 2 .
Figure2.Images of 6 stellar clusters studied in this work, made from the combination of the 12 bands using the S-PLUS cloud, which can be found at https://splus.cloud/.The RGB was composed using the bands , , 0861, and  for the R canal.For the G canal, we used the , 0515, and 0660 bands.Finally, for the B canal, the , 0378, 0395, 0410, and 0430 were used.

Figure 3 .
Figure 3. Zoom of the stellar cluster NGC 121 showing that it is not possible to resolve stars in crowded core regions.

Figure 4 .
Figure 4. S-PLUS images of the u (upper left panel) and r (lower left) bands for the stellar cluster NGC 458.Red circles represent the ring used to obtain the sky flux level value, while white circles represent the aperture used to obtain the integrated flux of the cluster.The horizontal and vertical axes are the pixel positions of the image.In the right panels, we have the cumulative distribution of the flux as a function of the radius.

Figure 5 .
Figure 5. Simple stellar population models (SSPs) used in BAGPIPES (black dots).Red circles are all of our starting sample, while blue are the ones in the final sample analyzed in this work.In blue we have star clusters with  −  < −0.20, and, in red,  −  > 0.35.Green circles are stellar clusters with colors between these two values.

Figure 6 .
Figure 6.BAGPIPES fitting example for S-PLUS photometry for NGC 458 using a burst star formation history.Blue dots are the S-PLUS data with the respective errors.The shaded orange area represents the 16th and 84th percentile range for the posterior spectrum and photometry.

Figure 7 .
Figure 7. Corner plot for the BAGPIPES fitting example of the NGC 458 stellar cluster.The median, 16% and 84% values of BAGPIPES are also shown in the plot as dashed lines.

Figure 8 .Figure 9 .
Figure 8.The top panels show the comparisons between the values derived in this work and the literature values for age (left) and metallicity (right).The bottom panels are the residuals in age and metallicity between the literature and derived values, with the shaded area being the dispersion of the values.The dispersion values were 0.31 for log(age) and 0.41 dex for [Fe/H].

Figure 10 .
Figure 10.Spatial distribution of ages and metallicities (colorbars in the upper and lower panels, respectively) using BAGPIPES.Circles with no edges are stellar clusters that have values in the literature, while those with blue edges are new values.
age-metallicity relation (AMR) of our sample is shown in Figure 11.The different lines show different chemical-evolution models known from the literature: PT98 (Pagel & Tautvaisiene 1998, burst model, blue line); closed-box models (Da Costa & Hatzidimitriou 1998, orange lines); model HZ04 (Harris & Zaritsky 2004, green line), models C13-B and C13-C (red lines, Cignoni et al. 2013) are the two Bologna models; TB09-1, TB09-2 and TB09-3 models (purple lines Tsujimoto & Bekki 2009).Comparing the theoretical models, the literature values for the clusters, and our results, we can also see that the ones from our sample closely follow both the literature age-metallicity relationship and the theoretical models, but the results are better for stellar clusters with log() > 8.0.

Figure 11 .
Figure 11.AMR using BAGPIPES.In green, we have the results for all of our sample.Those with a purple outline, are clusters with known parameters in the literature.Purple squares are the literature values for the SMC clusters found in Bica et al. 2020 that are within the S-PLUS fields.Theoretical models are also present in the plot: PT98 "burst" model (blue line); closed-box models for [Fe/H]= −0.6 dex and [Fe/H]= −0.5 dex (full and dashed orange lines, respectively); the HZ04 model (green line); models C13-B and C13-C (full and dashed red lines, respectively); models TB09-1, TB09-2, and TB09-3 (full, dashed and dot-dashed purple lines, respectively).To compare with our Galaxy, we also have a sample of globular clusters from Kruĳssen et al. 2019 (black squares), a sample of open clusters from Dias et al. 2021 (gray squares), and the model for the Gaia-Sausage/Enceladus accreted by the MW from Limberg et al. 2022 (full black thick line) along with an extrapolation (dashed black thick line)

Table 1 .
Extinction Schlafly et al. 2016.ed for the 12-band filter system used by the S-PLUS, calculated using the extinction law fromSchlafly et al. 2016.

Table 2 .
List of free and fixed parameters.To the left, we have the free parameters (uniform priors), where  formed is the stellar mass formed, age is the age of the stellar population,  is the metallicity, and  is the redshift.The fixed parameters are the ionization parameter, log 10 (), and the ones related to dust attenuation modeling,   and  (both are zero because we are already derredening the photometry).

Table 3 .
Standard deviations of RA and DEC for stellar clusters divided into 5 age groups in order to verify if there is a gradient towards the center of the galaxy.

Table 4 .
Standard deviations of the RA and DEC for 3 different groups of metallicity.