Introduction

With the growth of the world population associated with contemporary industrialization, the generation of agro-industrial waste has been identified as a crucial issue that impacts the environment. Improper disposal of these unprocessed in the environment results in the accumulation of harmful organic compounds in the ecosystem, in addition to generating greenhouse gas emissions during anaerobic decomposition, posing serious risks to human health and other living beings [1]. Recently, there has been an increasing in interest in environmental preservation, food security, and sustainable resource management. Thus, aiming to conserve ecosystems, several sustainable development actions were adopted by the United Nations (UN) with the goal of halving agro-industrial waste on a global scale by 2030 [2]. Several initiatives have been undertaken to achieve sustainability, covering the reduction of this waste throughout the postharvest, processing, retail, and consumption stages. However, recently, there has been considerable interest in utilizing agro-industrial residues as inputs to obtain high-value substances, aimed for subsequent integration into the food chain [3]. Additionally, the search for polysaccharides from vegetables, such as pectin, with the aim of boosting human health, has registered growth. Therefore, innovations are required for the development of advanced recovery techniques, aiming at extracting and applying of these substances in the preparation of functional foods.

Pectin is a complex polysaccharide that mainly consists of d-galacturonic acid residues linked together by α-(1–4) glycosidic bonds [4]. Due to its numerous technological, functional, and pharmacological properties, pectin has become the most widely used functional ingredient, resulting in to a 6.5% annual growth in the global pectin market [5]. Citrus fruit peels have long been a common raw material for commercial production. Several scientific studies have reported the extraction of pectin from the peels of different species such as Allanblackia parviflora, Citrus sinensis, Citrus aurantifolia and Citrus reticulata [6,7,8]. However, considering the increasing global demand for pectin, researchers are continuously exploring other fruit genera, such as Spondias, for pectin extraction and investigating the bioactivity and yield as well as physicochemical properties for functional viability and economy [9]. The species Spondias purpurea L., commonly known as “siriguela”, originates from Central America and is distributed from Mexico to northern Peru and northeastern Brazil [10]. The average annual production of this fruit in Mexico and Brazil was approximately 73 and 4 thousand tons, respectively, and waste is generated that comprises around 70% of the fruit’s weight [11, 12].

From an industrial point of view, pectin traditionally extracted by heated water acidified with powerful mineral acids at high temperatures, and low pH levels, over a long period. However, this traditional method is time-consuming, requires a high amount of energy, exhibits reduced efficiency. Therefore, to overcome these limitations, several innovative and environmentally friendly pectin extraction techniques are under investigation, with the aim of enhancing process effectiveness and product quality [13]. Ultrasound-assisted extraction (UAE) is an innovative and promising extraction technique that aims to improve pectin yield and quality by reducing processing time, energy, and solvent consumption, as well as decreasing production costs. The UAE process involves acoustic cavitation, causing damage to plant cell walls, increasing contact between the solvent and target cell contents enhancing mass transfer, and resulting in higher pectin yields [14, 15]. Furthermore, although the use of strong mineral acids yields high amounts of pectin, these acids are also responsible for corrosion, environmental problems and significantly affect the pectin structure through disruption of the side chains. This negatively affects the physical properties and chemical and technological processes of extracted pectin [16]. Therefore, green organic acids such as citric acid have attracted increased research interest due to their environmentally friendly nature and their ability to preserve pectin properties.

The main contributions of this manuscript include the valorization of the residue from the peels of Spondias purpurea L. during processing, and assessing the potential of the extracted pectin as a food additive. Since the response surface methodology (RSM—Response Surface Methodology) has not yet been used to model pectin extraction from Spondias purpurea L. peel, in this study aims to optimize the experimental parameters by RSM. It also compares commercial pectin (CP) with pectin extracted by UAE as well as understand the combined effects of operational variables (ultrasound power, extraction temperature, sonication time, liquid/solid ratio, pH) on pectin yield. In addition to maximizing the yield and degree of esterification, the galacturonic acid content of the samples was quantified, functional properties were investigated, and the structural characterizations along with physicochemical properties were evaluated.

Experimental

Raw material

Spondias purpurea L. peels were purchased at the fruit market in the city of Teresina—PI, Brazil. The samples were dried in an oven at 45 °C for 96 h. After drying, the samples were ground using a blender and stored in a dry, dark place for 30 days at room temperature.

Reagents

All reagents used in this work were of analytical grade or higher. The reagents used were commercial citrus pectin, citric acid, galacturonic acid, β-carotene, Folin–Ciocalteu, meta-hydroxydiphenyl, sodium tetraborate, sodium carbonate, sodium hydroxide, and sulfuric acid, which were purchased from Sigma-Aldrich (Darmstadt, Germany) while ethanol and acetone were obtained from J.T.Baker® (Geel, Belgium).

Experimental design

A 25–1 fractional factorial design was applied to screen the chosen variables [hydrogen potential (pH), extraction temperature (T), extraction time (t), ratio (s/l), and power of the ultrasonic bath (Pw)] in accordance with previous studies [17, 18]. In fractional planning, the extraction yield [y(%)] was used as a response and the generator used was 12,345, where the fifth variable was obtained by multiplying variables 1, 2, 3, and 4 (25–1). All experiments were performed randomly to minimize the effect of unexplained variability in the observed responses due to systematic errors [19]. The variables were coded according to Eq. 1, where x is the coded value, Xi is the corresponding real value, X0 is the real value at the central point and \(\Delta\)X is the increment of Xi corresponding to a variation of 1 unit of x.

$$x=\frac{{X}_{i}-{X}_{0}}{\Delta X}$$
(1)

After the screening stage, only the significant variables were selected and new levels were defined to refine the extraction method using Box–Behnken Design (BBD) planning. The statistical model obtained was validated by analysis of variance (ANOVA), analysis of residual graphs, and experimental vs predicted values. The optimal conditions for each variable were evaluated using the RSM.

