Introduction

Water pollution due to contamination by dyes and metals is a worldwide environmental problem [1, 2]. Most synthetic dyes and metal cations are carcinogenic and mutagenic, and persist in the environment due to their toxicity, non-biodegradability, bioaccumulation capacity, and solubility [3]. The accumulation of cadmium in an organism causes damage to the kidneys, liver, intestine, reproductive system, and central nervous system [4]. The accumulation of methylene blue causes skin irritation, eye burn, dyspnea, dermatitis, cyanosis, vomiting, and tissue necrosis [5].

Cadmium and methylene blue are discarded into the environment as the consequence of electrolytic, agricultural, medical, textile, and other human activities [6]. The abatement of these substances in water and wastewater is commonly performed using physiochemical processes, such as photocatalysis, oxidation-reduction, flocculation, coagulation, electrolysis, membrane separation, ion exchange, and sorption [7]. Sorption is one of the most efficient and economical methods for the depollution of water and wastewater contaminated with synthetic dyes and heavy metals due to its simplicity, high efficiency, and low cost [8, 9].

Sorption studies are generally conducted using traditional adsorbents, such as activated carbon, zeolite, and biosorbents. However, these adsorbents have low sorption capacities that limit their use in some applications [10]. Numerous studies have described the development of polymers and composites capable of adsorbing and removing large amounts of pollutants from aqueous solutions with high sorption rates, low cost, and easy operation, including superabsorbent hydrogels [11]. Hydrogels are hydrophilic three-dimensional polymer networks that swell in water without dissolving [12]. Hence, these polymer matrices absorb water and pollutants through diffusion processes and macromolecular relaxation during swelling assays.

Chitosan-based hydrogels, in particular, are potential matrices for water treatment due to their mechanical resistance, thermal resistance, chemical stability, as well as the possibility of the recovery of both the hydrogel and pollutant, enabling reuse studies [13]. However, the mechanical resistance of chitosan-based hydrogels can be improved with the addition of inorganic nanoparticles during polymer synthesis [14]. Moreover, chitosan/magnetite-based composite hydrogels can be efficiently recovered without using chemical reagents [15], thereby avoiding the production of secondary residues. The fact that polysaccharide-based hydrogels need to have significant mechanical resistance to be embedded in water purification filters [16, 17] is a motivation for the synthesis of chitosan/magnetite-based composite hydrogels for the water and wastewater treatment contaminated by metals and dyes.

The aim of the present study was to evaluate a chitosan-based hydrogel and chitosan/magnetite-based composite hydrogel as potential matrices for water treatment through sorption experiments of metals and dyes. Cadmium and methylene blue were used as model pollutants. Experiments were conducted in a water shaker bath by varying the pH of the aqueous solution, initial pollutant concentration, and sorption time. The sorption mechanisms of the pollutants to the hydrogels were evaluated using nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherm models as well as nonlinear pseudo-first-order, pseudo-second-order, and Elovich kinetic models. The sorption thermodynamics of the pollutants in the hydrogels were studied by measuring the variation in entropy, enthalpy, and Gibbs free energy. The sorption processes were confirmed by Fourier-transform infrared spectroscopy and thermogravimetric analyses.

Materials and methods

Reagents

Chitosan (CS) with a 92% degree of deacetylation and molar weight of 1.0 × 106 Da, acrylic acid (AA, Merck), acetic acid (AAc, Merck), methylenebisacrylamide (MBA, Aldrich), ammonium persulfate (APS, Aldrich), magnetite nanoparticles (Fe3O4, Fisher Scientific) with average particle size around 50 nm, cadmium sulphate (CdSO4 PA, Biotec), and methylene blue (MB, Aldrich). All experiments were performed using ultrapure water.

Hydrogel synthesis

The chitosan-based hydrogel (CBH) was synthesized by dissolving 0.30 g of CS in 30.0 mL of 2% acetic acid solution contained in a glass flask. The resulting CS solution was deaerated for 30 min with nitrogen gas. Next, 120 mg of APS (initiator) was added to this solution under continuous nitrogen gas flow. Finally, a previously deaerated solution containing 3.4 g of AA and 150 mg of MBA was added to the glass flask under an inert atmosphere and left at 80 °C for 3 h to complete the crosslinking process. The synthesis of the chitosan/magnetite-based composite hydrogel (CMCH) was performed by adding 50 mg of magnetite nanoparticles to the AA and MBA solution. The CBH and CMCH were synthesized with the aim of comparing the effects of pollutant sorption in aqueous solutions. Understanding such effects is important, as magnetic hydrogels can be recovered from successive sorption/desorption cycles without the use of chemical reactants. Both formed hydrogels were cut into small cylindrical pieces weighing approximately 100 mg, immersed in 2.0 mol L−1 sodium hydroxide solution for 15 min, washed with ultrapure water for 24 h, and dried in an oven (Ethiktechnology 400/5TS, Brazil) at 60 °C for 72 h.

Swelling kinetics

