Introduction

Environmental pollution poses a significant challenge across the globe because of social, technological, and industrial growth1. Water is the fundamental necessity for the survival of all living organisms2. It is estimated that 70–80% of illnesses in developing countries are linked to water contamination, with women and children being the most affected. As water pollution continues to cause widespread health issues, it has become a critical concern that requires urgent action to address and mitigate. The industrial wastes, including both toxic inorganic and organic pollutants, extremely contribute to water pollution when released into aquatic systems. Among these pollutants, the synthetic dyes, in accordance with their widespread application in industrial manufacturing facilities, become one of the most toxic water pollutants1,3. Methylene blue dye (MB) is a synthetic, heterocyclic aromatic compound, C16H18N3SCl 319.85 g/mol (3,7-bis(dimethylamino) phenothiazine chloride tetramethylthionine chloride), and cationic chemical compound4, widely employed in various industries as a cosmetic, in paper production1, rubber, plastic, leather processing, food, and pharmaceutical manufacturing2. The contaminated MB effluent from these industries has emerged as a significant environmental issue5,6. If MB is swallowed, it may irritate the digestive tract and produce nausea and vomiting, convulsions, shortness of breath, tachyarrhythmia, and blue disease. MB was reported as resistant to biodegradation due to its stable complex aromatic molecular structure containing a chromophore and polar groups7,8. So, to remove MB from effluent before releasing it into the aquatic environment, practical and innovative technologies are needed9,10. As a result, a wide range of biological, chemical, and physical methods should be utilized, such as chemical precipitation, reverse osmosis, nanofiltration, electrocoagulation, electrodialysis, ion exchange, and photocatalysis11.

But each of these strategies has its own limitations due to economic and technical reasons12. These reasons may include high cost, chemical consumption, heavy equipment, tricky handling, design, and operation13. Alternatively, adsorption, which is a well-known separation method, revealed excellent application in MB elimination with great competence14,15 and low costs16,17. Adsorption has several advantages over previous methods of electrochemical cell1,18, including the following: (a) efficiency in removing both carbon-based and inorganic pollutants, (b) accessibility, (c) manageability and simplicity, and (d) adsorbents can be easily restored and recycled.

Several forms of adsorbents, including carbon-based and natural polymeric materials, are considered the most efficient adsorbents. Activated carbon (AC) is the main significantly effective carbonaceous adsorbent19. Agricultural residue-based ACs provide eco-friendly sustainable materials with extraordinary removal proficiency for low production costs20. Such a policy can be counted as an invasive tool to minimize pollution of solid waste produced from agricultural crop harvesting and processing20,21. Agricultural wastes that are widely applied in AC production include fruit stones, bagasse, rice hulls, kenaf core fiber, nutshells, grape seeds, corncobs, sugar beet pulp, and leaves22.

For AC production, two protocols for activation are widely adopted: Physical and chemical procedures23. In the physical protocol, the starting precursor material is carbonized at elevated temperatures ranging from 500 to 900 °C in inert conditions. Then a successive cycle of activation is conducted for the obtained activated carbon at temperatures ranging from 800 to 1000 °C in CO2 or H2O vapor conditions as oxidizing gases or a mixture of them24. Conversely, the activation via chemical protocol encompasses the impregnation of the precursor materials in a suitable agent using inert conditions. The widely applicable activating agents include H3PO4 and ZnCl2, which act as dehydrating/pyrolytic chemicals, enhancing AC yield by25. For environmental and economic considerations, H3PO4 became the most acquainted agent in AC production in the last decade26.

It has been extensively researched how AC can be utilized to eliminate MB from textile wastewater27. For instance, MB was removed from wastewater using activated carbon, with a maximum removal effectiveness of 93.8%. Also, AC was developed from organics to remove MB from wastewater with a maximum removal efficiency of 99.9%28. Although CAC, or commercial-grade AC, has been applied for dye removal, its use is limited by its high cost and lack of regeneration properties29.

Egypt is one of the leading countries in the production of sugarcane crops, with approximately 325,000 hectares of cultivated land annually in Upper Egypt, where the warm climate supports high yields. Egypt’s annual production of sugarcane is about 16 million tons/year, with the primary use being sugar extraction30. A significant by-product of sugarcane processing is the fibrous residue, referred to as sugarcane bagasse (SCB), which consists of hull and core. This residue is abundant, comprising about 30% of the processed sugarcane by weight30. The hull and core are often burned as fuel for energy production or left as waste to be dumped30. However, these wastes hold great potential as raw materials for other applications, such as the production of bio-based adsorbents, paper, and biochar, due to their high lignocellulosic content. Thus, the efficient utilization of SCB waste in Egypt presents both a challenge and an opportunity for enhancing sustainability and reducing environmental impacts in the agricultural sector.

So, the current study aims to (1) recycle SCB wastes (hull and core) in ACs production via thermo-chemical protocol using H3PO4 as an activating agent; (2) Comparing the morphological, structural, and geometrical characteristics, as well as the removal efficiency of hull-derived (AC(H)) and core-derived ACs; (3) Evaluating the impact of some physicochemical experimental parameters upon the proficiency of MB remediation by AC(H) from synthetic solutions; (4) Elaborating the behavior and mechanism of MB sorption by setting the equilibrium data to familiar kinetic and isotherm models in both linear and non-linear forms; (5) Highlighting the thermodynamics’ characteristics of MB removal by AC(H); (6) Finally, evaluating the competence of AC(H) regeneration using a suitable reagent.

Materials and methods

Materials and chemicals

Sugarcane bagasse (SCB) waste (hull and core), the solid residue that remains after juice extraction, was employed in the current study as the basic raw material for active carbon (AC) preparation. This waste contains almost 20–24% lignin and 30–50% cellulose31. Such waste was collected from a small drinking stall in Beni-Suef Governorate, Egypt. Whereas phosphoric acid (H3PO4) (85%), which was employed as the chemical activating agent for both types of SCB waste (hull and core) to prepare AC via thermochemical activation protocol, was delivered from E. Merck, Germany. Methylene Blue, MB, dye with a molar mass of 319.85 g/mol and a C16H18N3SCl formula that was employed as a cationic contaminant in the current study, was secured by Fluka, Switzerland, and employed without further purification. To prepare a 1000 mg/L stock solution of MB, 1 g of MB was dissolved in 1000 mL of distilled water (DW). From this stock, the desired diluted concentrations for the subsequent experimental work were prepared using DW. The pH of these MB solutions was adjusted to the chosen values by adding diluted droplets of HCl (0.01 M) or NaOH (0.01 M).

