1 Introduction

Water pollution has increased substantially in recent decades due to population growth and rapid developments in infrastructure, industrial, agricultural, and pharmaceutical sectors. The main contaminants typically found in water bodies include dyes, pharmaceutical waste, heavy metals, radioactive materials, fertilizers, and pesticides [1, 2]. Dyes consist of synthetic aromatic compounds along with different functional groups [3, 4]. The discharge of wastewater with such dyes into the environment causes many problems which have a detrimental effect on human health and aquatic life [5]. These dyes are synthetic and composed of complex aromatic structures that may be carcinogenic and non-biodegradable [6]. Among them, Rd-B is one of the dyes found in industrial wastewater. Rhodamine B is a highly water-soluble dyestuff with the chemical formula C28H31ClN2O3 (479.02 g mol−1). Rd-B is a dye with amphoteric properties, although it is generally included in the dyestuff group with basic properties. Therefore, the chromophore groups that give color to the dyestuffs form the cation group of the molecule. The oxochromes, which provide the binding affinities of dyestuffs, are dimethylamino groups in the molecular structure, and chromophore groups are connected by quinoid rings [7, 8]. Rd-B dye is used in the textile industry for coloring papers, dying cotton, wood, leather, and silk [9]. Rd-B causes produce harmful effects such as tissue necrosis in humans, heartbeat increase, shock, and vomiting. Therefore, it is important to develop low-cost approaches that balance cost and effectiveness to remove organic contaminants from residual waters to enable its proper handling either for safe waste disposal or for safe reutilization for human use. Various physical or chemical methods such as ion exchange, reverse osmosis, chemical precipitation, membrane filtration, and adsorption are used for the treatment of wastewater [10]. In the removal of colored pollutants from wastewater, the adsorption process has the advantages of low cost, high selectivity, efficiency, environmental friendliness, and ease of application [11,12,13]. For the adsorption process to be applied more effectively, it is of particular importance that the material chosen as an adsorbent is economical, easily obtainable, easily recoverable, and non-toxic [4, 14,15,16]. For this purpose, the use of cheap, non-toxic, abundant in nature, low-cost adsorbents has become widespread in recent years. Natural minerals and polymers are widely used such as clay [17], vermiculite [18], sepiolite [19], and dolomite [20] and natural minerals such as chitosan [21] and lignin [22] in the removal of dyes from wastewater. In addition to these adsorbents, the use of biosorbent, which is defined as the removal of dyes by living or dead biomass, stands out today. The biosorption process is very attractive because the biosorbent is inexpensive and readily available. Today, various agricultural solid wastes as natural biosorbent such as agave bagasse [23], apricot stone [24], grapefruit peel [25], corncob [26], avocado seed [27], and bamboo shoot shell [28] were utilized for the removal of dyes from wastewater. The use of agricultural solid waste biomass as a biosorbent is very interesting due to its advantages such as the high potential for ion exchange, the biosorbent recovery by sorption–desorption cycles, the low cost and easy availability, the abundance, and the high surface area [29, 30].

Therefore, this study investigates the feasibility of using an almond shell (AS)-based biosorbent to remove Rd-B as a cationic dye from an aqueous solution. AS is a readily available lignocellulosic biowaste feedstock that contains cellulose, hemicellulose, and pectic components. The experiments were designed, and the operating conditions were optimized. Isotherm and kinetic studies were also carried out to identify the adsorption properties of the biosorbent. To our knowledge, this is the first report on the removal of Rd-B dye using AS biosorbent. Moreover, this study also involves quantum chemical calculations. Quantum chemical parameters were calculated by the DFT/B3LYP/6-311G method for the unprotonated and protonated Rd-B. Finally, to prove the effective application of the material, we treat wastewater from paper photography processing operations using AS biosorbent showing efficient removal of organic contaminants.

2 Methods

2.1 Reagents and instrumentation

2.1.1 Reagents

Rd-B and methanol were purchased from Sigma-Aldrich. HCl, NaOH, KNO3, and ethanol were all purchased from Merck. Other all chemicals were of analytical grade.

2.1.2 Instrumentation

FT-IR (Bruker Model: Tensor II), SEM–EDX (SEM Tescan Mira3 Xmu), and UV–vis spectrophotometer “Shimadzu 160A” measuring device.