Swelling kinetics are used to describe water diffusion processes in hydrophilic three-dimensional polymeric chains [18]. Hydrogel swelling assays were performed (in triplicate) by immersing 100 mg of cylindrical dried hydrogel pieces in 100 mL of (i) water distilled, (ii) drinking water, (iii) 0.2 mol L−1 acetate buffer solution at pH 4.0, or (iv) 0.2 mol L−1 phosphate buffer solution at pH 7.0. Swollen hydrogel weights were measured at different time intervals to determine the degrees of swelling (DS, g g−1) using Eq. (1):

$$ DS=\frac{w_s(t)-{w}_d}{w_d} $$
(1)

in which, ws(t) is the swollen hydrogel weight (g) at a specific swelling time and wd is the dried hydrogel weight (g).

The water absorption mechanism is described using the Fick equation modified to explain water transport into the hydrogel network [19], as presented in Eq. (2):

$$ \frac{w_t}{w_{eq}}=k{t}^n $$
(2)

in which wt and weq are the water weights (g) absorbed in the hydrogel chain at a specific absorption time and at equilibrium, respectively, k is the kinetic constant (min−1), n is the water diffusion exponent, and t is the swelling time (min).

When the n value is lower than 0.45, water transport is characterized by Fick diffusion. In this case, only diffusion processes take place during hydrogel swelling. When the n value is between 0.45 and 0.89, water transport is defined by non-Fick diffusion. In this case, diffusion occurs through pores and the macromolecular relaxation of the polymer network simultaneously. Finally, when the n value is higher than 0.89, water transport is defined as Super Case II. In this case, diffusion in the polymer chain only takes place by macromolecular relaxation [20].

Fourier-transform infrared spectroscopy

Fourier-transform infrared (FT-IR) spectra were recorded using a Perkin-Elmer Frontier spectrometer with attenuated total reflectance (ATR). Hydrogel samples before and after the sorption of MB and cadmium were swollen in distilled water to maximum swelling equilibrium, frozen in an ultra-freezer (IULT 335 D, Indrel, Brazil), and freeze-dried (TFD5503, Ilshin Lab. Co. Ltd., Korea) for 24 h. Next, the dried hydrogel samples were dispersed on an ATR diamond crystal, with measurements conducted in the spectral range varying from 500 to 4000 cm−1, with sensibility of 2 cm−1 and 32 scans per sample.

Thermogravimetric analysis

Thermogravimetric analysis (TGA, Netzsch STA 449 C Jupiter, Germany) was conducted using a simultaneous thermal analyzer (STA, Germany) operating at temperatures ranging from 25 to 600 °C, with a heating rate of 20 °C min−1 under an inert atmosphere generated for a N2 flow of 40 mL min−1, and dried hydrogel weights ranging from 10 to 20 mg. The hydrogel samples were prepared as described in the “Fourier-transform infrared spectroscopy” section.

Cadmium and methylene blue sorption studies

The sorption experiments were performed using stock solutions of 50 mg L−1 cadmium and 10 mg L−1 methylene blue (MB) at either pH 4.0, 5.0, or 6.0. A total of 100-mg dried hydrogel pieces were placed in Erlenmeyer flasks containing 100 mL of either the metal or dye solution at room temperature with different sorption times. The MB concentration remaining in aqueous solution was determined by UV-VIS spectrophotometry (Schimadzu, UV-1800, Japan) at 665 nm wavelength, and the remaining cadmium concentration was determined by flame atomic absorption spectrometry (FAAS – Analytic Jena AG, Jena, Germany, contra 700, air-acetylene flame, λ 228.8018 nm). Sorption capacities (qe, mg g−1) were calculated using Eq. (3):

$$ {\mathrm{q}}_{\mathrm{e}}=\frac{{\mathrm{C}}_0-{\mathrm{C}}_{\mathrm{e}}}{\mathrm{m}}\ \mathrm{V} $$
(3)

in which Co (mg L−1) and Ce (mg L−1) are the initial and equilibrium pollutant concentrations, respectively, m (g) is the dried hydrogel weight, and V (mL) is the initial volume of the aqueous solution.

Data analysis

The experimental data were treated considering a relative error lower than 5% (p ≤ 0.05). The sorption processes were investigated at contact times ranging from 1 to 4500 min. The sorption kinetics were investigated by applying nonlinear pseudo-first-order, pseudo-second-order, and Elovich kinetic models. The nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherms were investigated with an initial cadmium concentration ranging from 10 to 100 mg L−1 and an initial MB concentration ranging from 10 to 30 mg L−1. The thermodynamic assays were conducted at temperatures of 303.15, 313.15, and 323.15 K. All experiments were performed in triplicate. However, the error bars did not appear in the most of the experimental results as their values were not significant. The experimental errors were predicted using the chi-square test (χ2) and correlation coefficient (R2) as described elsewhere [21].

Sorption kinetics

Models of sorption kinetics are widely used to evaluate interactions between adsorbents and adsorbates [22]. The nonlinear pseudo-first-order and pseudo-second-order kinetic models are represented by Eqs. (4) and (5), respectively:

$$ {\mathrm{q}}_{\mathrm{t}}={\mathrm{q}}_{\mathrm{e}}\left(1-{\mathrm{e}}^{-\mathrm{kt}}\right) $$
(4)
$$ {\mathrm{q}}_{\mathrm{t}}=\frac{\mathrm{k}{\mathrm{q}}_{\mathrm{e}}^2\mathrm{t}\ }{1+\mathrm{k}{\mathrm{q}}_{\mathrm{e}}\mathrm{t}} $$
(5)

in which k (min−1) is the sorption rate, t (min) is the sorption time, and qt (mg g−1) is the sorption capacity at time t.

The nonlinear Elovich sorption kinetic model is represented by Eq. (6):

$$ {\mathrm{q}}_{\mathrm{t}}=\frac{1}{\beta }\ \ln\ \left(1+\upalpha \upbeta \mathrm{t}\ \right) $$
(6)

in which α (mg g−1 min−1) is the initial sorption rate at time t (min) and β (g mg−1) is a desorption constant related to the adsorbate layer on the adsorbent surface as well as the activation energy of chemisorption processes.

Sorption isotherms

Sorption isotherms are applied to study the economic feasibility of an adsorbent and its efficiency in the sorption process [23]. The nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherm mathematical models are described by Eqs. (7), (8), (9), and (10), respectively:

$$ {\mathrm{q}}_{\mathrm{e}}=\frac{{\mathrm{q}}_{\mathrm{max}}{\mathrm{K}}_{\mathrm{L}}{\mathrm{C}}_{\mathrm{e}}}{1+{\mathrm{K}}_{\mathrm{L}}{\mathrm{C}}_{\mathrm{e}}} $$
(7)
$$ {\mathrm{q}}_{\mathrm{e}}={\mathrm{K}}_{\mathrm{F}}{\mathrm{C}}_{\mathrm{e}}^{\frac{1}{\mathrm{n}}} $$
(8)
$$ {\mathrm{q}}_{\mathrm{e}}=\frac{{\mathrm{K}}_{\mathrm{R}}{\mathrm{C}}_{\mathrm{e}}}{1+{\mathrm{a}}_{\mathrm{R}}{\mathrm{C}}_{\mathrm{e}}^{\upbeta}} $$
(9)
$$ {\mathrm{q}}_{\mathrm{e}}=\frac{{\mathrm{q}}_{\mathrm{max}}{{\mathrm{K}}_{\mathrm{s}}{\mathrm{C}}_{\mathrm{e}}}^{\upbeta_{\mathrm{S}}}}{1+{\mathrm{K}}_{\mathrm{S}}{\mathrm{C}}_{\mathrm{e}}^{\upbeta_{\mathrm{S}}}} $$
(10)

in which qe (mg g−1) is the equilibrium sorption capacity of the hydrogel, qmax (mg g−1) is the maximum sorption capacity, KL(L mg−1) is the Langmuir sorption constant, Ce (mg L−1) is the equilibrium metal/dye concentration, KF (mg g−1) is the Freundlich constant related to sorption capacity, 1/n is the Freundlich constant related to the surface heterogeneity of the specific adsorbate, aR (mg−1) and KR (L g−1) are Redlich-Peterson constants, β is the Redlich-Peterson exponent, Ks (L mg−1) is the Sips constant, and βS is the Sips exponent describing the homogeneity/heterogeneity of the sorption process.

Thermodynamic parameters

Variations in Gibbs free energy (ΔG0), enthalpy (ΔH0), and entropy (ΔS0) for the sorption of methylene blue and cadmium with the chitosan-based hydrogel and chitosan/magnetite-based composite hydrogel were calculated using Eqs. (11), (12), (13), and (14). The Van’t Hoff equation (Eq. 14) was obtained by substituting Eq. (11) in Eq. (13):

$$ \Delta G{}^{\circ}=- RT\ln \left({K}_D\right) $$
(11)
$$ {K}_D=\frac{C_{o-\kern0.5em }{C}_e}{C_e} $$
(12)
$$ \Delta G{}^{\circ}=\Delta H{}^{\circ}-T\Delta S{}^{\circ} $$
(13)
$$ \kern1em \ln \left({K}_D\right)=\frac{\Delta S{}^{\circ}}{R}-\frac{\Delta H{}^{\circ}}{RT} $$
(14)

in which R is the ideal gas universal constant (8.314 J K−1 mol−1), T is the absolute temperature (K), and KD is the distribution constant. The ΔH° and ΔS° values were determined by plotting ln(Kd) as a function of 1/T.

Results and discussion

Swelling kinetics