Preparation and chemical activation of sugarcane bagasse (SCB)

The SCB was washed with tap water to make sure that the SCB was free of any fine dust particles. Then the soft and smooth, pale fibers (hull, HSCB) were ripped off from the inner side of the SCB (core, CSCB) by hand. Those two samples were sanitized using distilled water (DW) and then placed separately in aluminum plates to be dried up at 70 °C/2 h till complete moisture removal. Each of the dried samples was shaped into small pieces using scissors (< 2 mm). Then a fixed weight of the bagasse fractions (core and hull), 10 g, was added separately to an equivalent weight of H3PO4, achieving a 1:1 w/w ratio to prepare two mixtures (hull/H3PO4 and core/H3PO4). Each mixture was liquefied with 100 mL DW and kept overnight with no interruption at ambient temperature. After excess acid decantation, the separated, soaked solid waste was washed by DW several times till pH neutralization. The separated solid fractions were then dried for 24 h at 100 °C, then weighed and calcined in open air at 700 °C (5 °C/min) for 2 h, using a programmable muffle furnace. Each prepared AC sample was gently ground using an agate mortar to get black powder (< 100 µm). The powder of each sample was stored in an airtight glass bottle as AC(H) and AC(C) to be characterized and further applied.

ACs characterization

The XRD patterns (50°–80°) of the prepared ACs (AC(H) and AC(C)) were identified using a Shimadzu XRD-7000 diffractometer with a scanning speed of 2°/min and Cu K radiation at 40 kV/20 mA. Also, the structural analysis of these ACs was assessed using FT-IR in the range of 400–4000 cm−1 (Shimadzu IR-Tracer 100 with mode of reflection at a 4 cm−1 resolution). Whereas the morphological topography of these ACs was evaluated using SEM (JEOL JSM-6610 LV, Japan). On the other hand, the Vt (pore volume), Dp (average pore diameter), and SBET (BET surface area) of the addressed ACs were estimated via Surface Area Analyzer (Nova 2000)” after degassing at 373 K/180 min. The BJH equation (Barrett–Joyner–Halenda) was employed to determine Vt and Dp of these ACs32. Oppositely, the BET equation “Brunauer–Emmett and Teller” was employed to estimate the SBET of the discussed materials33.

Batch studies

To elaborate on the ideal conditions for MB ion sorption by the prepared ACs in the batch system, the impact of several experimental factors was gauged: initial solution pH, AC mass, initial MB concentration, employed temperature, agitation time, and rate, as was illustrated in Table 1. For each experimental factor, the initial and residual MB ion concentrations in the supernatant at equilibrium were estimated using a UV–visible spectrophotometer (DR 6000) at λ “max” = 665 nm20,21,34,35. For accuracy, the experiments of each factor were conducted in triplicate, and the average result was recorded; at equilibrium, the removed amount (qe or qt, mg/g) of MB ions by the applied ACs was estimated using Eqs. (1) and (2) orderly (Table 2). Whereas the uptake capacity (R%) of MB ions by the addressed ACs was defined via Eq. (3) (Table 2)11,36.

Table 1 The applied experimental parameters and the prevailing conditions during the conduction of MB sorption experiments by the prepared ACs.
Table 2 Equilibrium equations that express the MB sorption by prepared ACs.

Adsorption kinetics

The adsorption path and mechanism, as well as the adsorption rate, were analyzed and determined by applying the linear fitting of the pseudo-first-order, pseudo-second-order, and intraparticle diffusion and Boyd models for the experimental data evaluation, as shown in Table 3.

Table 3 Sorption kinetics models for MB uptake by AC(H).

Adsorption isotherm

The equilibrium investigation was applied to indicate the interaction between the adsorbed metal ions and the used adsorbent by fitting the experimental equilibrium data to the linearized and non-linearized forms of Langmuir, Freundlich, Temkin, and Dubinin–Radushkevich (D–R) isotherm models, as shown in Table 4.

Table 4 Sorption isotherm models for MB uptake by AC(H).

Adsorption thermodynamics

The nature, spontaneity, and interior energy change of the adsorption of MB onto the AC(H) surface was determined by the evaluation of the thermodynamic parameters, including the Gibbs free energy (ΔG, kJ/mol), enthalpy (ΔH, J/mol), entropy (ΔS, J/K mol), and the activation energy (Ea) by the Van’t Hoff expression, as shown in the following equations19.

$$\therefore \Delta {\text{G}}^{\circ } = \Delta {\text{H}}^{\circ } - {\text{T}}\Delta {\text{S}}^{\circ }$$
(4)
$$\Delta {\text{G}}^{\circ } = - {\text{RT}}\ln {\text{K}}_{{\text{d}}}$$
(5)
$${\text{K}}_{{\text{d}}} = {{{\text{q}}_{{\text{e}}} } \mathord{\left/ {\vphantom {{{\text{q}}_{{\text{e}}} } {{\text{c}}_{{\text{e}}} }}} \right. \kern-0pt} {{\text{c}}_{{\text{e}}} }}$$
(6)
$$\ln {\text{K}}_{{\text{d}}} = \frac{{\Delta {\text{S}}^{\circ } }}{{\text{R}}} - \frac{{\Delta {\text{H}}^{\circ } }}{{{\text{RT}}}}$$
(7)

where R is the universal gas constant (8.314 J/mol K), T is the absolute Kelvin temperature, and Kd is the thermodynamic equilibrium constant (distribution coefficient).

Experimental design and data analysis

In this work, response surface methodology (RSM) employing the CCD technique was used to analyze data and create experiments using Create-Expert software (version 8.0.0). A statistical technique called RSM makes use of quantitative data from studies to investigate how several parameters impact the process and how different components respond when they are varied simultaneously. Contact time (A), pH (B), adsorbent dosage (C), and starting concentration (C) are the four primary independent variables that were optimized, and their effects on MB removal utilizing the AC(h) design (3-level-4-factor) were investigated in this work. Table S1 lists the levels and range of variables that influence the removal efficiency of MB. These variables include low level (− 1), central (0), and high level (+ 1). Through statistical evaluation of the P value and F-value of regression coefficients (P < 0.05), analysis of variance (ANOVA) was used to examine the impact of input factors on the response.