2.2 Preparation of biosorbent

The almond shells called Prunus dulcis were obtained from the Kaynarlar company in Tokat province in Turkey. After collection samples were washed with distilled water, dried at room temperature, and then used and stored in a polypropylene container for use in biosorption experiments.

2.3 Biosorption experiments

To understand the nature of the biosorption process, experiments were carried out in a 10 mL solution volume polypropylene tube, at 500 mg L−1 Rd-B dye concentration, at natural solution pH: 5.8, in 100 mg biosorbent mass, and at 25 °C for 24 h carried out. The solution was then vigorously stirred, and after 24 h, the concentration of Rd-B dye in the equilibrium solution was determined by absorbance measurement at λ = 554 nm using a UV–vis spectrophotometer [31]. Biosorption%, Q (mg g−1), and recovery% were calculated in Eqs. 1, 2, and 3, respectively.

$$Biosorption\%=\left[\frac{{C}_{i}-{C}_{f}}{{C}_{i}}\right]\times 100$$
(1)
$$Q=\left[\frac{{C}_{i}-{C}_{f}}{m}\right]\times V$$
(2)
$$\mathrm{Recovery\%}=\frac{{Q}_{\mathrm{des}}}{{Q}_{\mathrm{ads}}}x100$$
(3)

Ci, Cf, m, and V represent the initial and equilibrium liquid-phase concentrations of the Rd-B dye (mg L−1), the biosorbent mass (mg), and the volume of the solution (L), respectively [32,33,34].

2.4 Computation details

Quantum chemical calculations are important to describe the quantum chemical parameters of the molecule, such as molecular orbital energy HOMO and LUMO, gap energy, dipole moment (μ), softness (σ), and total energy (ET). All calculations were made with Gaussian 09 software [35] the geometry of the molecules studied was fully optimized using the DFT/B3LYP/6-311G in the aqueous phase. The quantum parameters are presented by mathematical formulas as follows (Eqs. 47):

$$\Delta {E}_{\mathrm{gap}}={E}_{\mathrm{LUMO}}-{E}_{\mathrm{HOMO}}$$
(4)
$$\chi =\frac{-\left({E}_{\mathrm{LUMO}}+{E}_{\mathrm{HOMO}}\right)}{2}$$
(5)
$$\eta =\frac{\left({E}_{\mathrm{LUMO}}-{E}_{\mathrm{HOMO}}\right)}{2}$$
(6)
$$\sigma =\frac{1}{n}$$
(7)

3 Results and discussion

3.1 FT-IR and SEM–EDX analysis

On almond shells FT-IR (Fig. 1), the broad flattened peak was observed at 3281 cm−1 attributed to the OH group. Peak intensity increased to 2820 cm−1 showing the symmetric and asymmetric stretching of the C-H bond of the CH2 group. The broadbands in the region of 1750–1000 cm−1 are characteristic of the stretching of C = O, C-O groups and bending vibrations of adsorbed water [36]. Rd-B shows significant changes after biosorption, and the new peak was observed at 1464 cm−1 attributed to C-H bending of alkane [37]. Two different new peaks emerge from 973 to 778 cm−1 attributed to C = C bending [38]. The spectral changes and new peaks formation confirm the biosorption of Rd-B dye on the almond shells.

Fig. 1
figure 1

FT-IR spectra of unloaded (a) and Rd-B loaded AS (b)

SEM analysis was used to observe the morphological differences of AS biosorbent before and after the biosorption of Rd-B dye. The SEM images in Fig. 2a and c show the structure of AS biosorbent before biosorption, and Fig. 2b and d shows the structure after biosorption. Figure 2a and c show that the structure of the biosorbent is porous and irregular. In the SEM images in Fig. 2b and d, it is clearly observed that after the biosorption, the pores turn into a smoother and more regular structure as they are filled with Rd-B dye molecules. This significant differentiation in the structure of the biosorbent indicates surface complexation.

Fig. 2
figure 2

SEM photographs of AS biosorbent before (a, c) and after (b, d) biosorption of Rd-B