Furthermore, the BBD statistical design was used to study and optimize the effects of different process variables, including extraction temperature (T) (62–78 °C), extraction time (t) (20–50 min), ultrasound power (Pw) (1–5), and hydrogen potential (pH) (1.5–2.7) on pectin yield. The levels and design of the dependent and independent variables are shown in Table 1. The complete BBD design comprised 29 experimental runs, including 5 replicates at central points, to determine experimental error. All experiments were performed randomly and in triplicate to minimize unexplained variation in response factors due to systematic errors. The resulting data were fitted to a second-order polynomial model, whose Eq. 2 can be expressed as follows:

$$Y= {\beta }_{0}+ {\sum }_{i=1}^{4}{\beta }_{i}{X}_{i}+ {\sum }_{i=1}^{4}{\beta }_{ii}{X}_{ii}^{2}+{\sum }_{i=1}^{3}{\sum }_{j=i+1}^{4}{\beta }_{ij}{X}_{i}{X}_{j}+e$$
(2)

where Y represents the response variable (pectin yield), Xi, and Xj are the coded process variables; and β0, βi, βii and βij are the regression coefficients of the intercept, linear model, square model, and quadratic model, respectively. It should also be noted that the statistical significance of the variables was determined using analysis of variance (ANOVA) with a confidence level of 95%. Furthermore, the adequacy of the developed model was estimated by evaluating the lack of fit test, adjusted coefficient of determination (adj. R2), and coefficient of determination (R2) obtained by ANOVA.

Table 1 Box–Behnken planning for the optimization of ultrasound-assisted extraction of Spondias purpurea L. pectin

Ultrasound-assisted extraction (UAE)

UAE was performed with an ultrasonic bath (Sonitop 402-A, Soni-tech®, São Bernardo do Campo, SP, Brazil) with a capacity of 1.9 L (internal dimensions 15 × 13 × 10 cm).

Approximately 0.5 g of Spondias purpurea L. peel powder was mixed with a citric acid solution ratio, 1:20 w/v (Merck Chemical Co., Darmstadt, Germany) in a 50 mL polypropylene tube, and then placed in an ultrasonic bath according to the experimental design (Table 1) [18].

The acid extract was cooled to 4 °C for approximately 2 h. Then, the cold mixture was centrifuged at 3500 rpm (1090 × g) for 10 min. Ethanol (95%) was added to the pectin-containing supernatant at a 1:3 (v/v) ratio. After 2 h of rest, a pectin precipitate was obtained and centrifuged at 3500 rpm (1090 × g) for 10 min. Finally, the supernatant was discarded and the resulting material was dried in an oven at 50 °C until a constant weight was reached.

The pectin extraction efficiency was calculated using Eq. 3, where Y is the percentage of extracted pectin yield (%), mf is the amount of extracted pectin in g and mi is the initial amount of ground Spondias purpurea L. peel.

$$Y\left(\%\right)= \frac{mf}{mi} \cdot 100$$
(3)

Physicochemical characterization of pectin samples

Chemical composition

The percentages of ash, moisture and protein content for commercial pectin and pectin extracted under optimized UAE conditions were determined as described in the A.O.A.C. [20].

Degree of esterification (DE)

The degree of esterification (DE) of the pectin was analyzed using FT-IR (PerkinElmer®—Spectrum 100, London, United Kingdom). The FT-IR spectra of the samples were recorded from 400 to 4000 cm−1. The measurement resolution was 2 cm−1 and the resulting spectra were smoothed to remove noise. For this purpose, pectin samples were placed in a desiccator overnight before analysis. DE is the ratio of the number of esterified carboxyl groups to the total number of carboxyl groups present and can be calculated from the absorption intensities (band areas) at 1630 cm−1 and 1745 cm−1; corresponding to carboxyl groups not esterified with methyl groups and carboxyl groups esterified with methyl groups, respectively. The sum of the absorbance intensities of the bands at 1630 cm−1 and 1745 cm−1 corresponding to the total carboxyl groups was measured by OriginLab® software (Northampton, Massachusetts, USA). The percentage of DE was determined according to Eq. 4.

$$DE\left( \% \right) = \frac{{A_{1745} }}{{A_{1745} + A_{1630} }} \times 100$$
(4)

Equivalent weight, methoxyl content and total anhydrouronic acid content

The equivalent weight, methoxyl content (MeO), and total anhydrouronic acid (AUA) content of CP and UAE were determined by the titrimetric method [21]. For equivalent weight, pectin samples (0.2 g) were mixed with ethanol (5 mL) which was followed by the addition of sodium chloride (1 g) and distilled water (100 mL). Finally, six drops of phenol red indicator were added to the solutions and titrated with 0.1 N sodium hydroxide until a pink color appeared. The equivalent weight was then calculated using the formula in Eq. 5:

$${\text{Equivalent}}\,{\text{weight}} = \frac{pectin\,dough}{{Hydroxide\,volume\left( {mL} \right) \times hydroxide\,normality }} \times 1000$$
(5)

For the MeO content, the neutral sugars obtained from determining the equivalent weight of the pectin samples were mixed in 0.25 N sodium hydroxide (25 mL), followed by shaking the mixtures and the solutions were incubated at room temperature for 30 min. Afterwards that, 0.25 N hydrochloric acid (25 mL) was added to the solutions and titrated against 0.1 N sodium hydroxide. MeO was calculated using Eq. 6:

$${\text{Metoxil}}\,{\text{content}} = \frac{{Hydroxide\,volume\left( {mL} \right) \times hydroxide\,normality \times 31 \times 100}}{sample\,mass\left( g \right) \times 100 }$$
(6)

Finally, the total AUA of the pectin samples was calculated using the formula in Eq. 7:

$${\text{Total}}\,{\text{anhydrouronic}}\,{\text{acid}}\,{\text{content}} = \frac{{\left( {176 \times 0.1a \times 100} \right) + \left( {176 \times 0.1b \times 100} \right)}}{sample\,mass\left( g \right) \times 1000 }$$
(7)

where a = the volume of NaOH in mL obtained from the determination of the equivalent weight; and b = the volume of NaOH in mL obtained from determining the MeO content.

Color