Furthermore, adequate accuracy (AP), adjusted coefficient of determination (R2 adj.), and coefficient of determination (R2) were used to report the model’s validity. Lastly, to illustrate the relationship between independent elements and their associated impacts on the response, three-dimensional response level diagrams have been created. As recommended by DOE (version 8.0.0) software, 29 runs (three repeats) of the tests were conducted. Table S2 displays the average of every run, except for the 6 central runs. The expected response was computed using the quadratic equation model (Eq. 8), which incorporates all interaction factors42.

$${\text{Y}} =\upbeta 0 + \sum\upbeta {\text{iXi + }}\sum {\text{i}}\sum {\text{j}}\upbeta {\text{ijXiXj}} +\upvarepsilon$$
(8)

The coefficients of the statistical model were evaluated using the quadratic model based on Eq. (3) whenever Y is the response, β0 is the constant coefficient (the intercept), βi is the linear coefficient, βij is the interaction coefficient, βii is the quadratic coefficient, xi and xj are the coded values of the variables under investigation, and e is the statistical error term.

Results and discussion

Characterization of the prepared active carbons (ACs)

The XRD patterns of the produced ACs from both the hull and core of the SCB wastes via chemo-thermal activation protocol were compiled in Fig. 1a. The broad diffraction hump that was observed in AC(H)’s pattern at 2θ ≈ 20°–30° could be attributed to γ-phase carbon of AC, suggesting a more disordered carbon structure with a higher degree of porosity43,44. Such an amorphous hump was probably inherited from the amorphous parental material, SCB, hull20,21,45,46,47. The broader peak in AC(H) implies a more developed microporous structure compared to AC(C). However, in the AC(C) pattern, such a hump was overprinted with a very sharp diffraction peak at 2θ ≈ 25.98° with d spacing 3.43 Å, such peaks due to amorphous SiO246,47,48,49. This could indeed be associated with the biogenic silica that can be encountered in a higher ratio in the core than in the hull sample of SCB50,51. Despite the higher ashing degree in AC(C), some activated carbon with developed porosity could still be formed due to phosphoric acid chemical activation. This employed acid not only facilitated the creation of pores but also the formation of some activated carbon before extensive combustion occurs, leaving behind inorganic materials (biogenic silica) as ash.

Fig. 1
figure 1

XRD patterns (a) and FT-IR spectra (b) of AC(C) and AC(H).

On the other hand, broad diffraction peaks at 2θ ≈ 42°–46° in both AC patterns in favor of AC(H), could potentially be correlated to the structural features such as turbostratic ordering or stacking of carbon layers within the activated carbon structure20,44. Furthermore, the noticeable variation in ash content in both ACs in favor of AC(C), could be attributed to variations in the composition and structure of the initial raw materials (hull and core) used for each AC production. The core of SCB might contain a higher concentration of inorganic metals, such as silica, compared to the hull. These metals contribute to the ash content after the thermal treatment. Also, the variations in the proportions of lignin, cellulose, and hemicellulose between the core and hull can affect the yield of activated carbon and ash; the core might have higher lignin content, leading to more residue and ash upon decomposition. In accordance with variation in composition and structure between hull and core, their reactivity toward phosphoric acid might differ, affecting the extent of mineral removal during activation. The less reactivity of the core retains more inorganic material and hence higher ash content after thermal treatment. Thus, it can be concluded that the played role of phosphoric acid and the employed thermal protocol upon the activation process of SCB samples into ACs is critical20. Whereas the acid not only functioned as a dehydrating factor that influenced the pyrolytic decomposition of the hull and core of the SCB samples but also hampered ash formation and increased obtained carbon in AC(H)52.

The FTIR spectra of ACs prepared from both the hull and core of SCB are depicted in Fig. 1b. For AC(H), derived from sugarcane hull, the broad band at 3400 cm−1 corresponding to O–H stretching vibrations indicates the presence of hydroxyl and/or N–H stretching vibration groups, possibly due to residual cellulose or hemicellulose53,54,55. Additionally, bands around 2923 cm−1 and 2852 cm−1 are indicative of C–H stretching in aliphatic hydrocarbons56. Whereas the prominent band at 1710 cm−1 can be ascribed to C=O stretching in carbonyl groups, likely resulting from oxidation during the activation process. Moreover, the strong band at 1630 cm−1 is most likely due to C=C stretching in aromatic rings20. On the other hand, the bands between 1536.9 and 1253.5 cm−1 were associated with aromatic C=C and C–O stretching, orderly, suggesting a more complex and developed carbon structure57. Furthermore, the band at 819.6 cm−1, indicating aromatic C–H out-of-plane bending, points to well-developed aromatic rings in AC(H). The region between 1186 and 962 cm−1 includes bands corresponding to C–O stretching, indicating the presence of oxygenated functional groups that contribute to the adsorption properties of AC(H) by providing sites for chemical interactions, such as hydrogen bonding or dipole interactions, with sorbates. These functional groups are likely remnants of the original biomass material that have undergone transformation during the activation process58. In contrast, the FT-IR spectrum of AC(C), derived from the SCB core, shows a reduced intensity of the O–H and/or N–H groups around 3400 cm−1, reflecting their lower presence, likely due to increased ashing59. Similarly, the bands at 2919.2 cm−1 and 2851.6 cm−1 correspond to C–H stretching but are less intense than in AC(H), suggesting a reduction in aliphatic hydrocarbon content. The band around 1575 cm−1 in AC(C) also indicates C=C stretching in aromatic structures, highlighting some retention of aromatic character, although less pronounced than in AC(H)20. The approximate absence of the carbonyl band at 1710 cm−1 and the reduced intensity of aromatic C=C and C–O bands imply a less developed carbon structure in AC(C), aligning with the higher ash content observed in this sample. This is supported by the prominent band at 1095 cm−1, characteristic of Si–O–Si stretching60,61, which indicates the presence of silica, likely biogenic in origin. The increased ash content in AC(C) corresponds to a higher concentration of inorganic components, such as silica, which is consistent with the XRD findings and reflects the differences in the initial composition of the sugarcane core compared to the hull.