Elements before and after biosorption on AS biosorbent were determined using EDX analysis, and EDX spectra are given in Fig. 3. The peaks of C and O were determined in the EDX analysis of AS biosorbent before biosorption. After biosorption, the peaks of C, O, and N were determined in the EDX analysis. The presence of N in the structure of the Rd-B dye was evaluated as evidence for biosorption.

Fig. 3
figure 3

EDX spectrum of AS biosorbent before (a) and after (b) biosorption of Rd-B

3.2 Effect of pH on biosorption and PZC for AS biosorbent

The protonation mechanism of the Rd-B molecule was studied between pH 0 and 14 by the MarvinSketch software. Figure 4 represents the different forms of this molecule and the percentage of protonation sites. It is observed that the Rd-B molecule has weak basic properties which facilitate their protonation in the acid medium; also the presence of heteroatoms in the molecule studied also suggests their strong tendency to protonation in acid solution. Figure 4 has illustrated the distribution ratio of each species as a function of pH; it is clear that only one major form (Rd-B-H+) was 94% at pH = 0 [39]

Fig. 4
figure 4

Speciation diagram for Rd-B as function of pH

Generally, for a cationic dye, the percent dye removal will decrease at a low pH solution and increase at high pH solution [40]. Figure 5 depicts the effect of pH on the adsorption capacity. The elimination as a function of pH was investigated at a pH 2.0 to 12.0. We can mark that the maximum dye biosorption was noticed at a pH of 2–6 (acid medium), while the minimum biosorption capacity was at pH of 8–12 (basic medium). By increasing pH value, the concentration of H+ increase, and the tendency of Rd-B dye molecules to occupy active sites increase leading to a decrease in the quantity biosorbed of AS biosorbent [41]. At high pH, the Rd-B dye molecules may get converted to their hydroxides, resulting in a decrease in the biosorption of Rd-B by the active sites of AS biosorbent [42] The point of zero charge (pzc) of AS biosorbent was 5.43 (Fig. 5). The finding suggests that the biosorbent surface will be positively charged at pH below pHpzc, favoring anionic attraction. On the other hand, the biosorbent becomes negatively charged when the pHpzc > pH, favoring cationic attraction [43].

Fig. 5
figure 5

Effect of pH on biosorption of Rd-B onto AS {[Rd-B]0: 500 mg L−1, biosorbent mass: 10 g L.−1, pH: 2.0–12.0, contact time: 24 h, temperature. 25 °C} and pzc for almond shells (Prunus dulcis)

3.3 Effect of biosorbent dose

To study the effect of the biosorbent mass on the retention of Rd-B dye by almond shells powder, we varied the value of the biosorbent dose from 1 to 20 g L−1 a concentration of 500 mg L−1 of Rd-B dye and a natural pH. All the results are grouped in Fig. 6; it can be seen that the dye removal percentage increases from 9.83 to 70.82% with the biosorbent dose increasing from 1 to 20 g L−1 proportionally. This is possibly due to the increase in the number of biosorption sites following the increase in the biosorbent dose [44]. However, the encounter (molecules-site) is more probable, leading to better retention of the Rd-B dye by the AS biosorbent [45]. The biosorbent dose was set at 10 g L−1 for the subsequent experiments.

Fig. 6
figure 6

Effect of biosorbent dose on biosorption of Rd-B dye onto AS {[Rd-B]0: 500 mg L−1, biosorbent mass: 1–20 g L−1, natural pH: 5.8, contact time: 24 h, temperature: 25 °C}

3.4 Biosorption isotherm models

In the current study, Langmuir [46, 47], Freundlich [48], and Dubinin-Radushkevich (D-R) [49] models (Fig. 7) were selected to investigate the interaction between the Rd-B dye molecules and the AS biosorbent surface. The biosorption isotherm model parameters are presented in Table 1; it is seen that the correlation coefficient of the Langmuir model (R2: 0.960) is larger than the Freundlich model (R2: 0.886). This showed that Rd-B dye biosorption on AS better fitted the Langmuir model. Rd-B dye biosorption on AS took place in a monolayer. The D-R isotherm model, on the other hand, evaluates biosorption on porous surfaces from an energetic point of view [50]. If the adsorption energy is less than 8 kJ mol−1, it is physical, and if it is between 8 and 16 kJ mol−1, it is chemical. When the Rd-B dye biosorption to the AS biomass is evaluated from this point of view, it is seen that the EDR: 10.5 kJ mol−1 is, in this case, the biosorption process chemical.