Figure 1a–b displays the degrees of swelling of the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Figure 1c–d displays the water diffusion rates in the CBH (c) and CMCH (d) networks. The degree of swelling of the CBH in distilled water was 1074 g of water per gram of dried hydrogel after 1440 min. This value was approximately 13.18 g g−1 for the CMCH. The degrees of swelling of the CBH and CMCH in drinking water were respectively 152.97 and 11.54 g g−1. Higher degrees of swelling were found in distilled water due to the stronger electrostatic repulsion forces among the deprotonated carboxylic groups in the polymer networks. The presence of different metal cations in drinking water decreases the degree of swelling due to the reduction in the macromolecular relaxation of the polymer network [24]. The degrees of swelling were respectively 107.68 and 0.8246 g g−1 in buffer solution at pH 4.0 and 307.64 and 0.8590 g g−1 in buffer solution at pH 7.0. The carboxylic groups in the hydrogel networks are protonated in more acidic media, decreasing the electrostatic repulsion forces and degree of swelling. Similar effects were also noticed at pH 7.0 due to the presence of metallic cations in the phosphate buffer solution [25]. The increase in pH deprotonates carboxylic groups in polymer networks, increasing the degree of swelling, as observed experimentally [26]. The degrees of swelling of the CMCH were much lower than those found for the CBH, as magnetite nanoparticles increase the crosslinking density and mechanical resistance of three-dimensional polymeric structures, reducing macromolecular relaxation [27].

Fig. 1
figure 1

Degrees of swelling of the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based hydrogel (CMCH) (b) in distilled water, drinking water, 0.2 mol L−1 acetate buffer solution at pH 4.0 and 0.2 mol L−1 phosphate buffer solution at 7.0. Water diffusion rates in CBH (c) and CMCH (d)

Table 1 displays the diffusion exponent (n), correlation coefficient (R2), and kinetic constant (k) during the swelling assays of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) in distilled water, drinking water, 0.2 mol L−1 acetate buffer solution at pH 4.0, and 0.2 mol L−1 phosphate buffer solution at pH 7.0. The n values for the absorption of water in the CBH ranged from 0.5563 to 0.8316, indicating non-Fick transport. In this case, two water absorption processes are taking place simultaneously: (i) diffusion through pores and (ii) macromolecular relaxation of the hydrogel network. This confirms that the flexibility of the polymeric chain affects water and solute diffusion [27]. The n values during the swelling of the CMCH in distilled water and drinking water ranged from 0.45 to 0.89, indicating non-Fick transport. However, these values were lower than 0.45 in both buffer solutions, indicating Fick transport. In this case, water molecules move through porous hydrogels only by diffusion due to lower flexibility of the polymer chains [25]. Higher k values during the absorption of water in the CMCH confirmed faster swelling kinetics, with the equilibrium reached at shorter absorption times [13]. This affects the sorption of inorganic and organic pollutants in water and wastewater.

Table 1 Diffusion exponent (n), correlation coefficient (R2), and kinetic constant (k) during the swelling assays of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) in distilled water, drinking water, 0.2 mol L−1 acetate buffer solution at pH 4.0 and 0.2 mol L−1 phosfate buffer solution at pH 7.0

FT-IR spectra

Figure 2 displays the FT-IR spectra of the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b) before and after the sorption of methylene blue (MB) and cadmium. The absorption bands at approximately 3400 cm−1 were attributed to the stretching of either OH or N-H groups, with their intensities influenced by hydrogen bonds occurring in cross-linked polymer network [28]. The absorption band at 2940 cm−1 was attributed to symmetrical stretching vibrations of C-H groups [29]. Carbonyl group (C=O) bands are frequently observed from 1680 to 1820 cm−1 [30], as that seen at approximately 1690 cm−1. The absorption band at 1548 cm−1 was assigned to primary and secondary amide groups from the crosslinked chitosan [31, 32]. The absorption bands at 1410, 1288, and 1176 cm−1 were attributed to the asymmetric stretching of COO groups, C-H vibration, and stretching vibration of COO groups, respectively [28]. Finally, the absorption band at 1119 cm−1 was related to the stretching and vibration of the C-N group [33].

Fig. 2
figure 2

FT-IR spectra of the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b) before and after the interaction of methylene blue (MB) and cadmium

The absorption bands at 1690 and 1410 cm−1 shifted slightly to 1679 and 1400 cm−1 after the sorption of cadmium in the CBH due to the occurrence of intermolecular interactions. A similar effect was found for the absorption band at 1548 cm−1, which shifted to 1535 cm−1 due to the formation of a complex between the metal and NH2 groups [29]. The original absorption bands did not significantly increase after the sorption of cadmium, as the active sites in the CBH network were not completely occupied. This reveals that the sorption process is governed by physiochemical interactions and diffusion through pores during hydrogel swelling. The absorption band at 1060 cm−1 shifted slightly to 1052 cm−1 after MB sorption due to hydrogen bonds taking place between the dye molecules and polymer network [34]. The absorption bands in this region increased after the interaction of MB, as the active sites in the CBH network were occupied by dye molecules. Four differences were noted for the interaction of cadmium to the CMCH. First, the absorption band intensity at 1690 cm−1 increased 20% due to intermolecular interactions between cadmium and C=O groups. Second, the absorption band at 1320 cm−1 was shifted for 1309 cm−1 due to pollutant interactions in O-C-O groups. Third, the absorption band intensity at 1119 cm−1 decreased 15% due to physiochemical interactions occurring in polysaccharide rings containing C-N groups. Forth, the absorption band intensity at approximately 3400 cm−1 decreased 22% due to complex formation between cadmium/hydrogel, or iron/hydrogel in the case of the magnetic hydrogel. Some absorption bands increased, as magnetite can occupy the pores of the polymer network, with the occurrence of intermolecular interactions. The absorption band intensity at 1548 cm−1 increased during the sorption of MB, as hydrogen bonds can form between the dye and NH2 groups. Moreover, a complex can form between iron atoms from magnetite and NH2 groups.