The SEM images of AC derived from the hull of sugarcane bagasse (AC(H)) revealed several key characteristics. The morphology is notably heterogeneous, reflecting the mixed and fibrous nature of the hull material (Fig. 2a–c). The pore structure is varied, featuring a mix of micro- and mesopores with variable sizes and shapes, indicative of the less uniform pore distribution typical of hull-derived activated carbon50,55. The surface texture appears rough and inconsistent, likely due to the diverse components of the hull. Similarly, the displayed layering and wrinkles due to the arrangement of carbon atoms in sheets or layers (Fig. 2a,b) suggest the presence of semi-graphitic structures formed during the activation process, but with insufficient order and crystallinity to be traced using XRD patterns.

Fig. 2
figure 2

SEM images showing porous structure of AC(H) at different magnifications (ac).

The layering structure in the form of folded sheets which relate to the inner layer of hull bagasse provides more surface area for interactions, while the wrinkles create additional pores and voids of variable diameters within AC(H), enhancing its porosity. Conversely, AC derived from the core of SCB (AC(C)) is notably less heterogeneous in morphology with an almost smooth surface texture (Fig. 3a) compared to AC(H). This could be ascribed to the approximately homogenous nature of the precursor core material.

Fig. 3
figure 3

SEM images showing smooth morphological characteristic of AC(C) (a) with prominent presence of biogenic silica in form of droplets and spheroidal particles at different magnifications (bd).

However, the pores’ structure is a less varied mix of micro and mesopores, but smaller in pore diameter compared to those of AC(H). Additionally, the displayed layering and wrinkles are less developed as a sign of the very poor arrangement of carbon atoms in sheets or layers and hence the poor development of semi-graphitic structures during the applied activation processes (Fig. 3a). However, a prominent presence of biogenic silica in the form of droplets and spheroidal particles of various degrees of maturity and sizes was observed lining the layering structure of AC(C) (Fig. 3b–d), aligning with XRD data.

The N2 adsorption–desorption isotherms for both activated carbons, AC(C) and AC(H) reveal distinct porosity characteristics as depicted in Fig. 4a. The isotherm of AC(C) exhibits a type IV profile with a broad the hysteresis loop, indicative of mesoporous materials62. The broadening of the hysteresis loop and the overlapping of the adsorption and desorption branches suggest a complex pore structure with slit-like pores, which contributes to AC(C)’s greater total pore volume of 0.318 cm3/g and an average pore diameter of 1.50 nm (Table 3), making it suitable for adsorbing larger molecules. This wide range of pore diameters was supported by the incapability to reach N2 equilibrium status20. Conversely, the AC(H) isotherm displays characteristics of a type II isotherm with hysteresis loop of H3 (Fig. 4a), which is indicative of the presence of both microporous and mesoporous structures62,63. This suggests the existence of thin and broader slit-like mesopores, which enhance the material’s adsorption capacity64. The initial section of the isotherm at low P/P0, where adsorption and desorption branches are overlapping, suggests the presence of micropores, where adsorption occurs primarily due to monolayer coverage20. As the relative pressure increases, the isotherm transitions into a linear region with slightly broadening hysteresis loop, indicative of multilayer adsorption on the exterior surface of the pores20,21. This behavior aligns with the BET surface area of 424.332 m2/g, the total pore volume of 0.288 cm3/g, and the average pore diameter of 1.36 nm (Table 5). High BET and pore size distribution make AC(H) effective in adsorbing various molecules, particularly those that fit within the range of the presented pore sizes43,65. Despite the similar surface areas of both ACs, the differences in pore volume and average pore diameter underscore the impact of the raw material’s structural composition, core versus hull, on the final pore structure post-activation. Overall, the unique pore and surface area characteristics of both AC(C) and AC(H), suggest their potential versatility in various adsorption applications.

Fig. 4
figure 4

Nitrogen adsorption–desorption isotherms of AC(C) and AC(H) (a); Effect of pH on MB ions sorption by AC(C) and AC(H) (b) and point of zero charge of AC(C) and AC(H) (c).

Table 5 Textural parameters of the prepared ACs obtained from the nitrogen adsorption/desorption isotherms.

Batch studies

Effect of pH

Applied initial pH played an essential role in MB uptake by the prepared ACs (AC(C) and AC(H)) from synthetic solutions (Fig. 4b). It was revealed that both ACs have remarkable removal efficiency for MB ions, with some privilege of AC(H) over AC(C) (R% = 96.79–97.98% and 97.4–99.14%, orderly) all over the examined pH range, 2.0–11.0 (Table 1). However, the maximum R% was accomplished at pH 9.0 for both adsorbents (R% = 97.98 and 99.14%, respectively). Such a finding aligns with the pHpzc (point of zero charge) of both ACs (pHpzc ≈ 7.8) estimated following the proposed protocol by66 (Fig. 4c). Conversely, the least removal % for MB ions by the addressed materials was achieved at an extremely acidic medium, pH 2.0 (R% = 96.79 and 97.4%, orderly), matching with pervious investigations20,35. Beyond pH 9.0, a slight decline in MB ion removal % was noticed by both adsorbents (97.92 and 99.83% for AC(C) and AC(H), consecutively), implying that equilibrium was attained34. At pH < pHPZC, the surfaces of ACs become steadily protonated with medium acidity rising. This resulted in an invasive repulsive reaction among the + ve MB ions and oxygen/nitrogen groups of the employed ACs. Conversely, at pH > pHPZC, the domination of − ve charges upon the surfaces of ACs due to deprotonation processes triggers the hydrolyzed species of MB+ ions to be attracted by these sites through electrostatic mechanism67,68. This highlights the effective role of electrostatic forces in remediating MB ions out of solutions via employed ACs especially at pH > pHPZC69.