The color of the pectin samples was determined using a calibrated Hunter colorimeter (optical sensor model D25, Hunter Associates Laboratory Inc., USA) and was expressed in terms of L * (brightness: 0 = black, 100 = white), a * (− a = green, + a = red) and b * (− b = blue, + b = yellow). Analyses were performed in triplicate.

Galactouronic acid content (GlA)

Galactouronic acid (GlA) was determined by the m-hydroxydiphenyl method [22]. Each pectin sample (200 µL) was completely mixed with 1.2 mL of 0.125 mol/L sodium tetraborate solution (in concentrated sulfuric acid) heated in a boiling bath for 5 min and subsequently cooled in an ice bath. The mixtures were added to 20 µL of 0.15 g/100 mL m-hydroxyphenyl (in 0.5 g/100 mL NaOH) and mixed. A pink color appeared within 5 min. Then, the absorbance was recorded at 530 nm using a UV–Vis spectrophotometer (Genesys 10S UV–Vis, Thermo Scientific). To verify the accuracy of the procedure, experiments were carried out using the standard addition method. Furthermore, a standard curve (y = 0.7289x + 0.0126; R2 − 0.9849) was obtained using galacturonic acid at (2–100) µg/mL.

Total phenolic content (TPC)

The content of total phenolic compounds (TPC) present in CP and UAE was determined spectrophotometrically according to the Folin–Ciocalteu method adapted with some modifications [8]. For the determination procedure, a 0.5 mL aliquot of the pectin samples was added to 250 μL of the Folin–Ciocalteu reagent and 2 mL of a 15% (m/v) sodium carbonate solution and the final volume was measured to 10 mL with deionized water. After incubating for 1 h at room temperature and protection from light, the absorbances of the samples were read at a wavelength of 745 nm on a spectrophotometer (Genesys 10S UV–Vis, Thermo Scientific). From a calibration curve prepared with a standard solution of gallic acid, with concentrations ranging from 7 to 84 µg/mL, the levels of total phenolic compounds were expressed in mg of gallic acid equivalent (GAE) per g of sample. Analyses were performed in triplicate.

DPPH elimination activity

The 1,1-diphenyl-2-picrylhydrazyl (DPPH) antioxidant activity of the pectin samples was determined following the procedure of Nakagawa et al. [23] with some modifications. Solutions (1 mL) of both pectin samples were prepared with distilled water and then mixed with 0.1 mM DPPH methanolic solution (4 mL). The solutions were carefully vortexed incubated for 30 min in the dark. Finally, the absorbance was read at 517 nm, and DPPH scavenging activity was measured using the following formula Eq. 8:

$${\text{DPPH}}\left( {\text{\% }} \right) = \frac{{A_{control} + A_{sample} }}{{A_{control} }} \times 100$$
(8)

Particle size and zeta potential

The particle size and zeta potential of the pectin samples were measured using a Zetasizer Nano ZS90 zeta potential analyzer. The 0.01% (w/v) pectin solutions were added to the loading tube and the refractive index and temperature were set at 1.33 and 25 °C, respectively [24].

Structural characterization

Scanning electron microscopy (SEM)

The morphology of the pectin samples was observed using a scanning electron microscope (SEM) system (JSM-7610 F plus, JEOL, Japan) operating at an accelerating voltage of 15 kV. Under vacuum conditions, the samples were sprayed with a thin layer of gold, and images were recorded at ×500 magnification.

Infrared spectroscopy with Fourier transform (FT-IR)

Fourier transform infrared (FT-IR) spectroscopy of CP and UAE pectin was performed using an FT-IR spectrometer (Perkin Elmer Spectrum, RX-U, FT-IR, USA) in the wavelength range of 4000–400 cm−1. Before analysis, pectin samples were mixed with KBr at a ratio of 1:100 and pressed into pellets using a press [25].

Raman spectroscopy

The Raman spectra of CP and UAE pectin were obtained using Bruker equipment (model Senterra), with an Olympus BX50 microscope, a monochromator connected to a charge-coupled device (CCD—“charge-coupled device”), and automatic resolution adjustment at 10 cm−1. A microscope made up of cylindrical lenses at ×100 magnification was used. Furthermore, the samples were analyzed at room temperature, using a 785 nm laser, under an output power of 10 mW, and an integration time of 3 s.

X-ray diffraction (XRD)

X-ray diffraction (XRD) patterns of the pectin samples were recorded using an X-ray diffractometer (PAN-analytic-X’pert PRO MRD, Almelo, Netherlands). The samples were scanned at diffraction angles (2θ) of 10–80 °C with a step size and time rate of 0.05° and 4°/min, respectively.

Functional properties of the pectin samples

Water (WHC) and oil (OHC) holding capacity

The water/oil holding capacity of the pectin samples was determined following the methods of Bayar [26], with minor modifications. Briefly, 1 g of pectin powder was mixed with 10 mL of distilled water or oil and shaken vigorously on a vortex mixer for 1 min at room temperature. Then, the mixture was centrifuged at 4000 rpm (1246 ×g) for 20 min, the supernatant was discarded and, the residue was weighed. The water and oil holding capacities are expressed as grams of water/oil retained by 1 g of pectin sample.

Emulsifying properties

The emulsion activity (EA) and emulsion stability (ES) of the pectin samples were determined according to the procedure of Asgari et al. [27]. Briefly, solutions of both pectin samples (5 mL, 0.5% w/v) were prepared, after which oil (5 mL) was added. The mixtures were then homogenized using ultrasound for 5 min and centrifuged at 4000 rpm (1246 ×g) for 5 min. The emulsion activity was calculated using the following formula in Eq. 9:

$$\mathrm{EA }\left(\mathrm{\%}\right)=\frac{emulsifying\, layer\, volume}{total\, volume\, of \,solution } \times 100$$
(9)

Moreover, the emulsion stability (ES) of the pectin samples was evaluated by storing the prepared emulsions for 1 and 30 days at room temperature and the ES was calculated using Eq. 10:

$$\mathrm{ES }\left(\mathrm{\%}\right)=\frac{Volume\, of\, remaining\, emulsifying\, layer}{initial\, volume\, of\, the\, emulsion} \times 100$$
(10)

