1 Introduction

Nowadays, because of the rapid population increase, high rates of urbanization, and industrialization, water contamination has become one of the most significant environmental difficulties and problems, and its existence has received significant attention from the general public and researchers. The textile and dyeing industries release dangerous effluents into the environment [1]. They are inevitably released into the environment as wastewater, which has a negative influence on human health. According to their structural characteristics, dyes can be divided into three groups according to their charge: cationic, anionic, and neutral. Methylene blue (MB) is one of the most often utilized dyes in a variety of sectors. Due to its high toxicity, methylene blue can seriously harm a person’s health, resulting in symptoms like dizziness, nausea, jaundice, chest discomfort, anemia, and even neurological injuries [2]. The removal of the organic dye contamination has been addressed using a number of physicochemical methods, including biological treatment, photocatalytic and sonocatalytic degradation, coagulation, ion exchange, ultrafiltration, and adsorption which have been employed to eliminate dyes from wastewater [3]. The most efficient and eco-friendly technology is adsorption because of its potential efficiency, excellent molecular selectivity, low energy consumption, low cost, reusability, and simplicity of operation [4]. The reduction and elimination of MB dyes from aqueous solutions have been studied using a variety of adsorbents such as activated carbon [5], carbon nanotube [6], graphene oxide [7], nanohydroxyapatite [8], zeolite [9], biomaterials [2], metal organic frameworks [10], silica [11], clays [12], and hydrogel [1]. The previous solid adsorbent is related to many drawbacks as higher cost preparation, the possibility of pore blocking, bad reusability results, limited medium applications, and physical changes after applications [13,14,15]. These disadvantages have prompted a number of researchers to investigate other accessible, low-cost materials that are equally effective to those produced chemically. As a result, the utilization of agricultural solid waste is considered as a promising solid adsorbent source. Additionally, using such environmentally favorable beginning materials may lower pollution caused by solid waste while also lowering the price of the raw materials used to make activated carbon. Fruit stones (apricot, peach, and cherry stones), nutshells (walnut, almond, and pecan shells), bagasse, rice hulls, grape seeds, data palm pits, olive waste, corncob, and other common types of these wastes are common examples. These materials are affordable and easily accessible, and minor preparation is needed. They also have an efficient adsorption for the removal of a range of pollutants besides its good reusability results [16]. Dialium guineense, often known as the “African black velvet tamarind,” is a sizable tree that may be found over most of Africa, including Chad, Central African Republic, and West Africa. One or two seeds are enclosed in a dry, brownish edible pulp by a bristle shell on Dialium guineense fruits, which are typically spherical and flattened, black in color, with a stalk that is 6 mm long [17]. Dialium guineense fruits are widely spread in the Kingdom of Saudi Arabia markets where they are imported from different places around the world. To the best of our knowledge, synthesis of modified solid adsorbents based on Dialium guineense fruit shells for adsorption of organic dyes was not studied up to now.

In the present work, two solid adsorbents were prepared from Dialium guineense fruit shells, one as the main precursor and the other chemically treated at lower temperature without consuming energy. The solid materials were characterized by different physicochemical techniques such as TGA, N2 adsorption, SEM, TEM, XRD, pHPZC, and FTIR. The adsorption efficiency for the solid prepared bioadsorbent was investigated towards the removal of methylene blue from aqueous medium under different application conditions considering kinetic and thermodynamic studies. Desorption and solid adsorbent reusability were applied to consider the sustainability of the prepared solid materials.

2 Materials and methods

2.1 Materials

Dialium guineense was purchased from the local market and its shells were washed with distilled water to remove any impurities and dried at 120 °C. The dried shells were finally ground using Retsch ZM200 titanium mill and stored in clean dry bottles as untreated sample (UD). Sodium hydroxide, hydrochloric acid, and methylene blue (> 95%) were purchased from Sigma-Aldrich Co. (St. Louis, MO, USA). All reagents were of analytical grade and were used without further treatment.

2.2 Preparation of treated Dialium guineense shells powder

The treated sample was prepared according to Eunice López-Ahumada procedure with slight modification [13]. Forty grams of the dried untreated sample (UD) was mixed with 400 mL of 0.5 mol/L sodium hydroxide and stirred for 4 h at 60 °C. The previous solution was filtered and the solid residue was added to 200 mL (1 mol/L) of hydrochloric acid and stirred for 4 h at ambient temperature. The last solution was filtered and washed several times with distilled water unti; neural filtrate followed by drying at 90 °C for overnight and stored in clean dry bottles as the treated sample (TD).