The remarkable removal percentage of MB ions at the prevailing acidic conditions (acidic medium, pH 2.0–6.0), in spite of the violent H+ ion competition by both ACs, signifies that non-hydrophobic forces (i.e., electrostatic attraction) couldn’t be considered as the only driving mechanism for MB ions; other forces can be involved70. These hydrophobic forces (H-bonding) probably performed an essential part in the MB sorption by the studied materials35,71. The inherited hydrophobicity of these ACs from their organic contents is the probable source of such forces71,72. These hydrogen bonding connections can be defined as: (1) Yoshida and (2) dipole–dipole35,73. The interconnection among nitrogen/oxygen of MB ions (H-acceptor) with the available H (H-donor) of the OH groups upon the surfaces of the addressed ACs expresses the 1st H-bonding sort35,73. Conversely, the bonding between MB aromatic rings with OH groups of the addressed ACs signifies the 2nd H-bonding sort35,70. In light of the pH experimental work and the obtained geometrical data, XRD, and FT-IR results of the investigated ACs, pH 9.0 and AC(H) were selected for removal of MB ions from synthetic solutions in the upcoming experimental work (Table 1).

Effect of contact time

The remediation of MB ions from synthetic solution at variable retention time (5–120 min) by AC(H), keeping the other experimental parameters constant, was found to be a time-dependent procedure (Fig. 5a, Table 1). This was accentuated through the very rapid remediation of MB ions at times ranging from 5 to 15 min (293.7–305.2 mg/g, orderly)74, aligning with previous investigations35. Such sorption behavior was ascribed to the approachability of vacant deprotonated groups on the AC(H) surface with high affinity for MB ions75. Conversely, at equilibrium time 15 > t ≤ 60 min, the remediation rate of MB from standard solutions was decelerated (qt ≈ 305.2–312.4 mg/g). Such an attitude could be linked to the drop in the accessible unoccupied sites on the AC(H) surface with time progress (Fig. 5a). Further than the equilibrium time of 60 min, a trivial change in the remediated MB ions by the addressed AC (qt ≈ 312.3 mg/g) was observed. Accordingly, such adequate equilibrium presents AC(H) as a favorable material for MB removal via the sorption process of a chemical nature. Hence, 60 min was assigned as MB sorption equilibrium time by AC(H) in the succeeding experimental work (Table 1).

Fig. 5
figure 5

Effect of retention time, dose, concentration and rpm on MB ions sorption by AC(H) (ad respectively).

Effect AC(H) mass

The remediation of MB ions using variable masses of the prepared AC(H) (2–10 mg) was thoroughly investigated, maintaining the other employed parameters fixed (Fig. 5b, Table 1). It was revealed that the increase in the employed mass of AC(H) from 2 to 4 mg was coupled with a noticeable development in MB removal % from 86.3 to 99.2%, orderly. However, a further rise in the employed dose from 6 to 8 mg was supplemented by a marginal increase in R% from 99.6 to 99.8%, implying the attainment of equilibrium status20. But the utilization of 10 mg of AC(H) was enough to achieve a complete MB removal with R% 100%. This was ascribed to the huge availability of free deprotonated sites (N- and O-holding groups) on AC(H) with high affinity toward MB ions76,77.

Effect of initial concentration

The applied initial concentration of sorbate has a critical impact upon the sorption process and consequently the R% of the investigated material34. To configure this impact, numerous initial concentrations of MB sorbate (10–70 mg/L) were utilized, preserving the constancy of the other involved experimental parameters (Fig. 5c, Table 1). With raising MB concentration from 10 to 60 mg/L, the sorbed amount (qe) of MB ions was steadily improved from 61.3 to 332.6 mg/g, successively, per employed dose of AC(H). Such remarkable development in the absorbed amount of MB ions could be tied with the ascending rate of MB ions collision with the available free sites on the AC surface20,35. The acceleration in the rate of collision among the MB ions at higher initial concentration enforces these ions toward the active sites upon adsorbent’s surface, facilitating their attraction and remediation by AC(H)78. However, further progress in the employed initial concentration beyond 60 mg/L (i.e. 70 mg/L) was accompanied by marginal change in the removed amount of MB ions (qe ≈ 330.1), signifying equilibrium status. This can be justified by the unavailability of free active sites on the AC(H) surface (i.e. sites becoming saturated) to be involved in the sorption process of MB ions, aligning with several reported data20,35.

Effect of agitation rate

To illustrate the critical role of the applied agitation speed upon the sorption process of MB ions43,79 by the investigated AC(H), various agitation rates (50–250 rpm) were cautiously examined, maintaining the other experimental factors constant (Fig. 5d, Table 1). The progressive increase in the employed agitation speed from 50 to 200 rpm was coupled with an appreciable improvement in the MB R% from 92.48 to 98% (Fig. 5d). However, further progress in the employed agitation speed to 250 rpm was accompanied by marginal improvement in the achieved MB R% (98.4%). This signifies that 200 rpm was enough rate to achieve equilibrium status for MB remediation by the investigated AC(H). So, this agitation rate was utilized in conducting the other experimental investigations.

Kinetics investigations

To spell out the mechanism of MB ion sorption by the investigated AC(H), three of the most widely applicable equations in this field were employed: pseudo-1st order (PFO), pseudo-2nd order (PSO), and intra-particle diffusion. The linear and non-linear mathematical forms of both PFO37 and PSO38 models were employed (Table 4). Whereas the linear expression of the IPD80 was applied in the current study, using a t0.5 vs. qt plot (Fig. 6d, Table 6). To determine PFO and PSO parameters for the linear equations, t vs. ln(qe − qt) and t vs. t/qt plots were employed, orderly (Fig. 6a,b). While the fitting to the non-linear curve t vs. qt (Fig. 6c) was utilized to define the parameters of the non-linear expressions of these equations by the means of Microsoft Excel Solver Tool35.

Fig. 6
figure 6

Linear and non-linear plots of PFO and PSO (ac), orderly, as well as IPD (d) kinetic models for MB sorption by AC(H).

Table 6 Kinetic parameters of the MB sorption by AC(H).

In light of R2 (regression determination coefficient) outcomes, it was revealed that the sorption process of MB by AC(H) was justified by PSO, in both linear and non-linear forms, in a more fluent way than PFO (Fig. 6a,c). This implies that during the MB sorption process by AC(H), chemisorption may be the rate-driving force43,81. Such a conclusion was based on the astonishing R2 for both linear and non-linear regression fitting of PSO (R2 = 1 and 0.9998, orderly) that exceeded those of the PFO equation (R2 = 0.36 and 0.998, orderly), especially that of the linear expression34. This was also enforced by the identical matching among the experimental (qeexp = 312.4 mg/g) and calculated qe values (qecal = 312.5 and 312.36 mg/g) that were derived from linear and non-linear regressions, successively (Table 5)20. Such matching was not achieved by the PFO, especially the linear regression fitting (qecal = 10.72 and 308.55 mg/g for linear and non-linear mathematical expressions, respectively) (Table 5).