Thermal analysis (DSC and TGA)

The thermal analysis of CP and UAE pectin was evaluated by differential scanning calorimetry (DSC) and thermogravimetric analysis (TGA) following the procedure of Khatkar [28]. For DSC analysis, a small amount of powdered sample (4 mg) was hermetically sealed in an aluminum pan and then transferred to the instrument (PerkinElmer, DSC 4000, UK). Measurements were performed at a temperature ranging from 0 to 300 °C, with a constant increase of 10 °C per minute. Furthermore, TGA measurements of pectin samples were performed using a thermogravimetric analyzer (TGA 4000, PerkinElmer, USA) under a nitrogen atmosphere in the temperature range of 50–600 °C at a heating rate of 10 °C/min.

Viscosity

The pectin samples were dissolved in distilled water at different concentrations of 1%, 3%, and 5% (w/v) and stirred at room temperature to ensure dissolution. These solutions were subjected to apparent viscosity analysis using a Modular Rheometer Compact (Anton Paar MCR 102, Graz, Austria). The apparent viscosity of the pectin samples was determined by measuring the flow curves at 25 °C at shear rates ranging from 1 to 100 s−1 using a parallel steel plate (60 mm diameter and 1 mm gap) [29].

Statistical analysis

The statistical analysis of the data and graphs was carried out using the software programs Design Expert® (version 13), Rstudio (version 2022.12.0), and Origin 17.0 (OriginLab Corporation, Northampton, USA). Tukey’s multiple comparison test was used to determine significant differences between trial responses at the 95% confidence level.

Results and discussion

Experimental data analysis

To achieve the maximum yield of pectin extracted from Spondias purpúrea L. peels, the BBD project was applied to evaluate the individual and combined effects of four independent process variables, namely, the extraction temperature (T) (62–78 °C), extraction time (t) (20–50 min), ultrasound power (Pw) (1–5), and hydrogen potential (pH) (1.5–2.7). A total of 29 sets of experiments involving various combinations of variables and the experimental and predicted values of extracted pectin are presented in Table 1. Multiple regression analysis was applied to the experimental data and a second-order polynomial equation, Eq. 11, including linear, interactive, and quadratic terms, was developed to determine the relationship between process variables and response (pectin yield).

$${\text{Y}} = - 360.16 + 7.77{\text{A}} - 0.16{\text{B}} + 13.33{\text{C}} + 87.46{\text{D}} - 0.05{\text{A}}^{2} - 0.01{\text{B}}^{2} - 1.08{\text{C}}^{2} - 18.61{\text{D}}^{2} + 0.01{\text{AB}}{-}0.01{\text{AC}}{-}0.31{\text{AD}}{-}0.04{\text{BC}} + 0.38{\text{BD}}{-}0.98{\text{CD}}$$
(11)

where A, B, C, and D, are the coded values of extraction temperature, extraction time, power, and pH, respectively and Y is the pectin yield. Analysis of variance (ANOVA) was used to evaluate the experimental results and the statistical reliability of the developed model and any differences were considered as significant at a p-value < 0.05; the results are shown in Table 2. The low p-value < 0.0001, high F value (868.86), and nonsignificant lack of fit, with a p value = 0.1344, showed that the proposed experimental model was significant and well-adjusted. Furthermore, the highest coefficient of determination (R2 = 0.9989), and adjusted R2 (R2 adj. = 0.9977) indicated the accuracy of the model in describing the relationship between variables and response.

Table 2 ANOVA table for UAE pectin

The influence of UAE variables on pectin yield

According to the developed experimental model and the ANOVA table (Table 2), all process variables, including linear, quadratic, and interactive variables, significantly affected the pectin extraction yield. For better understanding, surface plots (Fig. 1) were generated to represent the linear relationships between the independent process variables and pectin yield. As evident from Fig. 1a–c, the pectin yield increased with increasing temperature from 62 to 70 °C, but increasing the temperature from 70 to 78 °C led to a decrease in the pectin yield. This increase in pectin yield with increasing the temperature is due to swelling and cavitational effects that result in disruption of the plant cell wall, thus increasing the rate of solvent penetration and increasing the diffusivity, solubility, and release of pectin into the medium [30, 31]. However, further temperature increments potentially led degradation of the pectin chains and a reduction in the viscosity ratio and surface tension of the solvent, which caused a reduction in the mass transfer intensity, thus decreasing the pectin yield [32]. Similarly, sonication time significantly affected the pectin yield. As shown in Fig. 1a, d, the pectin yield increased up to 40 min and then decreased beyond a certain duration.

Fig. 1
figure 1

Response surfaces of the interactions between the parameters of the ultrasound-assisted extraction process of pectin from Spondias purpurea L.: a time × temperature, b power × temperature, c pH × temperature, d power × time, e pH × time, f pH × power

An increase in the wetting of plant material, achieved by extending in sonication time leads to the enlargement of pores in the cell walls, accelerating the infusion of solvent into the plant material, and thus improving the release of pectin into the external environment [33]. In contrast, prolonged exposure to ultrasound leads to enlargement and asymmetric collapse of cavitation bubbles close to the surface of the cell wall due to the generation of microjets which results in surface erosion that can cause structural damage to the polysaccharide, resulting in lower pectin yield [34]. As shown in Fig. 1b, d, and f, as the amplitude increased to level 4, the pectin yield increased linearly. It may be because at greater amplitude it causes an increase in the development and collapse of cavitation bubbles and this violent collapse of the bubbles generates shock waves and high-speed jets that increase the penetration of the solvent into the plant cell walls and the release of polysaccharides, disrupting cell walls [35]. However, a further increase in amplitude beyond level 4 reduced the pectin yield due to a reduction in cavitation activity at high bubble volume concentrations, which increased the probability of bubble collapse asymmetrically, resulting in reduced transmission. Ultrasonic energy and mass transfer rate, thus reducing pectin yield. Furthermore, high-amplitude pectin degradation is also responsible for the reduction in yield [13, 36]. Finally, the influence of pH on pectin yield is illustrated in Fig. 1c, e, and f. The results inferred that highly acidic conditions (pH 1.5–2.1) improved pectin extraction recovery due to the potential of acid to hydrolyze insoluble and bound pectin in soluble form, reducing its molecular weight and modifying its structure, thus promoting pectin extraction yield [37,38,39]. However, increasing the pH beyond 2.1 reduced the pectin yield, possibly due to the degradation of pectin into low molecular weight sugars, causing its aggregation and precipitation in the solvent, hindering pectin release [40].