2.3 Characterization of solid adsorbents

The prepared two solid adsorbents (UD and TD) were subjected to thermogravimetric analysis using a thermal equipment (SDT Q600 V20.9 Build 20) at a flow rate of 50 mL/min for nitrogen with heating rate of 10 °C/ min at a temperature of up to 800 °C.

Using the NOVA-3200e gas sorption analyzer at − 196 °C, the average pore radius (\(\overline{r }\), nm), specific surface area (SBET, m2/g), and total pore volume (VT, cm3/g) were measured. In order to prepare the sample, 0.15 g of the sample (UD or TD) was put into a dry clean sample holder. The temperature was then raised to 120 °C, and the sample was allowed to degassing for a determined amount of time (often between 20 and 24 h) under a lowered pressure of 10–5 Torricelli.

X-ray diffraction spectra were used to examine the produced adsorbents’ crystalline characteristics. Using a D8 advance diffractometer (Bruker AXS, Germany) with a Bragg–Brentano goniometer (radius 217.5 mm), secondary beam curved graphite monochromator, and NaI scintillation detector, the diffraction patterns (Cu Kα, λ = 1.5418 Å) were captured on powdered samples. At room temperature (20 °C), the scan was performed from 10 to 70° with a counting time of 10 s/step.

Scanning electron microscopy (SEM) and transmission electron microscope (TEM) were employed for UD and TD using JEOL JSM-6510LV and JEOL-JEM-2100 models, Japan, respectively. With the aid of the dust-sprinkling apparatus “Bio-Rad Polaron,” the sample was coated with an Au layer (0.2 nm) prior to SEM analysis in order to increase its conductivity. For TEM sample preparation, 200 kV was the operating voltage while samples were subjected in ethanol for 30 min to ultrasonic and then added on a carbon-coated Cu TEM grid.

Zeta potentials for UG and TD were evaluated using the Zetasizer Nano S from Malvern Instruments in the UK to assess pHPZC.

The spectrophotometer Nicolet Impact 400 D ATR- FTIR with a ZnSe crystal was used to perform the ATR-FTIR for UD and TD before and after methylene blue adsorption. Between 4000 and 500 cm−1, transmittance percentage was measured as a function of wavenumber (cm−1) with a resolution of 8 cm−1 and 128 scans.

2.4 Methylene blue adsorption study

By shaking 50 mL of methylene blue solution with a certain concentration (500 mg/L) and 0.2 g of the solid adsorbent for 20 h at 25 °C, at shaking speed of 100 rpm, and a pH 7 value, methylene blue adsorption from the aqueous medium by UD and TD was investigated. After adsorption equilibrium, the residual MB solution was removed via centrifugation and the concentration of MB (Ce, mg/L) was measured at a wavelength of 663 nm using UV–vis spectrophotometer. qe (the adsorption capacity, mg/g) was calculated by applying the following equation.

$${q}_{e }= \frac{{C}_{o} - {C}_{e}}{\mathrm{m}} \times V$$
(1)

where Ce is the equilibrium MB concentration while Co is the starting MB concentration (mg/L), respectively. m and V are the adsorbent mass (g) and MB solution volume (L), respectively. The effects of pH (2 to 12), shaking time (up to 20 h), initial MB concentration (50 to 900 mg/L), the dose of UD and TD (1.0 to 8.0 g/L), and adsorption temperature (25, 35, and 45 °C) on methylene blue adsorption effectiveness were examined.

2.5 Adsorption isotherm, kinetic, and thermodynamic models

Different models were used to calculate the kinetic, adsorption equilibrium, and thermodynamic parameters to discuss methylene blue adsorption mechanism onto the prepared solid adsorbents.

Models such as pseudo-first order (PFO, Eq. 2), pseudo-second order (PSO, Eq. 4), and Elovich (Eq. 5) were used to explore the mechanism and rate of MB adsorption onto UD and TD [4].

$$\mathrm{ln}\left({q}_{e}- {q}_{t}\right)= \mathrm{ln}\left({q}_{e}\right)- {k}_{1}t$$
(2)
$${q}_{t} = \frac{\left({C}_{o}-{C}_{t}\right) V}{m}$$
(3)
$$\frac{t}{{q}_{t}}= \frac{1}{{k}_{2}{{q}_{e}}^{2}}+ \frac{t}{{q}_{e}}$$
(4)
$$q_t=\frac1\beta\;\mathrm l\mathrm n\propto\beta+\frac1\beta\;\mathrm l\mathrm n\;t$$
(5)