Furthermore, to elaborate on the nature of MB ion diffusion from the synthetic solution toward the AC(H) surface, the IPD model was employed. The obtained graphical presentation of the IPD model was constructed of 3 different steps, indicating its multilinearity and deviation from the point of origin (Fig. 6d). Thus, intra-particle diffusion was not the main diffusion type in MB sorption process68. However, several types of diffusions may be included82. The 1st step (steep section at time interval 0–15 min of contact time) of the multi-linear plot expresses that boundary layer diffusion or exterior mass transfer was the main diffusion process that caused a very fast MB sorption by the de-protonated sites on the AC(H) surface20,83. As the sorbent material molecules diffuse from the solution, they move toward the material’s outside surface under investigation84,85. This very rapid sorption process was ascribed to the plentiful unoccupied groups on the AC(H) surface and the higher concentration of MB ion in the solution at such contact time86. Oppositely, the 2nd gently inclined step at time interval ≥ 15 t ≤ 60 min, whereby the molecules penetrate the materials’ pores84,85, expresses the domination of intra-particle diffusion during the gradual sorption process of MB ions by the active functional groups of the investigated AC(H)75. Meanwhile, the boundary diffusion layer thickness reflected by the high C value (297.91 mg/g) demonstrates the efficient participation of the AC(H) surface in MB removal. At such time intervals, the deceleration in the MB sorption process can be linked to the decline in the number of vacant binding groups on the AC(H) surface and the reduction in the MB ion concentration in the solution with time, as well as the longer diffusion pathway of MB ions into the inner surface and pores of40,41,87 AC(H)20,86. This was followed by the plateau stage (3rd step beyond 60 min of contact time), expressing nearly a fixed rate of MB sorption by AC(H) due to equilibrium attainment88. As the boundary layer value rises across the stages, indicating an increase in the molecules adsorbed on the material’s surface, the kid values decrease throughout the stages, corresponding to the adsorption process gradually slowing down84,85.

Therefore, the 2nd step of this multi-linear plot was selected to determine IPD parameters, KP (297.91 mg/g min0.5) and C and R2 (0.918) (Table 6).

Isotherm investigations

To elaborate the interaction nature of the investigated MB sorbate and the binding sites of the AC(H), the linear and non-linear mathematical expressions for three of the widely applicable isotherm models, Langmuir, Freundlich, and Temkin, were employed (Table 7). From the linear expressions of these models, these models’ parameters were estimated using ce vs. ce/qe, log ce vs. log qe, ln ce vs. qe and ε plots, orderly (Fig. 7a–d, Table 7). Furthermore, to estimate the parameters of the nonlinear expressions of these equations, ce vs. qe nonlinear plot was employed, using the Solver tool of Microsoft Excel (Fig. 7e, Table 7). Langmuir equation presumes a monolayer sorption process of the sorbate ions form the solution via distinct active groups on the adsorbent surface with iso-energetic power35,89,90. Conversely, Freundlich pretends to be the heterogeneous multilayer sorption theory of sorbate ions upon adsorbent surface by aniso-energetic functional groups91.

Table 7 The isotherm parameters of the MB adsorption by AC(H).
Fig. 7
figure 7

Linear (ad) and non-linear (e) plots of Langmuir, Freundlich, Temkin and DR.

Unlike the Langmuir and Freundlich equations, Temkin equation accounts specifically for the indirect sorbate-sorbate interactions effects. It also points toward the fact that the sorption heat declines linearly instead of logarithmically with coverage, implying that as more sorbate ions are absorbed, the energy required for further sorption declines86. The DR isotherm is an empirical isotherm model that describes the degree of surface covering features and the adsorption mechanism with Gaussian energy distribution. Experimental data was further confirmed by distinguishing between chemical and physical adsorption of adsorbents using the DR model. Chemisorption was suggested by mean free energy (E) more than 8.00 kJ/mol. The preponderance of chemisorption is further supported by the activation energy (EDR) of 550.8 and 2500 J/mol in non-linear and linear, respectively, which suggests that the MB and the functional groups in the sorbent material have formed chemical bonds.

Considering the determination coefficient (R2) results of the three employed equations in both modes, linear and non-linear forms, Langmuir (R2, 0.992 and 0.973, orderly) justified MB sorption data by the investigated AC(H) in sufficient way than Temkin (R2, 0.917 and 0.961, orderly) and Freundlich (R2, 0.900 and 0.929, orderly) models. This implies that the sorption process of MB ions had a homogeneous nature. This nature was expressed by the formulation of singular-layer of MB ions through the attraction forces of iso-energetic binding groups on AC(H) surface20,69. Similarly, estimated RL (0.018–0.114) using the equation compiled in Table 639, that lies within the limit 0 < RL < 1, indicates favorable sorption process and confirms the Langmuir pertinency to elucidate clearly the sorption process of MB ions by AC(H)35.

Furthermore, the expectational qmax (357.41 and 389.4 mg/g from linear and non-linear equations, respectively) for the MB sorption process at equilibrium aligns with the high SBET and unique porous structure of the investigated AC(H) (Table 3). It also designates the extreme affinity of the deprotonated − ve functional groups on the AC(H) surface toward the MB ions20,92.

For comparison, the displayed qmax of the investigated AC(H), was compiled with those of some other adsorbents of previous studies that were used also for MB remediation (Table 8). In the light of such comparison, AC(H) may be designated as a sustainable, cost-wise, and competent adsorbent for MB remediation on an industrial scale.

Table 8 Adsorption capacity of MB by some natural, modified and synthetic materials in comparison with the AC(H) of the present study: qmax obtained from the Langmuir constant.

Thermodynamic investigations

Temperature performances a vital role in the sorption processes of certain sorbate by specific adsorbent as it controls both the capacity and the rate of sorption. The temperature manipulation in the kinetic energy of pollutant molecules, their movement in solution and hence solid–liquid interface, justifies such critical impact of temperature on sorption capacity and rate of sorption86.