Thermogravimetric analysis (TGA)

Figure 3 displays the thermogravimetric curves of the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b) before and after the sorption of methylene blue (MB) and cadmium. Table 2 displays the thermogravimetric variables. Weight loss of approximately 5 and 24% was observed at 90 and 450 °C, respectively. The first case is related to the evaporation of water contained in the hydrogel structures, as hydration water molecules are commonly found in hydrophilic polymer networks even after drying processes [35, 36]. The second case is associated with the onset of the thermal degradation of the hydrophilic three-dimensional hydrogel network due to the breakage of glycosidic bonds [36, 37]. Higher initial weight loss temperatures (Tonset) were determined for some hydrogel samples due to physiochemical interactions taking place between polar functional groups of hydrogel networks and water molecules, which favor the formation of denser polymeric structures. The empty volumes in the polymer structures must be occupied by magnetite nanoparticles in the CMCH, hindering the evaporation of water [25]. The maximum degradation rate temperatures (Tmax) of the CMCH were slightly higher than those found for the CBH. This may be associated with the formation of covalent bonds between active groups in the polymer network and magnetite, cadmium or MB, enhancing thermal resistance [25]. Overall, lower weight losses were found for the CBH and CMCH after the sorption of MB and cadmium, indicating that the presence of solutes in the hydrogel networks alters the thermal properties of the final materials [15]. Strong intermolecular interactions in three-dimensional polymeric networks can lead to significant changes in thermal stability [38]. However, the presence of MB and cadmium in the hydrogel structure can also increase the ash content without any intermolecular interaction with the polymer chain.

Fig. 3
figure 3

Thermogravimetric curves of the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b) before and after the interaction of methylene blue (MB) and cadmium

Table 2 Thermogravimetric variables of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) before and after the interaction of methylene blue (MB) and cadmium

Effect of sorption time

Figure 4 displays the sorption capacities of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) as a function of time during the sorption of methylene blue (MB) (a) and cadmium (b). The high initial sorption rates for both hydrogels are related to the amount of available active sites in the hydrophilic three-dimensional networks at the onset of the sorption process. This confirms that the sorption phenomena are dependent on the pollutant concentration transported from the aqueous solution to the hydrogel structure [29]. The sorption rates decreased with the increase in sorption time due to partial saturation of the available active sites in the hydrogel network [13]. Pollutant sorption capacities in aqueous solutions are also affected by the degree of swelling of the hydrogel network [39]. Indeed, the total amount of pollutant (in this case MB or Cd) removed from water by hydrogels can be represented by the sum of the amount adsorbed in the polymer network and the amount absorbed as a liquid phase in the swollen hydrogel. As MB and cadmium sorption capacities did not change significantly from 1440 min, the sorption equilibrium was assumed to have occurred between 1440 and 4320 min. The MB sorption capacity of the CBH was 16.97 mg of dye per gram of dried hydrogel after 4320 min and the MB sorption capacity of the CMCH was 14.48 mg of dye per gram of dried hydrogel after 4320 min. The high equilibrium sorption time found in this work is in agreement with reports of MB interaction to hemicellulose-based hydrogels [40]. Overall, MB sorption with composite hydrogel was not significantly affected by the presence of magnetite, probably due to the predominance of intermolecular interactions between the pollutant and hydrogel. The cadmium sorption capacity of the CBH was 48.70 mg of metal per gram of dried hydrogel after 4320 min, whereas the cadmium sorption capacity of the CMCH was 23.74 mg of metal per gram of dried hydrogel after 4320 min. Cadmium interaction to the CMCH was significantly affected by the presence of magnetite due to smaller amount of pores in the polymer network as a result of the increase in crosslinking points formed between magnetite and anionic groups. As diffusion processes and intermolecular interactions between pollutants and hydrogel networks are significant on porous surfaces, cadmium sorption is facilitated by its small hydrated ionic radius [41], enhancing the sorption capacity, as observed for the CBH. Moreover, the diffusion of water through pores transports small ions into the hydrogel network, increasing the sorption capacity. As the degrees of swelling of the CBH in different aqueous media were significantly higher than those found for the CMCH, one may assume that cadmium sorption is governed by intermolecular interactions and diffusion through pores. Thus, the metal sorption rate limiting step could be defined by hydrogel swelling. Metal sorption capacities in hydrogels are also affected by differences in electronegativity. As cadmium electronegativity is lower than iron electronegativity, lower cadmium sorption capacity of the CMCH would be expected [42].