where qt and qe, respectively, are the adsorbed quantities of MB (mg/g) at time (t, h) and equilibrium. The rate constants for the PFO and PSO models, as well as the residual MB concentration at time (t, h), are, respectively, k1 (h−1), k2 (g/mg h), and Ct (mg/L). The surface covering extent and the initial rate of MB adsorption are related to β (g/mg) and α (mg/g h), respectively.

Isotherm adsorption equilibrium models were tested and applied for methylene blue adsorption using Langmuir (Eq. 6), Freundlich (Eq. 8), Temkin (Eq. 9), and Dubinin-Radushkevich (DR, Eq. 11) models and expressed as:

$$\frac{{C}_{e}}{{q}_{e}} = \frac{1}{b{q}_{m}} +\frac{{C}_{e}}{{q}_{m}}$$
(6)
$${R}_{L}= \frac{1}{1+b{C}_{o}}$$
(7)
$$\mathrm{ln\;}{q}_{e} = \mathrm{ln\;}{K}_{F} +\left(\frac{1}{n}\right) \mathrm{\;ln\;}{C}_{e}$$
(8)
$${q}_{e} =A\mathrm{\;ln\;}{K}_{T} +A\mathrm{\;ln\;}{C}_{e}$$
(9)
$$A = \frac{RT}{{b}_{T}}$$
(10)
$$\mathrm{ln\;}{q}_{e}= \mathrm{ln\;}{q}_{DR}-{K}_{DR }{\varepsilon }^{2}$$
(11)
$$\varepsilon =RT\mathrm{\;ln\;}(1+ \frac{1}{{C}_{e}})$$
(12)
$${E}_{DR} = \frac{1}{\sqrt{2{K}_{DR}}}$$
(13)

The Langmuir constant and maximum adsorption capacity are denoted by the symbols b (L/mg) and qm (mg/g), respectively. In order to determine if the MB adsorption is irreversible (RL = 0), favorable (0 < RL < 1), or unfavorable (RL > 1), the dimensionless separation constant (RL) was calculated. Freundlich constants that express the adsorption intensity and the capacity of adsorption are related to n and KF, respectively.

The adsorption heat, the absolute temperature in Kelvin, and the gas adsorption constant (8.314 J/mol.K), respectively, are represented by the constants A, T, and R. KT (L/g) and bT (J/mol) are defined as the constants of Temkin model. \({q}_{DR}\) (mg/g), ε, and KDR (mol2/kJ2) are related to the maximum adsorption capacity, Polanyi potential, and constant of DR equation, respectively. The mean free energy of methylene blue adsorption (kJ /mol) is donated by EDR and calculated by applying Eq. 13.

The following equations were used to determine adsorption thermodynamic parameters like enthalpy (ΔH°), free energy (ΔG°), and entropy (ΔS°) changes [18].

$${K}_{d}= \frac{{C}_{s}}{{C}_{e}}$$
(14)
$$\Delta G^\circ =\Delta {H}^{o}-T\Delta {S}^{o}$$
(15)
$$\mathrm{ln\;}{K}_{d}= \frac{\Delta S^\circ }{R} - \frac{\Delta H^\circ }{RT}$$
(16)

where Cs, Ce, and \({K}_{d}\) are the equilibrium concentrations of MB onto the surface of adsorbent, in bulk of solution, and distribution constant for the adsorption process, respectively. The Van’t Hoff plot (Eq. 16) enables the calculation of ∆H° (kJ/mol) and ∆S° (kJ/mol K) values.

2.6 Methylene blue desorption and reusability of TD sample

In order to study the desorption of MB, 1.0 g of the dried, methylene blue pre-loaded TD in 100 mL of distilled water, ethanol, 1.0 mol/L HCl, and acetone were added, then the mixture was stirred for 15 h at 25 °C. Following filtration, the desorbed concentration of MB was determined, and the following equation was used to determine the desorption efficiency% [19].

$$\mathrm{Desorption\;efficiency\%} = \frac{V {C}_{d} }{q m} \times 100$$
(17)