Also, temperature can modify the surface characteristics of the employed adsorbent, such as the availability and activity of functional groups, which in turn affects the sorption efficiency. For instance, the dissociation or association of surface groups can be temperature dependent. Therefore, configuring the vital role of temperature not only allows for better optimization of sorption systems, but also can improve sorption efficiency, selectivity, and the operational life of the adsorbent35. In this context, the removal% profile of MB ions from synthetic solutions at different temperatures (291–328 K) was cautiously studied (Fig. 8a, Table 1). The MB removal% by AC(H) was relatively declined at temperature interval 291–313 K, with values ranging from 96.7 to 91.92%. This indicates that the MB sorption process is highly effective within this temperature range, likely due to optimal interactions between the MB ions and the binding groups on the AC(H) surface. However, the slight reduction in removal% suggests that the MB sorption process is not significantly affected by temperature variations within this range, possibly indicating a low activation energy for the sorption process. Conversely, a sharp decline in MB removal% was observed as the temperature increased > 313 K, dropping to around 35% (Fig. 8a). This drastic decline implies that the MB sorption by AC(H) is an exothermic process86 unlike several reported data34,35. As the temperature rises, the shifting in equilibrium may lead to this decline in sorption capacity as the system favors desorption over adsorption. This sensitivity to temperature variation consists of the exothermic nature of many sorption processes where higher temperatures reduce the interaction between the sorbate and the adsorbent, possibly due to increased kinetic energy leading to desorption of previously adsorbed MB molecules86. According to Le Chatelier’s assumption, temperature increase shifts the equilibrium to favor desorption. The stabilization of removal% around 35% beyond 320 K indicates that the sorption sites of AC(H) are no longer as effective at higher temperatures. This could also imply that some structural changes of AC(H) and/or MB might occur at these elevated temperatures, further reducing the R%86,101. For better conceptualization of the close relation between the prevailing solution temperature and MB sorption process by AC(H). The plot of ln Kd vs. 1/T (Fig. 8b) is a fundamental tool in understanding the thermodynamics of the MB sorption process by AC(H). In this context, qe expresses the amount MB ions absorbed at equilibrium, whereas ce is the concentration of dye at equilibrium, and T is the prevailing temperature in Kelvin. The linearity displayed by such plot confirms that the MB sorption process by the addressed AC(H) obeys Van’t Hoff equation that links the constants of sorption equilibrium to temperature. Intercept and slope of Van’t Hoff plot (Fig. 8b), were employed to determine the values of ΔS° and ΔH°, orderly (Table 9). The negative ΔH° value (− 83.38 kJ/mol) suggests that the MB sorption process is exothermic86. Similarly, the − ve ΔS° value (− 0.256 kJ/mol K), suggests that MB sorption process results in a decline in the randomness/disorder at the liquid–solid interface (i.e., the system becomes more ordered)34. This improvement in system order was probably correlated with the alignment of MB ions upon AC(H) surface, matching with the above-mentioned homogeneous monolayer sorption of Langmuir via isoenergetic sites. Moreover, the negativity of ΔS° value also implies that MB sorption process may involve a more structured interaction with AC(H), indicating a drop in the overall entropy of the system.

Fig. 8
figure 8

Effect of temperature on MB removal by AC(H) (a); Van’t Hoff plot (b); and Reusability test of MB sorption by AC(H) (c).

Table 9 Thermodynamic parameters of MB sorption process by AC(H).

Regarding ΔG° outcomes for all the investigated temperatures (Table 9), the − ve values at lower temperatures imply that the MB sorption process by AC(H) is spontaneous and thermodynamically favorable34,86,91. However, as the temperature increases, ΔG° approaches zero and eventually becomes positive (0.588 kJ/mol at 328 K), demonstrating that the process becomes less spontaneous at higher temperatures; positive ΔG° value, indicates non-spontaneous sorption process. This shift reflects the exothermic manners of the sorption process, where the driving forces decrease with increasing temperature, ultimately leading to a less favorable sorption at higher temperatures. The ΔG° range of values that lies approximately between 0 and − 20 kJ/mol, except for 328 K, implies that the mechanism of MB sorption process was physisorption, primarily due to weak Van Der Waals forces or electrostatic interactions86. As well, this ΔG° range indeed supports the idea that the sorption of MB on AC(H) is primarily driven by π–π interactions and hydrogen bonds86. These interactions are consistent with the observed thermodynamic properties, indicating a strong but reversible process that aligns with physical sorption enhanced by specific, non-covalent interactions.

The possible number of adsorption–desorption cycles of the regenerated AC(H) was recorded (Fig. 8c) as reusability test. It was revealed that the investigated AC(H) retains a high uptake competence, where the MB R% still surpassed 70% after four consecutive cycles before the noticeable decline to 38.9% at the 5th cycle. This exhibits that the AC(H) can be counted as cost-effective and recyclable adsorbent for the MB remediation102.

Process analysis and modeling of the MB removal

Multiple regression analysis was utilized to examine the association between the response value and four parameters: the response time, adsorbent dosage, initial pH, and initial MB concentration. Table 4 provides an overview of the analysis of variance (ANOVA) results. pH, contact time, beginning dye concentration, and adsorbent dosage all showed a favorable impact on the removal effectiveness of MB, according to the analysis of the F and P values of the variables examined in this study. Furthermore, AC, BD, AD, and CD all had P values below 0.05, indicating a significant impact on MB sorption. The first dye concentration and adsorbent dosage have the biggest impact on dye removal.

A strong correlation between the predicted and experiment results is confirmed by the adjusted R2 and correlation coefficient (R2) for the MB removal, which are 0.978 and 0.9663, respectively.

However, the model was significant for MB removal, as indicated by the Model F-value (180.84) whereas it is recorded 58.5103,104. Prob > F values below 0.05 are interpreted as indicating that the model terms were significant, whilst values over 0.05 suggest that the model terms are not. The model’s sufficiency is confirmed by the non-significant absence of ft value 6.54. Signal to noise ratio value of 4 or higher is typically considered needed for adequate precision103 whereas it is recorded 3.53103. The model developed in this work may be used to explore the design space since the achieved appropriate precision for the deterioration of MB was 44.539, whereas it recorded 29.69653103, which verified an adequate signal (Eq. 8). Y = 92.14 + 4.32 A + 3.98 B + 6.87 C + 2.62 AB + 2.93 AC − 0.1245 BC − 2.14 A2 − 2.22 B2 − 4.73 C2.