Fig. 4
figure 4

Sorption capacities of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) as a function of time during the interaction of MB (a) and cadmium (b). Experimental conditions: 50 mg L−1 initial cadmium concentration, 20 mg L−1 initial MB concentration, 100 mg dried hydrogel weight, and room temperature

Effect of pH

Figure 5 displays the effect of pH on the methylene blue (MB) (a) and cadmium (b) sorption capacities of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH). MB sorption capacities of the CBH were 13.95, 15.39, and 16.07 mg of dye per gram of dried hydrogel at pH 4.0, 6.0, and 8.0, respectively, and MB sorption capacities of the CMCH were 13.93, 15.24, and 15.81 mg of dye per gram of dried hydrogel at pH 4.0, 6.0, and 8.0, respectively. Higher sorption capacities were found in both hydrogels with the increase in pH due to ionization of the active glucuronic groups present in hydrophilic three-dimensional polymer networks [29, 43]. Hydrogel ionization involves anionic groups interacting with MB cationic groups, enhancing the sorption capacity. These interactions are more significant at pH higher than 3.80 (pKa of MB), since the MB molecule is positively charged. When the solution pH is lower than 3.80, the MB molecule is either partially or completely protonated, decreasing the electrostatic interactions with hydrogel chemical groups, which decreases the sorption capacity. Moreover, amine groups (-NH2) of chitosan-based hydrogels are partially or completely protonated at pH lower than 6.5 (pKa of NH2 groups), forming -NH3+ ions, whereas carboxylic groups are protonated (-COOH) at pH lower than 4.7 (pKa of carboxylic groups). Hence, electrostatic repulsion forces take place between -NH3+ ions and cationic MB molecules, decreasing the sorption capacity. When the solution pH is higher than 3.80, stronger electrostatic attraction forces take place between carboxylate anions and cationic MB molecules, enhancing the sorption capacity, as observed experimentally [29, 44]. The lower sorption capacity of the CMCH at all pH values is related to interactions between iron and anionic groups of the hydrogel, impeding the interaction of MB. However, similar effects were observed comparing both hydrogels, as FeOH2+ ions can be also found at pH values lower than 5.3 (pKa of FeOH2+ groups). Moreover, FeO groups can be found at pH values lower than 8.8 (pKa of FeO groups) [45]. Overall, the pollutant sorption capacity of the CMCH at pH lower than 7.0 (isoelectric point of magnetite) was also affected by the protonation of magnetite in the polymer network [46]. Hence, electrostatic repulsion forces among the protonated magnetite, MB, and hydrogel decreased the sorption capacity of MB.

Fig. 5
figure 5

Sorption capacities of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) as a function of pH during the interaction of MB (a) and cadmium (b). Experimental conditions: 50 mg L−1 initial cadmium concentration, 20 mg L−1 initial MB concentration, 100 mg dried hydrogel weight, and room temperature

By assuming that the free sorbate concentration in the liquid phase inside the hydrogel is equal to that determined in the liquid phase outside the hydrogel, the sorption capacity represents the amount of pollutant effectively sorbed in the polymer network. In this case, the amount of pollutant sorbed in the hydrogel network can be estimated from the sorbate concentration in the solution and the swelling coefficient of the hydrogel. A simple calculation using the results of the swelling and sorption experiments at pH 4 (disregarding the dissimilar ionic strength used in the swelling and sorption solutions) could be performed to justify the experimental results in terms of sorption capacities, as follows: if 1.0 g of dried CBH adsorbs 13.95 mg of MB (sorption capacity) and 107.68 g of aqueous solution (swelling capacity) with a concentration of (roughly) 20 mg of MB per liter, the estimated amount of free MB trapped in the liquid phase inside the hydrogel is 0.10768 l × 20.0 mg of MB per liter, i.e., about (but actually always less than) 2.16 mg. This amount is significantly lower than that sorbed in the CBH (13.95 mg) and still lower than that sorbed in the composite hydrogel (CMCH) with much lower swelling capacity. Hence, this rough calculation could be useful for the presentation of the pollutant-removal capacity of the hydrogels solely in terms of sorption capacity.

The cadmium sorption capacities of the CBH were 26.48, 29.52, and 49.28 mg of metal per gram dried hydrogel at pH 4.0, 5.0, and 6.0, respectively. The cadmium sorption capacities of the CMCH were 25.93, 27.94, and 35.94 mg of metal per gram dried hydrogel at pH 4.0, 5.0, and 6.0, respectively. The metal sorption capacity of both hydrogels increased with the increase in pH due to the deprotonation of amine and hydroxyl groups, as described above. Hydrogel anionic groups (-COO) are either partially or completely protonated (-COOH) at pH values lower than 4.7, decreasing the electrostatic attraction forces and physiochemical interactions with cadmium. Moreover, high proton concentrations in an aqueous solution with low pH hinder cadmium interaction due to competition effects. Hence, higher sorption capacities were obtained in pH values ranging from 4.7 to 6.0 [21]. Sorption was not evaluated at pH values higher than 6.0 due to the hydroxide precipitation of cadmium [47]. The presence of magnetite in the CMCH network decreased the sorption capacity due to the presence of FeOH2+ groups at pH values lower than 5.3. This is a result of the increase in the electrostatic repulsion forces between FeOH2+ and cadmium (II) ions. This effect is also observed at pH lower than 7.0 due to the protonation of magnetite in the polymer network [46].