Herein, Cd refers to the equilibrium concentration of MB after desorption from the surface of TD. V and q are the volume of eluent (L) and the maximum TD adsorption capacity (mg/g), respectively, while m (g) represented the mass of TD.

After five rounds of methylene blue adsorption/desorption operations, the reusability of TD was achieved. Methylene blue adsorption was controlled by TD under 800 mg/L of MB, 7.0 g/L of adsorbent dosage, pH 7, at 25 °C, and 8 h as shaking time. Following every cycle, TD was filtered, repeatedly washed with 25 mL of 1.0 mol/L HCl to remove all of the adsorbed MB, rinsed with deionized water, and then dried at 75 °C for future reuse.

3 Results and discussion

3.1 Solid sample characterization

Figure 1a shows the thermogravimetric stability for the UD and TD samples. As can be seen, the sample’s mass declines with temperature, losing 4.7 and 6.1% of its mass for UD and TD, respectively, at 150 °C. The evaporation of both internal and externally adsorbed water molecules is responsible for the earlier detectable drop [20]. The enhanced textural porosity of TD due to treatment with sodium hydroxide and hydrochloric acid, together with its higher moisture content on TD than UD, is caused by the presence of numerous surfaces’ chemical functional groups on its surface [13]. The mass loss between 250 and 400 °C may be explained by the emission of several volatile substances as well as the breakdown of cellulose and hemicellulose into condensable vapors (acetic acid, methanol, and wood tare) and incondensable gas (CO, CO2, CH4, H2, and H2O) [21]. It is possible to attribute the weight loss between 400 and 700 °C to the onset of lignin decomposition and the removal of leftover volatiles from earlier phases. Over the temperature range of 700 °C, the mass loss for the UD and TD solid sample was 59.4 and 44.5%, respectively, indicating that a thermally stable product was produced with unchanged weight.

Fig. 1
figure 1

TGA (a), nitrogen adsorption isotherms (b), XRD (c), and zeta potential (d) for UD and TD. In addition to ATR-FTIR (e) for UD and TD before and after MB adsorption

The nitrogen adsorption/desorption isotherms for UD and TD are presented in Fig. 1b and are used to determine the BET-specific surface area, pore radius, and total pore volume, which are also displayed in Table 1. The adsorption isotherms are categorized as type II according to the IUPAC classification. The adsorption and desorption branches of the isotherm coincide as a result of the prior observation, i.e., there are no adsorption–desorption hysteresis loops that are typical of non-porous and macroporous adsorbents [22]. Total pore volume values for UD and TD were determined to be 0.0073 and 0.0107 cm3/g, respectively, while the predicted specific surface areas were found to be 8.2 and 15.4 m2/g. In comparison to UD, TD showed more advanced surface texture analysis, which may be explained by the forceful action of sodium hydroxide and hydrochloric acid in the pore-forming interaction with ash and cellulose fiber of the precursor [13].

Table 1 Nitrogen adsorption parameters and pHPZC for the investigated UD and TD

X-ray diffractograms of UT and TD are displayed in Fig. 1c. The untreated sample showed two broad peaks at 2θ values of 21.8° and 34.5°, while the treated sample showed additional peak at 16.2°. The displayed peak broadening is related to the amorphous nature of the prepared untreated precursor [23]. That broadening is decreased in the case of treated sample (TD) in comparison with the untreated one (UD) which means that treatment with NaOH and HCl slightly raises the crystallinity of sample (TD). The previous observation may be explained on the basis that the cellulose of solid materials may have inflated when the solid precursor was treated with the alkali and acid solution [24].

Scanning and transmission electron microscopy images for UD and TD solid samples are shown in Fig. 2. As presented in the SEM image of UD, the crude precursor fibers are clearly observed without any change in its structure, while the TD samples displayed a highly porous structure due to the treatment by strong acid and basic solution. The created porosity may be related to the dissolution of some ash atoms or cellulosic materials from the texture of precursor and the submerging of precursor molecules after the basic hydrolysis with sodium hydroxide. The same observation can be found in TEM images where the UD is without any structure change but the treatment with chemicals in TD leads to the destruction of precursor structure leading to a porous and cracked material which stands behind its advanced adsorption capacity [25].

Fig. 2
figure 2

SEM (a, b) and TEM (c, d) images for UD and TD, respectively