Fig. 7
figure 7

Biosorption isotherms {[Rd-B]0: 10–1000 mg L−1, biosorbent mass: 10 g L−1, natural pH: 5.8, contact time: 24 h, temperature: 25 °C}

Table 1 Biosorption isotherms and their parameters

Maximum monolayer sorption capacities of Rd-B dye to various sorbents are presented in Table 2. When Table 2 is examined, it is seen that the biosorption capacity of AS biomass is relatively larger compared to other sorbents. This is promising because AS biomass is an effective, inexpensive, and natural biosorbent for the removal of Rd-B dye from wastewater.

Table 2 Comparison of sorbent capacities of low-cost sorbents

3.5 Biosorption kinetics

Biosorption kinetics provide vital information about the rate and mechanism of the biosorption process. Generally, an adsorption process takes place in three stages: (i) mass migration from solution to biosorbent surface, which is very rapid due to mixing, (ii) the film diffusion of the biosorbent from the bulk solution to the surface of the biosorbent, and (iii) the intraparticle diffusion of the biosorbate into the pores of the biosorbent.

Pseudo-first-order (PFO), pseudo-second-order (PSO), and intraparticle diffusion (IPD) models (Fig. 8) [59, 60] are commonly used to explain biosorption kinetics. As a result of the fit to the models, the biosorption mechanism can be predicted. From Table 3, it is seen that the R2 value of the PSO model (R2: 0.907) is higher than that of the PFO (R2: 0.834) model. This showed that Rd-B dye adsorption on AS biomass better fitted the PSO model.

Fig. 8
figure 8

Biosorption kinetics {[Rd-B]0: 500 mg L−1, biosorbent mass: 300 mg, natural pH: 5.8, contact time: 10–1440 min, temperature: 25 °C}

Table 3 The calculated parameters of PFO, PSO, and IPD models

When the IPD model fit graph is examined, it is seen that it has two linear components instead of a single line passing through the origin. In this case, he states that the biosorption process includes firstly rapid adsorption to the surface and then relatively slow intraparticle diffusion steps. This showed that it is not possible to explain the biosorption process with a single kinetic model. The biosorption kinetics of Rd-B dye to AS biomass can be explained by PSO and IPD models [61].

3.6 Biosorption thermodynamics

During the biosorption process, thermodynamic parameters such as ΔH°, ΔG°, and ΔS° were calculated using the following equations [62] ΔG° was determined using Eq. 8.

$${\Delta G}^{^\circ }=-RT\mathrm{ln}({K}_{d})$$
(8)

where R (8314 J mol−1 K−1) is the ideal gas constant, T (K) is the absolute temperature, and Kd is the distribution coefficient. The dispersion coefficient, which reveals the affinity of the biosorbent surface, is calculated by Eq. 9.

$${K}_{d}= \frac{Q}{{C}_{e}}$$
(9)

ΔH° and ΔS° parameters were found using the Van’t Hoff Eq. 10.

$$\mathrm{ln}{K}_{D}= \frac{{\Delta S}^{^\circ }}{R}-\frac{{\Delta H}^{^\circ }}{RT}$$
(10)

ΔH°, ΔG°, and ΔS° were determined using the slope and intercept values of the lnKD-1/T plot (Fig. 9, Table 4). When Table 4 is analyzed, it is seen that the biosorption process is spontaneous, entropy-increasing, and endothermic.

Fig. 9
figure 9

The effect of temperature {[Rd-B]0: 500 mg L−1, biosorbent dose: 10 g L−1, natural pH: 5.8, contact time: 24 h, temperature: 5 °C, 25 °C, and 40 °C}

Table 4 Thermodynamic parameters

3.7 Recovery and reusability of AS

The recovery and reusability of AS biosorbent after the biosorption process is extremely important in terms [63, 64]. Therefore, 5 times desorption experiment was carried out using HCl, methanol, and ethanol, solutions with 0.1 mol L−1 concentration to recover the Rd-B dye biosorbed on the AS biosorbent surface. Obtained recovery percentages are given in Fig. 10. In Fig. 10, it is seen that the highest recovery is achieved with ethanol (46%), and the lowest recovery is with HCl (23%).