Effect of initial pollutant concentration

The methylene blue (MB) (a) and cadmium (b) sorption capacities of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) as a function of initial pollutant concentrations are displayed in Fig. 6. The MB sorption capacity of the CBH ranged from 4.88 to 22.55 mg of dye per gram of dried hydrogel with the increase in the initial concentration from 10 to 30 mg L−1. The MB sorption capacity of the CMCH ranged from 4.54 to 22.56 mg of dye per gram of dried hydrogel with the increase in the initial concentration from 10 to 30 mg L−1. The cadmium sorption capacity of the CBH ranged from 8.37 to 75.12 mg of metal per gram dried hydrogel and from 4.10 to 66.12 mg of metal per gram dried CMCH with the increase in the initial concentration from 10 to 100 mg L−1. The sorption capacity increased with the increase in the initial pollutant concentrations due to the gradual occupation of active sites in the hydrogel networks. It is important to study the sorption isotherms (see the “Sorption isotherms” section).

Fig. 6
figure 6

Sorption capacities of the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH) as a function of the initial adsorbate concentration during the interaction of MB (a) and cadmium (b). Experimental conditions: 100 mg dried hydrogel weight, pH of the MB solution = 8.0, pH of the cadmium solution = 6.0, 100 mL solution volume, sorption time of 1440 min, and room temperature

Sorption isotherms

Figure 7 displays the nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherms for methylene blue (MB) interaction to the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Figure 8 displays the nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherms for cadmium interaction to the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Table 3 displays the isotherm parameters obtained after the nonlinear plots. The best isotherm fits for MB and cadmium interaction to both hydrogels were found using nonlinear three-parameter Redlich-Peterson and Sips isotherm models. These results were confirmed by the higher correlation coefficients (R2) and lower chi-square (χ2) test results, which are commonly applied to estimate errors in sorption isotherm plots [13, 48]. The R2 value is calculated using theoretical and experimental sorption capacities, whereas the χ2 value is calculated using the sum of the squares of the differences between the experimental data and data predicted by isotherm models [49]. When results predicted by isotherm models are similar to the experimental data, χ2 is close to zero [43]. Based on the isotherm results, and R2 and χ2 values, the sorption processes of MB and cadmium in the hydrogel networks take place by the formation of a monolayer and multisite interactions occurring simultaneously. This is in agreement with the water absorption mechanism for chitosan-based hydrogels determined by our research group [13]. The Langmuir constant (KL) values show that the sorption processes are specifically based on the binding affinity between MB or cadmium and active groups in the hydrogel structures [31]. The βS values obtained from the Sips isotherm model indicate interaction processes occurring on heterogeneous/homogeneous hydrogel structures, exactly as observed for three-dimensional polymer matrices [13]. The maximum MB sorption capacities of the CBH and CMCH were 23.389 and 23.478 mg of dye per gram of dried hydrogel, respectively, according to the nonlinear Sips isotherm model. The maximum cadmium sorption capacities of the CBH and CMCH were 90.038 and 80.383 mg of metal per gram of dried hydrogel, respectively, according to the nonlinear Sips isotherm model.

Fig. 7
figure 7

Nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherms for methylene blue (MB) interaction to the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Experimental conditions: sorption time of 1440 min, 100 mg dried hydrogel weight, 100 mL solution volume, pH = 8.0, and room temperature

Fig. 8
figure 8

Nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherms for cadmium interaction to the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Experimental conditions: sorption time of 1440 min, 100 mg dried hydrogel weight, 100 mL solution volume, and pH = 6.0, and room temperature

Table 3 Parameters of the nonlinear Langmuir, Freundlich, Redlich-Peterson, and Sips isotherms for the interaction of methylene blue (MB) and cadmium to the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH)

Sorption kinetics