Different chemical functional groups that are present on the surface of solid adsorbents determine their capacity for adsorption and the kind of adsorbate that is attracted to the surface. The point at which the net surface charge equals zero is known as pH of point of zero charge (PZC), while at pH greater than pHPZC, the surface accesses a negative charge and increases the adsorption capacity for cationic species. Different chemical functional groups can be related to pHPZC which can be observed in Fig. 1d. The measured pHPZC for UD and TD were found to be 7.1 and 6.6, respectively. The slight decrease in pHPZC may be related to the occurrence of carboxylic and OH phenolic groups after chemical treatment to the precursor [26].

Figure 1e shows the ATR-FTIR of UD and TD before and after methylene blue adsorption from aqueous medium. The prepared biosorbents contain many chemical functional groups originated from lignin, cellulose, and hemicellulose structure. Before and after MB adsorption, TD and UD both had a peak at 3300 cm−1, which is associated to the OH group and the bonds belonging to lignin, cellulose, and hemicellulose [27]. The stretching of lignin’s CH groups is attributed to the band at 2846 cm−1 [28]. The treated sample exhibited a band at 1627 cm−1 which is related to the stretching vibration of C = O carboxylic groups originating from the precursor treatment with acid and base [29]. UD and TD samples before MB adsorption showed peaks at 1027, 2858, and 2921 cm−1 which are related to C–O–C vibration in hemicellulos and cellulose, C-H asymmetric, and symmetric stretching, respectively [13, 30, 31]. After methylene blue adsorption, the peak intensities located at 3300, 1727, 2921, and 2858 cm−1 either disappeared or reduced which may be connected to the robust interactions between MB and various groupings of UD and TD [32]. The peaks located at 1611 and 1627 cm−1 in the case of UD and TD before adsorption of MB are shifted to lower wavenumber values confirming the surface interaction with methylene blue molecules [33].

3.2 Methylene blue adsorption studies

Different application conditions were performed on methylene blue adsorption onto treated and untreated solid adsorbents to evaluate the maximum adsorption capacity and identify the mechanism of adsorption.

3.2.1 Effect of adsorbent dosage

The effect of adsorbent dosage (1.0 to 8.0 g/L) on methylene blue adsorption onto UD and TD using 50 mL of 500 mg/L MB concentration at pH 7, 25 ℃, and for 20 h of shaking time was evaluated using Eq. 1 as shown in Fig. 3a. The increment of adsorbent dosage from 1.0 to 4.0 g/L was followed by providing more accessible adsorption sites and enhancing the adsorption capacity of UD and TD from 24 to 51 mg/g and 35 to 63 mg/g, respectively. Further increase in the adsorbent dosage from 4.0 to 8.0 g/L is accompanied by a slight increase in the adsorption capacity by about 7.8 and 4.7% for UD and TD samples which may be related to the decrease in the ratio of methylene blue ions to the active sites of adsorbent materials [5]. The previous result concluded that 4.0 g/L is the suitable adsorbent dosage for MB adsorption onto the investigated solid adsorbents.

Fig. 3
figure 3

Effect of adsorbent dosage (a), pH (b), time (c), PFO (d), PSO (e), and Elovich kinetic models for MB adsorption onto UD and TD at 25 °C

3.2.2 Effect of initial solution pH

Besides textural properties and the chemical functional groups of the investigated solid adsorbents, initial pH of the adsorbate is a very important factor in determining the adsorption capacity of the removal process. The effect of pH of methylene blue solution (2–12) was investigated for the adsorption process onto UD and TD solid samples at 25 °C using 50 mL of 500 mg/L as initial concentration, after 20 h of shaking time, and 4.0 g/L as adsorbent dosage. Figure 3b displayed the effect of pH on the adsorption amount of MB on UD and TD. Increasing pH values from 2.0 to 6.8 is accompanied by an increase in the adsorption capacity from 25 to 55 and 35 to 64 mg/g in the case of UD and TD, respectively. The lower adsorption at pH values < pHPZC is related to the competition with protons present in the adsorption medium which is easily attracted to the surface of solid adsorbents than MB cations [34]. The increase in methylene blue adsorption with rising pH levels is caused by an increase in the electrostatic attraction between the negatively charged adsorbent surface and positively charged MB, as well as a decrease in the protonation of the adsorbent’s surface with rising pH levels above pHPZC (7.1 and 6.6 for UD and TD, respectively). At elevated pH values (pH > pHPZC), there is no observable increase in the adsorption efficiency which can be related to the attainment of equilibrium and no active sites are accessible [35]. pH = 7 was selected as the pH value with the maximum adsorption capacity for the removal of MB onto UD and TD.