Optimized experimental conditions

After nalysing the polynomial equation developed in Eq. 11, the optimal conditions extracting pectin from Spondias purpurea L. using ultrasound were obtained as follows: extraction temperature of 70 °C, sonication time of 35 min, power at level 4, and pH 1.9. Under these optimal conditions, the predicted yield obtained was 24.23%. To ensure the reliability and accuracy of the experimental model, the experiments were carried out in triplicate and the actual yield was observed to be 25.09 ± 0.12%, which was close to the predicted value. Therefore, it can be concluded that the experimental model developed was adequate and reliable for optimizing the pectin extraction process from Spondias purpurea L.

Characterization of pectin samples

Chemical composition

The moisture, ash, and protein contents of the commercial pectin (CP) and UAE samples are listed in Table 3. The moisture contents of CP and UAE were observed to be 6.11 ± 0.17% and 4.61 ± 0.23%, respectively. The moisture content of pectin is closely associated with the water content in citrus fruit peels and pectin with a high moisture content increases the possibility of microbial growth and pectinase production, thus affecting the quality of pectin [41]. According to the results, the moisture content in both pectin samples was low, which ensures safe storage and a longer shelf life. The ash contents of the pectin samples (CP and UAE) were 4.15 ± 0.05% and 3.56 ± 0.13%, respectively. It should be noted that the recommended ash content for food-grade pectin is less than 10% and the results indicate that the ash content of both pectin samples was less than the recommended value, which suggests high purity of the samples [42]. Furthermore, compared with that of commercial pectin, the ash content of UAE was lower (p = 0.001) than that of CP, revealing the high purity of pectin extracted using UAE. Furthermore, the protein content of UAE (1.76 ± 0.12%) was lower than that of commercial pectin (2.43 ± 0.63%) (p = 0.005). Although the protein content is considered an important factor affecting the technological properties of pectin, that is, a higher protein content can improve its functional properties, it has a high content of impurities in the pectin sample, which is unacceptable for use in the food industry [27]. Furthermore, considering the FAO recommendation, the protein content of pectin should not exceed 15.6%. Therefore, the lower protein content of Spondias purpurea L. pectin samples suggested that its purity should be used as a potential food ingredient. These results were comparable with previous studies in other species conducted by Kazemi et al. [37, 38], who reported similar moisture (8.29 ± 0.74 g/100 g), ash (2.41 ± 0.16 g/100 g) and protein (2.53 ± 0.38 g/100 g) contents for ultrasound-extracted eggplant peel pectin.

Table 3 Properties of Spondias purpurea L. pectin (UAE) and commercial pectin (CP)

Degree esterification (DE)

The degree of esterification (DE) is an important parameter that significantly affects the quality, functional properties, and industrial applications of extracted pectin. The DE values of CP and UAE were 51.10 ± 0.24% and 53.19 ± 0.71% (p = 0.072), respectively (Table 3), which indicated that both pectin samples were categorized as having high methoxy pectin content and that these can be used as a gelling agent for the preparation of jams, jellies and other food products that require high concentrations of sugar. This DE value for ultrasound-extracted Spondias purpurea L. pectin (UAE) can be attributed to the degradation effects of ultrasonic waves that led to deesterification and hydrolysis of the ester bonds [43]. Furthermore, the DE value of Spondias purpurea L. pectin (53.19 ± 0.71%) in this study was very close to the DE value reported for C. paradisi bark (58.78 ± 3.54%) [43] and Hylocereus polyrhizus bark (56.10%) [44], both of which are pectins extracted by ultrasound.

Equivalent weight, methoxyl content and total anhydrouronic acid content

The equivalent weight of pectin is an important parameter that affects its gel-forming capacity and indicates the amount of free and non-esterified galacturonic acid groups in its molecular chain. The equivalent weights of CP and UAE pectin were 519.87 ± 0.14 and 478.12 ± 0.27 (p = 0.021), respectively (Table 3). The equivalent weight of CP is different than that of UAE pectin, which is probably due to the degradation of linear pectin molecules due to ultrasonic vibrations, thus leading to the formation of a weaker network [45]. Similar results were obtained by Nguyen [46], who reported that the equivalent weight of commercial pectin (445.59 ± 16.49) was greater than that of pectin extracted from the bark of Hylocere usundatus (343.72 ± 15.39) using ultrasound at a temperature of 45 °C for 30 min. These differences in the equivalent weight of the pectin samples may also be due to differences in the type of plant material, extraction method, and quality of the raw material [47].

The methoxyl content of pectin is known as the total number of moles of methyl alcohol in 100 mol of galacturonic acid. It is a vital parameter that controls gel strength, gelling capacity, and gel setting time, as well as determining the structural and functional properties of pectin gels [48]. Furthermore, the methoxyl content of pectin varies between 0.2 and 12%, where a methoxyl content less than 7% is considered low methoxypectin, and a methoxyl content greater than 7% is considered high methoxypectin. The methoxyl content of pectin depends on the raw material, the type of extraction process, and the extraction conditions. As shown in Table 3, CP and UAE had methoxyl contents of 7.01 ± 0.03% and 7.23 ± 0.19% (p = 0.092), respectively, and the results indicated that both CP and UAE had high methoxypectin contents. However, the slightly greater methoxyl content in the ultrasound-extracted pectin than in the commercial pectin may be due to the effect of ultrasound power during the pectin extraction process, as it plays an important role in tissue degradation. Vegetables, thus leading to improved quality parameters of the extracted pectin. A similar trend was observed by Dranca [49], who reported higher methoxyl content for pectin extracted from Malus domesticaFalticeni’ apple pomace (4.03 ± 0.06%) by ultrasound than for commercial pectin (4.22 ± 0.06%).