Figure 9 displays the experimental and predicted results of the nonlinear pseudo-first-order, pseudo-second-order, and Elovich kinetic models for the interaction of methylene blue (MB) and cadmium to the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Table 4 shows the kinetic parameters of the nonlinear pseudo-first-order, pseudo-second-order, and Elovich models. The best kinetic fit for the interaction of MB to both CBH and CMCH was found using the nonlinear pseudo-second-order kinetic model, as demonstrated by the higher R2 values and lower χ2 values. One may assume that the chemical reaction between the hydrogel and MB is the main aspect controlling the sorption process and rate [21, 50]. This confirms a lower influence of hydrogel swelling during the sorption of MB. The best kinetic fit for the interaction of cadmium with the CBH was also found using the nonlinear pseudo-second-order kinetic model, whereas the best kinetic fit for the interaction of cadmium with the CMCH was the nonlinear pseudo-first-order kinetic model. These conclusions were also based on R2 and χ2 values. This suggests that the active-site occupation rate in the CMCH network is proportional to the number of non-occupied active sites. Thus, one may assume that each cadmium ion binds to a single active site in the hydrogel network, forming either a monolayer or multilayer of anchored metal [29, 51]. Overall, the change in kinetic behavior during the sorption of cadmium in the CBH and CMCH indicates that the removal of metals from aqueous solutions can be affected by both intermolecular interactions between the adsorbent and adsorbate and the degree of swelling of the hydrogel network. The α value of the Elovich model for the interaction of cadmium to the CBH was much higher than that found for the CMCH (αCBH >>> αCMCH), whereas the α value for the interaction of MB to the CBH was just slightly higher than that found for the CMCH (αCBH > αCMCH). Overall, a higher α value denotes higher the initial sorption rates, as observed experimentally. The higher initial pollutant sorption rates are associated with the higher swelling capacity of the CBH compared to the CMCH. The β values of the Elovich model were lower than 0.6, indicating significant physiochemical interactions of MB and cadmium in the hydrogel networks [22, 52]. This is in agreement with the isotherm results. Thus, we can conclude that the MB sorption rate-limiting step is mainly governed by intermolecular interactions, whereas the cadmium sorption rate-limiting step is governed by intermolecular interactions between the metal and hydrogel as well as the degree of swelling of the polymer network. Finally, the values of the predicted (qt) and experimental (qe) sorption capacities were similar, confirming that the MB and cadmium interactions in the CBH and CMCH are favorable.

Fig. 9
figure 9

Experimental and predicted results of the nonlinear pseudo-first-order, pseudo-second-order, and Elovich kinetic models for the interaction of methylene blue (MB) and cadmium to the chitosan-based hydrogel (CBH) (a) and chitosan/magnetite-based composite hydrogel (CMCH) (b). Experimental conditions: 50 mg L−1 initial cadmium concentration, 20 mg L−1 initial MB concentration; 100 mg dried hydrogel weight; 100 mL solution volume, pH = 8.0 for MB adsorption, pH = 6.0 for cadmium adsorption, and room temperature

Table 4 Kinetic parameters of the nonlinear pseudo-first order, pseudo-second order, and Elovich models for the interaction of methylene blue (MB) and cadmium to the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH)

Sorption thermodynamics

Table 5 displays the thermodynamics for the interactions of methylene blue (MB) and cadmium to the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH). The sorption capacity increased with the increase in temperature due to the faster mobility of the pollutants in the aqueous solutions and porous hydrogel networks, which decreases the activation energy and increases the intraparticle diffusion rate in porous structures [53, 54]. Moreover, macromolecular relaxation of the polymer network takes place at higher temperatures, facilitating intrapore diffusion processes and intermolecular interactions between the pollutant and hydrogel [13]. The positive ΔH° values indicate that the MB and cadmium sorption processes are endothermic at all temperatures studied, with the occurrence of possible physiochemical interactions [55]. As the ΔH° values were lower than 40 KJ mol−1, the sorption process must have been governed basically by physisorption. During physisorption phenomena, reversible intermolecular interactions take place that facilitate desorption processes as well as the recovery of pollutants and hydrogels [55, 56]. The positive ΔS° values indicate a system disorder during the sorption process due to the decrease in hydrogel dehydration [32]. The sorption process with CMCH was more organized due to the lower degree of swelling compared to the CBH.

Table 5 Thermodynamics for the interactions of methylene blue (MB) and cadmium to the chitosan-based hydrogel (CBH) and chitosan/magnetite-based composite hydrogel (CMCH)

Conclusion

The higher cadmium sorption capacity of the CBH compared to the CMCH is related to the presence of Fe3+/Fe2+ in the hydrophilic three-dimensional network. Fe3+/Fe2+ interact with anionic groups in the hydrogel network, decreasing the number of active sorption sites for interaction with cadmium. The lower MB sorption capacities of both hydrogels compared to cadmium sorption capacities were associated with the steric effects taking place in the organic molecule sorption processes. The isotherm results revealed that the sorption mechanism of MB and cadmium with both hydrogels is governed by monolayer formation and multi-site interactions. The main steps governing the sorption kinetics and rates involve chemical reactions and diffusions through pores during the hydrogel swelling. The sorption process is spontaneous, endothermic, and disorderly, depending on the hydrogel used. Overall, the chitosan-based hydrogel and chitosan/magnetite-based composite hydrogel could be employed as alternative solid matrices for the treatment of water and wastewater contaminated with metal ions and cationic dyes. These polymer materials could particularly be applied as solid sorbents for the removal of metal cations from battery production wastewater as well as for the removal of cationic dyes from textile wastewater. Future studies will be proposed for the recovery of hydrogels and pollutants as well as the production of sorption filters for water purification as a strategy for the replacement of conventional water purification filters. These studies could also focus on a reduction of organic matter in water and wastewater with the aim of generating reusable or potable water.