3.2.3 Kinetic studies of MB adsorption on solid adsorbents

Figure 3c shows the effect of shaking time on the adsorption of MB onto UD and TD. Due to the presence of active surface sites on the produced samples, it was shown that the adsorption rate is particularly fast during the initial adsorption phase. After 8 h of adsorption, methylene blue adsorption increased until the equilibrium time, at which point the adsorption capacities of UD and TD increased by 10.0 and 4.5 times, respectively. The majority of the active sites on the surface being occupied and the decrease in the concentration of methylene blue in the medium, which lessens the transfer of the substrate from one medium to another by concentration gradient, are the two factors behind the decrease in adsorption rate at longer adsorption times [36].

PFO (Eq. 2), PSO (Eq. 4), and Elovich (Eq. 5) kinetic equations for UD and TD are represented in Fig. 3d–f, respectively, and the calculated parameters of the kinetic models are listed in Table 2. According to the results in Table 2, it can be seen that (i) MB adsorption onto UD and TD was not well fitted by PSO kinetic equation due to the wide range between the calculated (qexp, mg/g) and experimental (qexp, mg/g) adsorption capacity values, despite the values of R2 calculated from PSO being nearly high (0.9988 and 0.9890, in the case of UD and TD, respectively). (ii) Because of its higher R2 (0.9857 and 0.9820 for UD and TD, respectively) and the small difference in the values of qm and qexp determined by the PFO equation, the adsorption on UD and TD fitted well the PFO equation. (iii) The values of the PFO rate constant (k1, h−1) show the rate of MB adsorption onto TD > UD which is caused by the occurrence of new active groups on the treated solid sample surface [37]. (iv) The Elovich kinetic model had correlation coefficients that were greater than 0.9103, indicating strong model applicability. Additionally, the initial rates (α) of methylene blue adsorption follow the sequence TD > UD, suggesting a rise in adsorption capacity due to the higher surface area and the presence of different chemical functional active sites in the case of TD. The surface coverage by MB cations is also related by β values as presented in the table and based on the lower surface area of UD [38].

Table 2 Pseudo-first-order, pseudo-second-order, Elovich kinetic, and thermodynamic parameters for the adsorption of MB onto UD and TD at 25 °C

3.2.4 Isotherms of MB adsorption onto the prepared solid adsorbents

The effect of initial concentration on the adsorption of MB onto UD and TD was investigated using 0.2 g of the adsorbent at pH7 and after 8 h of shaking time by using different MB concentrations (50–900 mg/L) and at different application temperatures (25, 35, 45 °C). Equilibrium adsorption isotherms for UD and TD are displayed in Fig. 4a and b, while the applied linear models of Langmuir, Freundlich, Temkin, and Dubinin-Radushkevich are shown in Fig. 4c–f and Fig. 5a–d, respectively, for untreated (UD) and treated solid (TD) samples. The calculated linear parameters for the adsorption process are collected in Table 3.

Fig. 4
figure 4

Adsorption isotherm (a, b), Langmuir (c), and Freundlich (ef) linear plots for the adsorption of MB onto UD an TD, respectively at 25, 35, and 45 °C

Fig. 5
figure 5

Temkin (a, b) and Dubinin-Radushkevich (c, d) linear plot of MB adsorption onto UD and TD, respectively at 25, 35, and 45 °C

Table 3 Langmuir, Freundlich, Temkin, and Dubinin-Radushkevich parameters for MB adsorption onto UD and TD at 25, 35, and 45 °C

Figure 4a and b showed that the amount of MB adsorption significantly increased at a lower initial concentration, demonstrating that the MB dye molecules had a very high affinity for the constructed adsorbent surface, resulting in total adsorption in the dye diluted solution. Due to the fact that all of the accessible active sites were covered, adsorption remained steady at higher MB starting concentrations. The observed adsorption capacity slows down at greater concentrations of methylene blue, which may be due to the saturation of solid surface-active sites. The fact that adsorption increased along with temperature suggests that the adsorption mechanism is endothermic.