The total anhydrouronic acid content is another important attribute of pectin that indicates its purity and affects its functional properties. According to Food Chemical Codex guidelines, the total anhydrouronic content in pectin should not be less than 65% for industrial application [50]. The results obtained in this study (Table 3) indicated that the total anhydrouronic acid contents of CP and UAE were 70.39 ± 0.01% and 72.85 ± 0.09% (p = 0.031), respectively, which confirmed the purity of both pectin samples. Furthermore, the total anhydrouronic acid content in UAE was greater than the anhydrouronic acid content in pectin extracted from Annona squamosa bark (70.24%) [40].

Color

Color is a crucial attribute that affects the appearance and end consumer acceptability of the formed gel as well as the final product produced. Therefore, to evaluate the color of the pectin samples, the average values of L*, a*, and b* were calculated. According to visual appearance, UAE pectin was brighter and darker than CP pectin was. This observation was confirmed by the results presented in Table 3, which revealed that the UAE values of L*, a*, and b* were 60.01 ± 0.82, 7.55 ± 0.09, and 20.77 ± 0.20, respectively, while the values of L*, a* and b* of PC were 79.32 ± 0.33, 1.53 ± 0.02 and 9.48 ± 0.18, respectively. It can be inferred from the results that the Spondias purpurea L. pectin extracted by ultrasound showed similar luminosity (L*), more redness (a*), and more yellowing (b*) than did commercial pectin. These color differences in the pectin samples were likely due to differences in the pectin extraction methods and conditions. Furthermore, efficient degradation of the plant cell wall by ultrasound leads to the dissolution of polyphenols and water-soluble pigments in the solvent and their entrapment in the pectin structure during the precipitation phase, thus resulting in dark-colored and shiny pectin [51].

Galacturonic acid (GlA)

Galacturonic acid (GalA) is the predominant building block in pectin and measurement of GalA content represents the purity of the pectin sample. Therefore, it is important to analyze the GalA content of pectin to understand its structure and potential use as a food ingredient [52]. According to the FAO/WHO and the European Commission, a pectin sample must not contain less than 65% GalA to be considered a food-grade pectin [53]. As shown in Table 3, the GalA contents in the CP and UAE groups were 89.01 ± 0.11% and 83.10 ± 0.15% (p = 0.011), respectively. The GalA value in the UAE treatment was lower than that in the CP, which was probably due to the degradation effect of ultrasonic waves on the main chains of the pectin structure [31, 54]. The GalA content pectin extracted by ultrasound in the present study was greater than that reported for pectin from C. sinensis peel (76.32 ± 1.68%) [55].

Total phenolic content (TPC)

The total phenolic content (TPC) is an important parameter of pectin that can affect its physicochemical properties, especially antioxidant activity. Therefore, the TPC of the pectin samples (CP and UAE) was determined and the results were presented in Table 3. As shown in the results, the TPC of commercial and ultrasound-extracted pectin was 26.90 ± 0.45 mg GAE/g pectin and 30.66 ± 0.02 mg GAE/g pectin (p = 0.045), respectively. This high TPC value of UAE may be due to the degradation effects of ultrasound waves on plant cell walls, leading to the coextraction of phenolic compounds in the solvent [56]. Furthermore, the lower brightness (L*) and greater redness (a*), as well as the greater degree of yellowing (b*) of UAE than of CP demonstrated the presence of phenolic compounds and pigments trapped within the pectin matrix [31]. This TPC for pectin extracted from Spondias purpurea L. bark using ultrasound was found to be greater than the TPC for pectin extracted from Helianthus annuus bark (8.11 ± 0.01 mg GAE/g) [57] and lower than that for pectin extracted from C. aurantium bark (39.95 ± 3.13 mg GAE/g) [58], both of which were extracted by ultrasound.

DPPH scavenging activity

The antioxidant activity of the pectin samples (CP and UAE) was determined using the DPPH radical scavenging method and the results are shown in Table 3. In this assay, when free radicals from DPPH are scavenged by the sample, DPPH is transformed into its nonradical form which further transforms the color of the solution from dark purple to light yellow [47]. The DPPH (%) values of PC and UAE were 64.39 ± 0.22% and 66.68 ± 0.12% (p = 0.059), respectively. The greater antioxidant activity of ultrasound-extracted Spondias purpurea L. pectin compared to that of commercial pectin is probably due to the greater TPC of the former. Furthermore, ultrasonic waves increase the DPPH activity of ultrasound-extracted pectin [25]. Similar results were observed by Kumar et al. [59], who reported a higher DPPH value for Artocarpus heterophyllus seed pectin (25.29 ± 4.03%) than for commercial citrus pectin (3.91 ± 1.43%).

Particle size and zeta potential

The particle size and zeta potential of CP and UAE are shown in Table 3. The particle size of the pectin samples was indirectly related to the average size of the polymers. In this study, the particle sizes of CP and UAE were 978.56 ± 0.53 and 716.65 ± 0.75 nm (p = 0.001), respectively. The smaller particle size of UAE compared to that of CP is due to the degradation of pectin chains due to the cavitation effect of ultrasonic waves, thus leading to smaller particles. Furthermore, Sucheta [14], reported that the large particle size of a polymer is directly related to high DE and GalA contents, which is evident in the results of present study. Furthermore, it has also been reported that the particle size of pectin affects its functional properties (emulsifying and foaming) [60].

The zeta potential of pectin represents the potential stability of a colloidal system. The zeta potential of CP was − 2.53 ± 0.26 mV, while the value of − 23.81 ± 0.04 mV (p = 0.002) was observed for UAE. The zeta potentials of both pectin samples were negative, which revealed the acidic nature of the polysaccharides. Furthermore, studies have reported that polysaccharides with smaller particle sizes have higher negative zeta potentials, which further contributes to strong electrostatic repulsion in dispersions, thus providing greater emulsion stability [61]. Furthermore, the higher DE value of pectin is responsible for the reduction in the zeta potential [29]. Therefore, it can be concluded that pectin extracted from Spondias purpurea L. by ultrasound has high potential for use as a suitable emulsifier in the food sector.