Figure 9 displays the AC(H) elliptical response surface plot. Dosage and duration of contact for the elimination of MB sorption by AC(H). The effectiveness of dye removal and contact time with RPM were shown to be significantly impacted by the interaction between dosage and RPM. The percentage of dye elimination rose when the contact duration was extended from 5 to 120 min. Near the response surface’s center points, maximum removal was achieved. At a dose of 10 mg and a duration of 120 min, respectively, a maximum MB sorption of 99% was anticipated; contact lasted 90 min.

Fig. 9
figure 9

(a) 2D response surface and (b) 3D contour plots show the effect of AC(H) dose on shaking speed; (c) 2D response surface and (d) 3D contour plots AC(H) dose and contact time 2D response surface and (d) 3D contour plots AC(H) dose and shaking speed on the removal of MB (%).

Within the experimental parameter range, Design Expert software recommended 17 numerical options for the highest dye removal at the 99% desirability level. Under the following conditions, the proposed model’s numerical solution projected the maximum dye removal (99%): 200 RPM, 90 min of contact time, and a dose of 10 mg of adsorbent.

Regeneration investigations

The competence of sorbent materials to be regenerated and recycled several times is an important aspect as it affects production expenses34. The regeneration of the spent AC(H) was carried out using HCl (5%) solution, invasive distilled water washing and oven-drying at 70 °C.

Cost analysis

The economic viability of an adsorbent plays a crucial role in determining its practical applicability for wastewater treatment. The total preparation cost comprises expenditures on energy consumption and chemical inputs. As summarized in Table 10, the total cost of producing 1.0 g of AC(H) is estimated at 0.02 USD.

Table 10 Cost analysis of the synthesized composite material.

Future study

Future research should concentrate on increasing the preparation of AC(H) for continuous-flow treatment systems in order to more accurately replicate industrial settings, building on the encouraging findings of this study. Its field application will be further confirmed by examining its adsorption behavior in actual wastewater matrices that contain organics, heavy metals, or mixed colors. Sustainability can also be improved by investigating green regeneration techniques (such as solar-assisted desorption or microwave). To increase selectivity for particular contaminants, AC(H) surface modification or functionalization may also be investigated. Finally, employing this biosorbent in hybrid treatment systems (such as AOPs + adsorption) could pave the way for extremely effective and reasonably priced wastewater cleanup.

Conclusions

On the light of the present work outputs, the following deductions can be represented; The malignant environmental impact of SCB wastes can be eliminated through their conversion into sustainable and cost-wise ACs via thermo-chemical protocol (H3PO4/SCB, 1:1 w/w ratio at 700 °C/2 h). The produced ACs exhibited distinct structural and textural characteristics, with the hull-derived AC (AC(H)) showing a more developed micro/meso-porous structure and higher SBET (424.332 m2/g) compared to the core-derived AC (AC(C), SBET = 423.792 m2/g). The appreciable presence of biogenic silica in the form of droplets and spheroidal particles of various degrees of maturity and sizes in AC(C), indicates a higher ash content in this product that can be correlated to the noticeable inorganic content in the precursor core. This was supported by the prominent existence of Si–O–Si group at 1095 cm−1 absorption band in AC(C) spectra. The MB sorption process by AC(H) was a pH/time liable practise; the maximum R% was accomplished at pH 9.0 and 60 min as equilibrium time. The kinetics of MB sorption onto AC(H) were expressed well by PSO equation, indicating that chemisorption was the inspiring mechanism. This was enforced by the very close agreement between the linear and nonlinear regression analyses (R2 > 0.999) and the astonishing coincidence between the experimental (qe exp. = 312.4 mg/g) and theoretical qe values (qe calc. = 312.5 and 312.36 mg/g for linear and non-linear regressions, orderly). Several intervening diffusion styles including IDP can be counted as the inspiring step in MB sorption process upon AC(H) surface. Linear and nonlinear isotherms demonstrated that MB sorption data were elucidated in a fluent way using Langmuir equations, with very high R2 values > 0.97 in both regression modes than those of Freundlich and Temkin equations. This supports the homogenous accumulation assumption of MB ions as a monolayer via N-and O-bearing iso-energetic functional groups on the AC(H) surface. Thermodynamic parameters, ΔH°, ΔS°, and ΔG°, verified the spontaneous and exothermic style of MB sorption process by AC(H) at 291–323 K; the sorption process becomes less spontaneous at higher temperatures of this range. Beyond this temperature range (> 323 K), the positive ΔG° value (0.588 kJ/mol at 328 K), indicates a non-spontaneous MB sorption process; the driving forces decrease with increasing temperature, ultimately leading to a less favorable sorption at higher temperatures. A strong correlation between the predicted and experiment results is confirmed by the adjusted R2 and correlation coefficient (R2) for the MB removal, which are 0.978 and 0.9663, respectively.

Regeneration investigations disclosed that spent AC(H) could be recycled till the 4th cycle (R% > 70%) before the appreciable decline in its removal efficiency. Finally, AC(H) can be classified as a long-term sustainable solution for SCB wastes elimination and as an eco-friendly cost-wise alternative to commercially activated carbons that used in thiazine dyes remediation form wastewater.

With the first-ever utilization of sugarcane bagasse hull and core, this study presents a novel method for creating tailored activated carbon that outperforms several current biomass-based adsorbents in terms of methylene blue adsorption capacity, reaching up to 357.14 and 389.4 mg/g) in linear and non-linear modes, respectively. The study further distinguishes itself by utilizing Design Expert software to combine adsorption isotherms, kinetics, and thermodynamic studies with ANOVA-based optimization—a technique that is rarely used in similar work. An effective and sustainable adsorbent is created by the economically and environmentally sustainable activation process, which uses easily accessible agricultural waste105. Its practical potential is shown by the results, which demonstrate great adsorption performance with R2 values surpassing 0.97 under optimum conditions. However, the study is constrained by its single dye testing and its emphasis on batch processes rather than continuous flow systems.