As displayed in Fig. 4c–f (Langmuir and Freundlich plots), and related parameters in Table 3, it is concluded that (i) Langmuir equations prove higher correlation coefficients at the three applied temperature (0.9989–0.9998) for MB adsorption onto UD and TD and prove the well application of Langmuir model and that confirms the monolayer adsorption process on a homogeneous surface of the solid adsorbents. The effective use of Langmuir models suggests a monolayer, homogenous adsorption, where the adsorption sites have the same energy and there are no interactions between the substrates that have been adsorbed. (ii) Treated solid sample (TD) exhibited a maximum adsorption capacity more than untreated one (UD) due to its higher surface area and the presence of more surface chemical functional groups related to the untreated sample. (iii) Adsorption capacities increase with temperature in both cases (onto UD or TD) which indicate the possibilities of endothermic nature of MB adsorption on the prepared samples. (iv) The RL values obtained from Eq. 7 based on the Langmuir constant are greater than 0.0202 and lower than unit, demonstrating the successful MB adsorption onto the investigated adsorbents [39]. (v) Langmuir constants (b, L/mg) for TD > UD indicating that the interaction between MB cations and the surface of TD is higher than that between MB and UD. Also, the interactions between MB and solid surface increase with temperature in both cases. (vi) The calculated Freundlich correlation coefficient (0.7678–0.8554) for the adsorption of MB onto either UD or TD is lower than that calculated by Langmuir models which means that Freundlich equation is not suitable to discuss the adsorption process.

Methylene blue adsorption on the synthesized UD and TD was explained by the Temkin isotherm model, which was investigated at different temperatures (25, 35, and 45 °C), as shown in Fig. 5a and b. The predicted equilibrium binding constants (KT) increased with increasing temperature, demonstrating the endothermic nature of adsorption and the enhanced adsorption at higher temperatures [40]. The higher correlation coefficient values (0.9013–0.9741) highlight the well-fitting of the Temkin adsorption isotherm model. Temkin parameters ranged from 408.72 to 548.99 J/mol (bT < 8000 J/mol), demonstrating the predominance of physical adsorption process [41]. Figure 5c and d represent the linear plots of Dubinin-Radushkevich model for MB adsorption onto UD and TD at different temperatures and the calculated parameters are listed in Table 3. In addition to the small differences (04–7.5%) in the adsorption capacities predicted by the Dubinin–Radushkevich model (qDR) and the Langmuir equation (qm), the higher regression coefficient values (R2 > 0.9199) demonstrated the application of the Dubinin–Radushkevich model. Using the mean energy values of adsorption (EDR, kJ/mol), this isotherm model is used to distinguish between the chemical and physical natures of the adsorption process. EDR levels between 8 and 16 kJ/mol are related to chemisorption to occur, whereas physical adsorption occurs when they are less than 8 kJ/mol. EDR values range from 0.055 to 0.267 kJ/mol, as shown in Table 3, demonstrating the physisorption and monolayer-multilayer coverage of MB onto the produced adsorbents at all the studied temperatures [4, 42]. The previous data suggest that MB adsorption onto UD and TD fits well the Langmuir, Temkin, and Dubinin-Radushkevich models at all the investigated temperatures.

The parameters of thermodynamic studies were calculated using Eqs. 1416 and the resulting data are collected in Table 2. Based on the displayed data, (i) the higher correlation coefficients (R2) values for the Van’t Hoff plot (0.9535 and 0.9735 for UD and TD, respectively) confirm the well-fitting of Van’t Hoff equation (Fig. 6a). (ii) The positive values of ∆H° (28.85 and 20.22 kJ/mol) prove the endothermic nature of the adsorption of methylene blue by UD and TD. (iii) The changes in entropy (∆S°) exhibited a positive value (99.0 and 74.9 J mol−1 K−1) which mean the increased randomness of MB molecules during the adsorption process at the interface displayed by solid/liquid boundary [43]. (iv) The methylene blue spontaneously and favorably adsorbs onto the produced solid adsorbents, as shown by the negative free energy values (∆G°, 0.6688–3.6076 kJ/mol) at all the examined temperatures. Also, the increase in the negative values of ∆G° and the positive values of Kd with increasing temperature revealed the enhanced adsorption at higher temperature. (v) It is known that the free energy change for physisorption is between − 20 and 0 kJ/mol, whereas chemisorption is in the range of − 80 and − 400 kJ/mol [44]. The changes in free energy values between − 0.6688 and − 3.6076 kJ/mol prove the physisorption of MB onto UD and TD.

Fig. 6
figure 6

Linear Van’t Hoff plot for MB adsorption onto UD and TD (a), MB desorption (b), solid adsorbent reusability (c) of TD at 25 °C, and the expected adsorption mechanism (d)