Functional properties

The functional characteristics of commercial citrus pectin (CP) and ultrasound extracted (UAE) were evaluated and the results are presented in Table 4. The water holding capacity (WHC) represents the amount of water contained in 1 g of sample. The WHC is a fundamental attribute that affects the textural, physiological, and technological properties of a variety of food products. The WHC of UAE was 2.89 ± 0.06 g/g, which was slightly lower than the WHC of commercial pectin (3.07 ± 0.12) (p = 0.058). This UAE value was greater than that of pectin from Daucus carota pomace (0.5 ± 0.01 g/g) [11] and from Ananas comosus peel (2.45 g/g) [62] extracted by ultrasound. This lower UAE WHC may be due to the degradation of the pectin chain length due to ultrasonic waves and the presence of fewer free hydroxyl groups in the pectin structure [25]. Similarly, oil holding capacity (OHC) is another significant parameter in the food processing sector and is used as a stabilizer, emulsifier, and fat replacer in fatty products. The OHC of both pectin samples (CP and UAEP) were 2.62 ± 0.01 g/g and 2.03 ± 0.05 g/g respectively. The slightly lower OHC of ultrasound-extracted Spondias purpurea L. pectin compared to that of commercial pectin is probably linked to the degree of esterification and the presence of fewer hydrophobic units in the pectin structure. The OHC of Spondias purpurea L. bark pectin extracted in present study was greater than that of Pistachia vera bark pectin (2.02 ± 0.19 g/g) [37] and Juglans regia bark pectin (1.21 ± 0.38 g/g) [27]. It can be inferred from the results that the water and oil holding properties of Spondias purpurea L. pectin extracted by ultrasound were comparable to those of commercial pectin, which suggests potential commercial application in the food sector.

Table 4 Functional properties of pectin obtained from Spondias purpurea L. by UAE and commercial pectin

Most polysaccharides are strongly hydrophilic in nature and are called nonsurfactant compounds. However, the presence of proteins in the structure of pectin significantly affects its emulsifying properties due to its hydrophilicity and hydrophobicity [57]. The emulsion activity (EA) of UAE was 32.67 ± 0.23%, which was considered lower than that of CP with an EA of 38.59 ± 0.11% (p = 0.022), which was probably due to the lower protein content of UAE. The EA achieved for pectin extracted by ultrasound from Spondias purpurea L. bark was greater than that obtained for C. aurantium bark pectin (40.7%) [63] and Opuntia ficus pectin (19.23–26.92%) [26, 64]. Furthermore, emulsion stability (ES) results showed that at similar storage times and conditions, emulsions of both pectin samples were more stable at 4 °C than at 24 °C, which was in line with previous studies [42]. The ES values of UAE at 4 °C and 24 °C were 80.02 ± 0.45% and 73.71 ± 0.31%, respectively, after day 1; and 76.12 ± 0.62% and 70.05 ± 0.19%, respectively, after 30 days. On the other hand, the ES values of CP at 4 °C and 24 °C were 78.36 ± 0.17% and 73.01 ± 0.40%, respectively, after day 1; and 75.22 ± 0.13% and 71.14 ± 0.91%, respectively, after 30 days. Therefore, the results showed that the EA of ultrasound-extracted pectin was similar to that of commercial pectin and could be used as an emulsifying agent in the food industry.

Structural characteristics

Scanning electron microscopy (SEM)

To evaluate the effect of the ultrasound extraction process on the morphology and structure of powders from raw Spondias purpurea L. shells (before treatment) and powders from treated peels (after treatment), as well as to compare the morphology of pectin extracted by ultrasound with that of commercial pectin, scanning electron microscopy (SEM) was employed. As depicted in Fig. 2a, the commercial pectin sample had a rough surface or cloudy aggregates, while the pectin structure determined by ultrasound (Fig. 2b) was more compact and had a relatively smooth surface. A similar study carried out by Kazemi [37], reported the effect of mechanical effects caused by ultrasound waves on breaking the cross-links between the pectin structure and reorganizing its matrix, thus leading to a smoother surface. Furthermore, micrographs of the raw (Fig. 2c) and treated (Fig. 2d) Spondias purpurea L. peels showed that the structure of the raw material before treatment was unchanged, uniform, dense, and compact. However, ruptured, loose, and ruptured cell wall were observed in the treated raw material due to the sudden increase in temperature and pressure during the extraction process. As a result, ultrasonic energy penetrates the plant cell wall, leading to the breakdown of plant tissue and the release of plant materials into the solvent, which results in high extraction yields. Furthermore, some hollow openings and microfractures were observed in ultrasound-treated raw materials [65].

Fig. 2
figure 2

SEM images of a commercial pectin, b Spondias purpurea L. pectin extracted by ultrasound, c Spondias purpurea L. peel powders before the ultrasound extraction process, and d Spondias purpurea L. peel powders after the ultrasound extraction process

Thermal analysis

To evaluate the thermal properties of the pectin samples and understand the changes that occur during thermal degradation of the pectin structure, DSC and TGA were employed and the thermograms are shown in Fig. 3a, b. The thermal stability of the pectin samples was further investigated by TGA, and the weight loss patterns of CP and UAE were demonstrated by TGA, as shown in Fig. 3a. According to the TGA curves, both pectin samples (CP and UAE) exhibited similar shapes and three main regions of degradation were visible at approximately 50–200 °C, 200–350 °C and 350–600 °C [66]. In the first region, a slight weight loss (approximately 10–15%) in the pectin samples was observed due to the evaporation of absorbed or free water in the samples [67]. Furthermore, it was observed that the water content of the UAE was lower than that of the CP. The second region (200–350 °C) exhibited extensive weight loss (> 50%), which corresponds to the pyrolytic decomposition of polysaccharide chains and the breaking of hydrogen bonds [66]. The third stage exceeded 350 °C and the results showed a slow weight loss of the pectin samples due to degradation of the polymer backbones and char decomposition [68]. However, more degradation of commercial pectin was observed in this region, which led to the conclusion that the thermal stability of ultrasound-extracted pectin was greater than that of commercial pectin, which was in line with the results of previous studies [41, 69].