Fig. 10
figure 10

The effect of desorption on AS biomass

3.8 DFT calculations

3.8.1 Reactivity descriptor analysis

Several quantum chemical parameters have been calculated and summarized in Table 5. The neutral form and the protonated form of the Rd-B molecule can be explained in terms of geometry, and it could be explained in terms of the gap energy ΔEgap and other quantum parameters. Therefore, the lower the energy difference between the orbital HOMO and LUMO, the easier the electrons of the molecule to pass to the surface of the adsorbent, and the higher the application of biosorption will be, on the other hand, larger gap values ​​will provide low chemical reactivity [65]. According to the results obtained in Table 5, we note that the proton form (P-Rd-B) has the smallest energy difference (1.3765 eV), so it is the least stable and most reactive form. Chemically relative to the neutral form (Rd-B), the P-Rd-B molecule is the easiest to be adsorbed by the almond shell adsorbent. The proton molecule (P-Rd-B) has a low hardness value (η = 0.6882 eV) and the highest softness value (S = 1/η = 1.4528 eV); this suggests the ability to adsorb by the almond shells; also the dipole moment of the protonated form is higher compared to the neutral form; maybe a larger dipole moment is responsible for the biosorption.

Table 5 Quantum chemical parameters are calculated by the DFT/B3LYP/6-311G method for the Rd-B and P-Rd-B

Figure 11 represents the frontier orbitals HOMO and LUMO of the neutral and protonated form after optimization. This Fig. 12 confirms that the Rd-B dye molecule is rich in electrons and capable of donating electrons. It is also observed that the HOMO density distribution of Rd-B dye is located on the heterocyclic atom rings, the nitrogen, and the CH3 groups. The distribution of the HOMO density of protonated form P-Rd-B is located in the function C = C, C–C = C, the oxygen atom, and the nitrogen atom which can play an essential role in the absorption.

Fig. 11
figure 11

Representation of the optimized geometry, frontier orbitals (HOMO, LUMO), and electrostatic potential (ESP) of the Rd-B and P-Rd-B

Fig. 12
figure 12

Mulliken charges for Rd-B and P-Rd-B

3.8.2 The Mulliken charges

Several authors agree that the more the heteroatom is negatively charged, the more it is able to adsorb by the adsorbent and has a serious reaction of the donor–acceptor type. The Mulliken charges for Rd-B and P-Rd-B are reported in Fig. 12. Examination of these results shows that all heteroatoms have negative charges with high electron density. These atoms behave as nucleophilic centers when they interact with the adsorbent. From the values ​​of Fig. 12, it is possible to observe that all the atoms of nitrogen and oxygen have a considerable excess of negative charge, and some carbon atoms have a negative charge, which are adsorbent active atoms.

4 Conclusion

In this study, agricultural solid waste biosorbent (almond shell) was used, and its effectiveness in removing Rd-B dye from aqueous solution was investigated. The maximum biosorption capacity of AS biosorbent for the Rd-B dye was found as 14.7 g mg−1 at 25 °C from the Langmuir model. The adsorption energy found from the D-R model showed that the adsorption process is chemical. Adsorption kinetics showed that the adsorption process is quite suitable for PSO and IPD models. Thermodynamic parameters of the biosorption process of Rd-B dye molecules by AS biosorbent were determined. At 25 °C, ΔH0, 2.35 kJ mol−1; ΔS0, 55 kJ mol−1; and ΔG0, − 14.1 kJ mol−1 were found. Also, at different temperatures, the adsorption process is negative, so it happens spontaneously. In addition, the adsorption of Rd-B dye molecules on the AS biosorbent surface was demonstrated by FT-IR and SEM–EDX analyses. The adsorption–desorption experiment results showed that the AS biosorbent has very good reusability and stability. The results of this work show that an effective low-cost adsorbent can be produced starting from almond shells without any treatment, which can be used by communities with limited resources facing water contamination by dyes. Moreover, the quantum chemical calculations used allowed us to propose the binding mechanism for Rd-B biosorption to the AS biosorbent. The overall results showed that the AS biosorbent has a remarkable biosorption affinity towards the Rd-B dye in aqueous medium.