3.3 Desorption and recyclability of treated solid samples

Equation 17 was used to calculate D.E% (desorption efficiency) of pre-loaded methylene blue from the TD surface, which is shown in Fig. 6b. As shown in Fig. 6b, the desorption efficiency of HCl (1.0 mol/L) ˃ ethanol ˃ acetone ˃ distilled water (98.3, 25.1, 20.1, and 5.1%, respectively). Polarity of eluent, viscosity, the quantity of produced cations from the applied desorbing solution, and the solubility of MB in eluent all affect desorption efficiency values. Methylene blue molecules mostly interacted with the TD surface by a physical binding force. Because there are less positively charged protons in distilled water, ethanol, and acetone, they all showed the lowest desorption percentage [45]. The quantity of protons generated by hydrochloric acid rises in an acidic environment, boosting the desorption effectiveness of methylene blue dye. This occurs as a result of the electrostatic attraction (physical adsorption) between positively charged sites on TD and cationic MB dye. Furthermore, the strong polarity, low viscosity, and increased solubility of MB in HCl solutions are supporting the viability of its capability to desorb MB from the solid surface in an efficient manner.

After five cycles of MB adsorption/desorption process, the reusability of TD was evaluated, as shown in Fig. 6c. It is observed that TD is still an effective solid adsorbent even after five cycles of adsorption and desorption, with only a 9.1% loss in adsorption capacity. The coagulation of solid adsorbent particles, which results in a reduction in surface area, the inability of some adsorption sites to regenerate as a result of the strong connections created with the substrates, and the anticipated loss of certain surface chemical functional groups, may be the cause of the decrease in adsorption efficiency [46].

3.4 Comparison of treated solid sample with other solid adsorbents

Given the different natural adsorbents listed in Table 4 and the adsorption settings employed in each article, TD has a higher Langmuir maximum adsorption capacity (qm, mg/g) value for MB adsorption at 25 °C of 63.87 mg/g than those other natural adsorbents [3, 47,48,49,50]. In light of its relatively higher surface area (15.4 m2/g), higher total pore volume (0.0107 cm3/g), and the presence of various surface chemical functional groups, it can be concluded that TD is a suitable solid material for the removal of dyes from wastewater. Along with its excellent reusability, treated Dialium guineense fruit shells serve as a biosolid waste adsorbent and are prepared at a reduced cost level.

Table 4 Comparison of TD maximum Langmuir adsorption capacity with other adsorbents

3.5 Postulated mechanism of MB adsorption on TD sample

Several surface chemical functional groups on the treated solid adsorbent sample can interact with the molecules of MB heteroatoms (Fig. 6d). During the process of MB adsorption on TD, several interactions coexisted. Methylene blue is a cationic dye that can be applied to negatively charged surfaces and is electrostatically adsorbable [51]. A hydrogen bonding contact was created between the hydrogen from the solid adsorbent and the nitrogen from MB. As the most common type of non-electrostatic bonding, hydrogen bonds are seen in most adsorption systems [52]. Furthermore, interactions between their aromatic backbones allow methylene blue ion and TD to easily adsorb one another even though they are ideal planar molecules. The preferred attraction of MB ions by the solid adsorbent is demonstrated by the increase in MB ion randomization at close proximity to the pores of the produced solid adsorbent as shown in the textural characterization and thermodynamic parameters.

4 Conclusion

The current work demonstrates how Dialium guineense fruit shells were used as biowaste to create a new, chemically straightforward, and effective solid adsorbent. The treated sample showed acceptable surface area (15.4 m2/g), a pore radius of 1.34 nm, a pHPZC of 6.6, thermal stability that was obtained from TGA up to 250 °C which enables its adsorption application at higher temperature, and the presence of a number of chemical functional groups. For methylene blue dye, TD displayed higher Langmuir adsorption capacity that increased with temperature (63.87 mg/g at 25 °C). Kinetic and thermodynamic investigations prove the best fitting of Van’t Hoff, PFO, and Elovich models for MB adsorption onto TD with endothermic, physisorption, and spontaneous nature. TD is reusable with only 9.1% decrease in adsorption efficiency even after six cycles of adsorption and desorption process. The previous results concluded that simple chemically treated biosolid waste at a lower temperature as Dialium guineense fruit shells is a power-saving and effective method to prepare solid adsorbents for environmental treatment.