Fig. 3
figure 3

a TGA for commercial pectin (CP) and UAE, b DSC for commercial pectin (CP) and UAE; c Infrared spectra for commercial pectin (CP) and UAE, d Raman spectrum for commercial pectin (CP) and UAE

As shown in Fig. 3b, two endothermic peaks were visible at 85 °C and 75 °C for CP and UAE, respectively. These endothermic peaks were attributed to the ability of polysaccharides to retain water and are related to the presence of hydrophilic groups in the samples [70]. A slight shift in this peak toward a lower temperature for commercial pectin was probably due to the presence of higher water content and it can be deduced that the extracted UAE samples had greater thermal stability than CP. Furthermore, second exothermic peaks were observed at 230 °C and 245 °C for UAE and CP, respectively, and these peaks were related to degradation in pectin samples with increasing temperature, and were generally correlated with the chemical profile. Notably, the UAE sample exhibited an exothermic peak at a slightly lower temperature than that of commercial pectin, which revealed that the thermal stability of UAE was greater than that of CP [70]. Similar results were obtained by Dranca & Oroian [13], who confirmed the high thermal stability of ultrasound-extracted pectin when compared to commercial pectin.

According to the abovementioned results, the ultrasound-extracted pectin from Spondias purpurea L. had good thermal stability comparable to that in previous studies. Therefore, pectins capable of resisting high temperatures may be more favored in the food industry [71]. Furthermore, UAE pectin can be used as an additive in food products, such as cakes, breads, and pastries, which can be subjected to high temperatures [66].

Raman spectroscopy and Fourier transform infrared spectroscopy

The Raman and infrared (IR) spectra of CP and UAE pectin are shown in Fig. 3c, d. The most intense Raman band, Fig. 3d, at 2940 cm−1 was attributed to the stretching of the C–H bonds of the carbons of the pyranoside ring [72]. In the IR spectra (Fig. 3c), the broad and intense O–H stretching band (3750–3100 cm−1), which was not observed in the Raman spectrum, overlapped the infrared C–H stretching band [73]. The IR spectra of CP and UAE have a smaller broad shoulder at approximately 2900–2950 cm−1, which is attributed to C–H stretching including CH, CH2, and CH3 bending vibrations [74]. This band was also absent in the corresponding Raman spectrum.

The IR bands at approximately 1740 and 1634 cm−1 for CP and UAE, respectively, were attributed to esterified carboxyl (–COOR) and ionized carboxyl (–COO–) absorptions, and the Raman band at (1740 cm−1) was attributed to the C=O stretching of COOH [75]. The Raman spectrum of CP showed two carboxylate stretching bands: a weaker asymmetric band (1607 cm−1) and a stronger symmetric band (1250 cm−1) [76].

A very strong and sharp Raman band was observed at 853 cm−1 for CP and UAE (Fig. 3d). The corresponding IR band was not found because it may be too weak and overlapped by an intense absorption at 930–1000 cm−1 (Fig. 3c) attributed to the out-of-plane vibration of OH [77]. The IR bands (Fig. 3c) in the absorption region between 950 and 1200 cm−1 may be due to vibrations related to glycosidic bonds and pyranoside rings [78]. However, some researchers have noted that this region is a fingerprint region with a specific function in characteristic groups of polysaccharides and is difficult to interpret [79].

XRD

Analysis of the XRD patterns of the samples at 2θ at approximately 20° showed a crystallographic plane for both pectins, CP and UAE (Fig. 4a). Thus, the XRD pattern obtained suggested an amorphous structure with low crystallinity for the CP and UAE pectins, but that the UAE pectins were more crystalline. Similar results were previously reported for pectin from lemon peels [80] and orange peels [58].

Fig. 4
figure 4

XRD patterns for a commercial pectin (CP) and UAE, and b flow behavior of commercial pectin (CP) and UAE at different concentrations

Rheological characterization

The viscosity curves of the solutions containing different concentrations of the CP and UAE pectins are shown in Fig. 4b. The viscosity of the CP and UAE solutions decreased with increasing shear rate. Consistent with the findings of Barbieri et al. [81], this phenomenon suggests that UAE solutions represent diluent fluids. Furthermore, all the CP and UAE solutions corresponded to non-Newtonian fluids due to the decrease in pectin intermolecular forces with increasing shear rate [77]. Furthermore, the viscosities of the CP and UAE pectin solutions were found to be concentration-dependent, and the highest viscosity was achieved at 5%. Similar results were obtained with pectin from citron peels [82]. In a previous study carried out by Sousa et al. [83], the pseudoplasticity of the solution increased when the concentration increased as a function of the increase in pectin concentration as was observed for Spondias purpurea L. pectin solutions from ultrasound-assisted extraction.

Conclusions

The effective extraction of pectin from the shells of Spondias purpurea L., through an innovative and ecologically sustainable methodology, has expanded the possibility of using this byproduct, which is commonly discarded in the environment or intended for animal feed. The use of the Box–Behnken design in the extraction process, considering four variables (temperature, time, power, and pH), resulted in a maximum yield of 24.23% under the ideal conditions of 70 °C, a power level of 4, a pH of 1.9 and a sonication time of 35 min. Additionally, compared with those of commercial pectin, the analysis of pectin extracted by ultrasound, showed high purity and significant esterification. The antioxidant and thermal properties of the ultrasound-extracted pectin where notable, while the water/oil holding and emulsification characteristics were similar in both samples. Pectin obtained by ultrasonication exhibited greater crystallinity and changes in surface morphology, indicating visible improvements in the recovery process. Based on these remarkable properties, the extracted pectin was proven to be a commercially viable food additive, and Spondias purpurea L. peels emerged as a promising source for pectin production, contributing to the mitigation of environmental pollution and generating financial benefits.