Self-Nitrogen-Doped Nanoporous Carbons Derived from Poly(1,5-diaminonaphthalene) for the Removal of Toxic Dye Pollutants from Wastewater: Non-Linear Isotherm and Kinetic Analysis

The high surface area and porosity of self-nitrogen-doped porous carbons (SNPCs) nominates them for potential application in water treatment due to their high efficiency towards the removal of various pollutants. In this study, SNPCs were fabricated from poly(1,5-diaminonaphthalene) (P(1,5-DANPh) by single and simultaneous carbonization at the activation step at different temperatures (600, 700, and 800 °C). The carbonization’s temperature plays a vital role in controlling the nitrogen-doping, surface area, porosity, and morphology of SNPCs. The SNPCs-7 sample prepared at 700 °C showed the highest surface area (1678.8 m2 g−1) with pore volume (0.943 cm3 g−1) with a micro/meso porous structure. The prepared SNPCs were used as an effective adsorbent for removal of crystal violet dye (CV) from contaminated water. SNPCs-7 showed the highest adsorption of 487.53 mg g−1 and the adsorption capacity of the SNPCs samples follows the order SNPCs-7 > SNPCs-8 > SNPCs-6, which is consistent with the results of their surface area and porosity. The adsorption for CV dye followed Freundlich isotherm models and a pseudo second order kinetic model. The negative values of Gipps free energy (ΔG°) and positive value of enthalpy (ΔH°) indicated that the adsorption of CV dye onto the surface of SNPCs was a spontaneous and endothermic process, respectively. Based on the results, the adsorption mechanism of CV dye onto the surface of SNPCs was proposed.


Introduction
The problem of providing potable and agricultural water is one of the most challenging that facing water-poor countries. Moreover, the problems of water scarcity and pollution of water that affect many countries encourage the researchers to develop new materials to overcome these problems [1,2]. The treatment and reuse of wastewater is one of the effective solutions to mitigate the problem of water scarcity and to protect the environment from pollution [3,4]. The industrial sector is one of the largest sectors that consumes a large amount of water due to most of its processes dependent on water [5]. Moreover, most of the water used in industrial processes is not completely consumed and is discharged wastewater that contains various pollutants. Among these industries that use large quantities of water are textile, cosmetics, printing, and the tanning industry, and the reuse of their wastewater will save water and reduce the environmental pollution [6]. To reuse wastewater, its treatment is necessary to eliminate pollutants such as dyes, which are the most dangerous one present in industrial wastewater with high toxicity and stability even at low concentrations [7]. Various methods such as coagulation [8], precipitation [9], photodegradation [10], biodegradation [11], and adsorption [12] 2.3. Preparation of Self-Nitrogen-Doped Porous Carbons (SNPCs) P(1,5-DANPh) and KOH were ground in a ratio of 1:4 by a regular blender and then the mixture was placed directly in vacuum oven overnight. The carbonization and activation processes were carried out semitonally in furnace tube for one hour at various temperatures (600, 700, and 800 • C) under nitrogen with temperature rate of 5 • C min −1 . After cooling the furnace to RT, the product was collected and dispersed in 1M of HCl with stirring for 2 h at 50 • C followed by filtration and washing several times with distillated water until neutral pH for the filtrate. The product (SNPCs) was dried in a vacuum oven overnight at 80 • C. The prepared samples are referred to as SNPCs-6, SNPCs-7 and SNPCs-8.

Characterization Self-Nitrogen-Doped Porous Carbons (SNPCs)
The prepared P(1,5-DANPh) and the corresponding SNPCs samples were characterized by routine techniques. Field emission scanning electron microscopy with energy dispersive X-ray (FESEM-EDX, JEOL2100F, Tokyo, Japan) spectroscopy was used to study the morphology and elemental analysis. The structure of polymer and the surface functional groups of SNPCs was identified by Fourier-transform infrared spectroscopy (FTIR, Thermo Fisher Scientific, Waltham, MA, USA) in the range of 400 to 4000 cm −1 using a KBr pellet. The crystallinity and graphitization degree of P(1,5-DANPh) and SNPCs were studied by X-ray diffraction (XRD, MiniFlex, Rigaku, Tokyo, Japan). The textural characteristics (e.g., pore volume, pore size and surface area) of the P(1,5-DANPh) and SNPCs was evaluated by using Brunauer-Emmett-Teller analysis (BET, Micromeritics-ASAP-2020, Micromeritics, Norcross, GA, USA) conducted via N 2 adsorption at 77 K. The thermal behavior of P(1,5-DANPh) and SNPCs was studied using thermogravimetric analysis (TGA, Q500-USA, Canberra, Australia). Zeta potential values were measured at different pH values and carried out by Zeta potential (Nano Plus zet/nano, Gerbrunn, Germany) through the dispersion of 10 mg of adsorbent in 10 mL distillated water by sonication for 5 min at 25 • C before measurement.

Adsorption Study
The adsorption of CV dye onto SNPCs was studied in batches via many parameters, including the effect of pH, ionic strength, initial concentration of CV dye, contact time, as well as temperature.
The adsorption experiments were conducted in 20-mL polypropylene tubes. To 10 mL of dye solution at pH 10, the adsorbent (10 mg) was added and shaken using a thermostat shaker water bath at a speed of 70 rpm for 4 h. Then, the tubes were put in a tube holder for 15 min to settle the adsorbent, and the supernatant was collected for the measurement of unadsorbed CV dye. The residual concentration of CV dye was measured using a UV/Vis spectrophotometer (Perkin-Elmer, Lambda 35, Buckinghamshire, UK) at λ max = 589 nm. The effect of pH on the adsorption of CV dye was conducted at pH 3 (acidic), pH 7 (neutral), and pH 10 (alkaline). All media were adjusted by 0.1 mol L −1 of HCl or NaOH. The effect of ionic strength was performed at different concentration of NaCl (0.1, 0.3 and 0.5 mol L −1 ) at pH 10, 500 mg L −1 of CV dye and adsorbent dosage 10 mg. The effect of initial concentration of CV dye was studied by carrying out the adsorption experiments in the concentration range between 100 and 800 mg L −1 at room temperature.
Kinetic studies were done by adding 10 mg of the adsorbents was to 10 mL of CV dye solution (300 mg L −1 ) under agitation at 25 • C. The concentration of the residual CV dye was followed by measuring the absorbance at regular time intervals by taken 100 µL of dye solution which was diluted to 3 mL with distilled water. The efficiency of the adsorbent and the amount of adsorbed CV dye onto the adsorbents at equilibrium (q e , mg g −1 ) and time t (q t , mg g −1 ) were calculated using the following Equations (1)-(3): % Removal e f f iciency = where C o , C t , and C e (mg L −1 ) are the initial, t time, and equilibrium concentrations of the dye solution, respectively. V (L) is the volume of dye solution and m (g) is the adsorbents mass.

Desorption Study
The adsorption-desorption of CV dye was conducted in 20-mL polypropylene tubes by adding 10 mg of the adsorbent to 10 mL of CV dye (100 mg L −1 ) and placing on a thermostat shaker water bath at a speed of 70 rpm for 2 h. The tube was placed on the holder for 15 min to settle out the adsorbent and the supernatant solution was completely taken and the absorbance was measured. The desorption process was carried out by adding 10 mL of ethanol and 100 µL of HCl (0.1 mol L −1 ) as desorption agent to the adsorbent, shaking for 5 min, then let to settle the adsorbent. Finally, the adsorbent was left to settle out and the absorbance of the desorbed solution of dye was measured as mentioned earlier.
The adsorption-desorption process was repeated for five cycles.

Error Analysis
The nonlinear regression method is a reliable tool to define the best fitting experimental data of adsorption and kinetic process. To determine the best kinetic and isotherm model for representing experimental data, Chi-square values (χ 2 ) and coefficient of determination values (R 2 ) were calculated for the nonlinear method by Equations (4)- (6). The model with the lowest value of χ 2 and the highest value of R 2 is the most representative of the experimental data and the least error.
(q e,exp − q e,mean ) 2 (5) where q e,model is each value of q e predicted by the fitted model, (q e,exp ) is each value of q e measured experimentally, q e,mean is the average value of q e that was measured experimentally, n p is the number of performed experiments, and p is the number of parameters for the fitted model.

Characterization of Self-Nitrogen-Doped Porous Carbons (SNPCs)
3.1.1. Morphology of (SNPCs) Figure 1 displays the low and high-resolution FESEM images of SNPCs that was prepared at three-different temperatures. Figure 1a and b showed that the SNPCS-6 sample has flake shape and macroporous structure with open channels. Upon increasing the temperature to 700 • C, the flake Polymers 2020, 12, 2563 5 of 20 shape changed to a herringbone shape and connected pore channels with a lesser size increased with a uniform distribution and porous structure, as shown in Figure 1c,d. The high and uniform porosity of SNPCS-7 is attributed to deeper etching arising from increasing the temperature. However, the increase in temperature to 800 • C led to the agglomeration and the conversion of the flake shape to spherical form accompanied with the damage of the interconnected channels and mesoporous structure in SNPCS-8, as shown in Figure 1e,f. The morphology of SNPCs after adsorption CV dye was also investigated, as shown in Supplementary Figure S4. After adsorption dye, the surface of SNPCs and pores became more smother, implying that CV dye molecules had attached to the SNPCs surface.
Polymers 2020, 12, 2563 5 of 20 was also investigated, as shown in Supplementary Figure S4. After adsorption dye, the surface of SNPCs and pores became more smother, implying that CV dye molecules had attached to the SNPCs surface.

BET Analysis
Isotherms of nitrogen adsorption-desorption and the pore size distributions are displayed in Figure 2 and the textural characteristic properties of SNPCs are listed in Table 1. SNPCs samples show Type I isotherm and amount of adsorbed nitrogen increased rapidly at pressure less than 0.2. This result confirms a high affinity between adsorbent and adsorbate; and the adsorbent possess micropores structure. However, samples SNPCs-7 and SNPCs-8 also exhibit Type IV isotherm which indicted to also them possess a mesoporous structure. The mesoporous ratio of the SNPCs samples increase with the temperature of carbonization, and were 26.38%, 74.70%, and 91.98 % for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. The average of pore width of SNPCs-6, SNPCs-7, and SNPCs-8 was 2.28, 2.25, and 3.1 nm, respectively. Interestingly, the SNPCs-7 exhibits the highest surface area (1678.8 m 2 g −1 ) with pore volume (0.943 cm 3 g −1 ). The order of the surface area and pore volume followed SNPCs-7 ˃ SNPCs-8 ˃ SNPCs-6. Based on the FESEM and BET results, it can be concluded that the temperature of the carbonization activation process plays an essential role in creating porous structures and the optimum temperature is 700 °C for the preparation of self-nitrogen doped porous carbons, which are characterized by high surface area and micro/meso porous structure. Similarly, Tian et al. have found the optimized temperature of carbonization to produce porous carbon from

BET Analysis
Isotherms of nitrogen adsorption-desorption and the pore size distributions are displayed in Figure 2 and the textural characteristic properties of SNPCs are listed in Table 1. SNPCs samples show Type I isotherm and amount of adsorbed nitrogen increased rapidly at pressure less than 0.2. This result confirms a high affinity between adsorbent and adsorbate; and the adsorbent possess micropores structure. However, samples SNPCs-7 and SNPCs-8 also exhibit Type IV isotherm which indicted to also them possess a mesoporous structure. The mesoporous ratio of the SNPCs samples increase with the temperature of carbonization, and were 26.38%, 74.70%, and 91.98 % for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. The average of pore width of SNPCs-6, SNPCs-7, and SNPCs-8 was 2.28, 2.25, and 3.1 nm, respectively. Interestingly, the SNPCs-7 exhibits the highest surface area (1678.8 m 2 g −1 ) with pore volume (0.943 cm 3 g −1 ). The order of the surface area and pore volume followed SNPCs-7 > SNPCs-8 > SNPCs-6. Based on the FESEM and BET results, it can be concluded that the temperature of the carbonization activation process plays an essential role in creating porous structures and the optimum temperature is 700 • C for the preparation of self-nitrogen doped porous carbons, which are characterized by high surface area and micro/meso porous structure. Similarly, Tian et al. have found the optimized temperature of carbonization to produce porous carbon from cellulose with a high surface area was 700 • C [30].   Figure 3 shows the FTIR spectra of P(1,5-DANPh) and SNPCs. The FTIR spectrum of P(1,5-DANPh) showed multiple peaks in the range of 400-4000 cm −1 and most of them disappeared after the carbonization activation process. The FTIR spectrum of P(1,5-DANPh) showed multiple peaks at 3358, 2873, 1630, 1596-1417, 1293, 1117, and 815-518 cm −1 , which are related to N-H stretching, -C=NH+-stretching, C=N stretching, C=C stretching, C-N stretching for primary amine, C-C interring, and C-H out-of-plane, respectively [31]. Most of its peaks disappeared after the carbonization activation process. This result indicates that the polymer is completely converted to SNPCs product. The sample of SNPCs-6 has only two characteristic peaks at 1601 and 1227 cm −1 , which were attributed to C=C and C-N stretching vibration, respectively. These results indicated the success of the carbonization process and the conversion of P(1,5-DANPh) into nitrogen-doped carbon structure, while the activation process is incomplete. As the carbonization activation temperature was increased, new characteristic peaks for SNPCs-7 and SNPCs-8 appeared at 3437 and 1113 cm −1 ; and at 3436, 958, 796, and 465 cm −1 , respectively. These were attributed to the presence of oxygencontaining functional groups that were formed on the surface of SNPCs by the activation process using KOH, which is more effective at both 700 and 800 °C.

EDX Analysis
The EDX analysis of SNPCs samples confirmed the presence of the elements; carbon, nitrogen and oxygen ( Figure 4). The amount of the doped nitrogen depends mainly on the temperature of calcination-activation process, and it was found to be 17.69%, 14.94%, and 6.62% for SNPCS-6, SNPCS-7, and SNPCS-8, respectively. The obtained results confirmed the high self-nitrogen doping and the creation of oxygen-containing functional groups on the surface of the porous carbon structure obtained by the carbonization activation process.    Figure 3 shows the FTIR spectra of P(1,5-DANPh) and SNPCs. The FTIR spectrum of P(1,5-DANPh) showed multiple peaks in the range of 400-4000 cm −1 and most of them disappeared after the carbonization activation process. The FTIR spectrum of P(1,5-DANPh) showed multiple peaks at 3358, 2873, 1630, 1596-1417, 1293, 1117, and 815-518 cm −1 , which are related to N-H stretching, -C=NH+stretching, C=N stretching, C=C stretching, C-N stretching for primary amine, C-C inter-ring, and C-H out-of-plane, respectively [31]. Most of its peaks disappeared after the carbonization activation process. This result indicates that the polymer is completely converted to SNPCs product. The sample of SNPCs-6 has only two characteristic peaks at 1601 and 1227 cm −1 , which were attributed to C=C and C-N stretching vibration, respectively. These results indicated the success of the carbonization process and the conversion of P(1,5-DANPh) into nitrogen-doped carbon structure, while the activation process is incomplete. As the carbonization activation temperature was increased, new characteristic peaks for SNPCs-7 and SNPCs-8 appeared at 3437 and 1113 cm −1 ; and at 3436, 958, 796, and 465 cm −1 , respectively. These were attributed to the presence of oxygen-containing functional groups that were formed on the surface of SNPCs by the activation process using KOH, which is more effective at both 700 and 800 • C.

EDX Analysis
The EDX analysis of SNPCs samples confirmed the presence of the elements; carbon, nitrogen and oxygen ( Figure 4). The amount of the doped nitrogen depends mainly on the temperature of calcination-activation process, and it was found to be 17.69%, 14.94%, and 6.62% for SNPCS-6, SNPCS-7, and SNPCS-8, respectively. The obtained results confirmed the high self-nitrogen doping and the creation of oxygen-containing functional groups on the surface of the porous carbon structure obtained by the carbonization activation process.   3.1.5. XRD Analysis Figure 5 displays the XRD analysis of P(1,5-DANPh) and SNPCs samples. As shown in Figure 5, P(1,5-DANPh) showed sharp diffraction peaks that reflect its high degree of crystallinity. During the carbonization activation process, most diffraction peaks of polymer disappeared and SNPCs showed only two broad peaks at 21.6 • and 42.5 • due to the conversion of the polymer to the disordered graphite structure and a slight ratio of transformation to the graphite composition, respectively. The interlayer spacing of SNPCS-6, SNPCS-7, and SNPCS-8 was 0.411, 0.425 nm, and 0.398 nm, respectively, which is bigger than that of graphite (0.335 nm). This result indicated that SNPCs samples have the highest ratio of C-C(sp 3 ) bond and more disordered structure due to the formation of oxygen-containing functional groups during the activation process [32]. 3.1.5. XRD Analysis Figure 5 displays the XRD analysis of P(1,5-DANPh) and SNPCs samples. As shown in Figure  5, P(1,5-DANPh) showed sharp diffraction peaks that reflect its high degree of crystallinity. During the carbonization activation process, most diffraction peaks of polymer disappeared and SNPCs showed only two broad peaks at 21.6° and 42.5° due to the conversion of the polymer to the disordered graphite structure and a slight ratio of transformation to the graphite composition, respectively. The interlayer spacing of SNPCS-6, SNPCS-7, and SNPCS-8 was 0.411, 0.425 nm, and 0.398 nm, respectively, which is bigger than that of graphite (0.335 nm). This result indicated that SNPCs samples have the highest ratio of C-C(sp 3 ) bond and more disordered structure due to the formation of oxygen-containing functional groups during the activation process [32].

Thermogravimetric Analysis
The thermal decomposition of P(1,5-DANPh) and samples was studied by TGA-DTA as shown in Figure 6. The thermogram of P(1,5-DANPh) showed that the degradation takes place in single step in the range 230-270 °C, peaked at 300 °C (Tmax) and leaving residue of 49.39% at 800 °C. The high percentage of residue reflects the importance of P(1,5-DANPh) as a promising polymer for the preparation of self-nitrogen-doped porous carbon materials. It noteworthy that the thermal stability of SNPCs depends on the temperature of carbonization-activation process as can be seen in Figure 6. SNPCs showed good thermal stability and the residual at 800 °C was found to be 75.59, 82.96, and 87.44 °C for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. Three steps of thermal decomposition for SNPCs samples took place, at which the first step was assigned to the decomposition of less stable oxygen containing functional groups such as carboxylic groups resulting from the activation process at 200-400 °C. The second step was assigned to the decomposition of more stable oxygen containing functional groups such as hydroxyl groups at 500-600 °C. The third step is attributed to the partial collapse of the carbon structure and the liberation of doped nitrogen as nitrogen gas over 600 °C.

Thermogravimetric Analysis
The thermal decomposition of P(1,5-DANPh) and samples was studied by TGA-DTA as shown in Figure 6. The thermogram of P(1,5-DANPh) showed that the degradation takes place in single step in the range 230-270 • C, peaked at 300 • C (T max ) and leaving residue of 49.39% at 800 • C. The high percentage of residue reflects the importance of P(1,5-DANPh) as a promising polymer for the preparation of self-nitrogen-doped porous carbon materials. It noteworthy that the thermal stability of SNPCs depends on the temperature of carbonization-activation process as can be seen in Figure 6. SNPCs showed good thermal stability and the residual at 800 • C was found to be 75.59, 82.96, and 87.44 • C for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. Three steps of thermal decomposition for SNPCs samples took place, at which the first step was assigned to the decomposition of less stable oxygen containing functional groups such as carboxylic groups resulting from the activation process at 200-400 • C. The second step was assigned to the decomposition of more stable oxygen containing functional groups such as hydroxyl groups at 500-600 • C. The third step is attributed to the partial collapse of the carbon structure and the liberation of doped nitrogen as nitrogen gas over 600 • C.

Effect of pH
pH plays an important role in the adsorption process of pollutants, especially for ionic pollutants, in functionalized carbon materials. This was assigned to the change in electrostatic attraction between the ionic dye molecules and the surface of adsorbent. Therefore, pH effect on the adsorption capacity of CV dye onto the SNPCs-6, SNPCs-7 and SNPCs-8 was studied at acidic, neutral and alkaline media at 25 °C and CV concentration of 500 ppm. Figure 7 showed that the adsorption capacity of CV dye onto all adsorbents has no noticeable change in both acidic (pH 3) and neutral (pH 7) media but in alkaline medium (pH 10) there is a significant increase in the adsorption capacity of SNPCs-6 and SNPCs-8. In alkaline medium, the ionization of oxygen-containing groups increased, resulting in the formation of an anionic surface of SNPCs, which can be more suitable for the adsorption of cationic CV dye. Due to the pKa value of phenolic groups being approximately 8.0-9.0, the surface charge of SNPCs the SNPCS-6, SNPCS-7, and SNPCS-8 will become predominantly negative at pH higher than the pKa. From the obtained results, the performance of SNPCs-6 and SNPCs-8 as adsorbents for CV dye was improved in alkaline media while SNPCS-7 is an effective adsorbent in all pH's. These results indicated the important role of pores@SNPCs-7 in the adsorption process across the diffusion of dye through it. The zeta potential vs. initial pH of SNPCs was studied as shown in Figure 7b. The charge on the surface of SNPCs-7, SNPCs-7, and SNPCs-8 is correlated with pH values of solution and they exhibit a negative charge at pH 7 and 11. This result agrees with that result of pH's effect on adsorption capacity.

Effect of pH
pH plays an important role in the adsorption process of pollutants, especially for ionic pollutants, in functionalized carbon materials. This was assigned to the change in electrostatic attraction between the ionic dye molecules and the surface of adsorbent. Therefore, pH effect on the adsorption capacity of CV dye onto the SNPCs-6, SNPCs-7 and SNPCs-8 was studied at acidic, neutral and alkaline media at 25 • C and CV concentration of 500 ppm. Figure 7 showed that the adsorption capacity of CV dye onto all adsorbents has no noticeable change in both acidic (pH 3) and neutral (pH 7) media but in alkaline medium (pH 10) there is a significant increase in the adsorption capacity of SNPCs-6 and SNPCs-8. In alkaline medium, the ionization of oxygen-containing groups increased, resulting in the formation of an anionic surface of SNPCs, which can be more suitable for the adsorption of cationic CV dye. Due to the pK a value of phenolic groups being approximately 8.0-9.0, the surface charge of SNPCs the SNPCS-6, SNPCS-7, and SNPCS-8 will become predominantly negative at pH higher than the pK a . From the obtained results, the performance of SNPCs-6 and SNPCs-8 as adsorbents for CV dye was improved in alkaline media while SNPCS-7 is an effective adsorbent in all pH's. These results indicated the important role of pores@SNPCs-7 in the adsorption process across the diffusion of dye through it. The zeta potential vs. initial pH of SNPCs was studied as shown in Figure 7b. The charge on the surface of SNPCs-7, SNPCs-7, and SNPCs-8 is correlated with pH values of solution and they exhibit a negative charge at pH 7 and 11. This result agrees with that result of pH's effect on adsorption capacity.

Effect of Ionic Strength
The ionic strength effect on adsorption of CV dye onto SNPCs can assist the interpretation of the adsorption mechanism. Figure 8 showed that the increase in the concentration of NaCl results is accompanied with an increase in the adsorption capacity of CV dye onto SNPCs-6 and SNPCs-8 compared to slightly increase onto SNPCs-7. With increasing the concentration of NaCl from 0 to 0.3 mol L −1 , the adsorption capacity was increased from 111.21, 460.77, 323.86 to 459.37, 492.58, and 468.68 mg g −1 for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. This increase in adsorption capacity onto SNPCs is due to the decrease in interactions between CV dye and water molecules due to the presence of sodium cations. Subsequently, the affinity of CV molecules to be adsorbed onto the surface of SNPCs was enhanced. These results are compatible with the obtained results for the effect of pH, which revealed the main role of the electrostatic interaction in adsorption of the CV dye onto SNPCs-6 and SNPCs-8, while that onto SNPCs is less.

Effect of Ionic Strength
The ionic strength effect on adsorption of CV dye onto SNPCs can assist the interpretation of the adsorption mechanism. Figure 8 showed that the increase in the concentration of NaCl results is accompanied with an increase in the adsorption capacity of CV dye onto SNPCs-6 and SNPCs-8 compared to slightly increase onto SNPCs-7. With increasing the concentration of NaCl from 0 to 0.3 mol L −1 , the adsorption capacity was increased from 111.21, 460.77, 323.86 to 459.37, 492.58, and 468.68 mg g −1 for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. This increase in adsorption capacity onto SNPCs is due to the decrease in interactions between CV dye and water molecules due to the presence of sodium cations. Subsequently, the affinity of CV molecules to be adsorbed onto the surface of SNPCs was enhanced. These results are compatible with the obtained results for the effect of pH, which revealed the main role of the electrostatic interaction in adsorption of the CV dye onto SNPCs-6 and SNPCs-8, while that onto SNPCs is less.

Effect of Ionic Strength
The ionic strength effect on adsorption of CV dye onto SNPCs can assist the interpretation of the adsorption mechanism. Figure 8 showed that the increase in the concentration of NaCl results is accompanied with an increase in the adsorption capacity of CV dye onto SNPCs-6 and SNPCs-8 compared to slightly increase onto SNPCs-7. With increasing the concentration of NaCl from 0 to 0.3 mol L −1 , the adsorption capacity was increased from 111.21, 460.77, 323.86 to 459.37, 492.58, and 468.68 mg g −1 for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. This increase in adsorption capacity onto SNPCs is due to the decrease in interactions between CV dye and water molecules due to the presence of sodium cations. Subsequently, the affinity of CV molecules to be adsorbed onto the surface of SNPCs was enhanced. These results are compatible with the obtained results for the effect of pH, which revealed the main role of the electrostatic interaction in adsorption of the CV dye onto SNPCs-6 and SNPCs-8, while that onto SNPCs is less.

Effect of Initial Concentration and Adsorption Isotherm Study
The affinity between adsorbate and adsorbent can be interpreted by isotherm models, which is a helpful tool for describing the relationship between the residual concentration of the adsorbate in solution and its concentration on the surface of the adsorbent at a constant temperature. Currently, non-linear isotherm models like Langmuir [33], Freundlich [34], Langmuir-Freundlich [35], and Dubbinin-Radushkevich [36] were applied to study the adsorption behavior of CV dye onto the SNPCs. Supplementary Table S1 displays the equation and parameters of all used isotherm models. The relationship between the residual concentration of CV dye (C e , mg L −1 ) and the adsorption capacity (q e , mg g −1 ) of SNPCs and fitting of non-linear isotherm models are shown in Figure 9. The corresponding parameters of isotherm are listed in Table 2. To determine the best model to fit the equilibrium data and to describe the adsorption behavior, values of R 2 red and χ 2 red were calculated for each model. Low values of χ 2 red and high values R 2 red imply a high resemblance between the experiment and the model. Accordingly, the best isotherm model to describe the adsorption of the CV dye onto the surfaces of SNPCs-7 and SNPCs-8 followed Freundlich model while onto the surface of SNPCs-6 followed Langmuir-Freundlich model. Thus, it can be concluded that the multilayers of CV dye onto specific heterogeneous sites of the SPNCs surface occurred at equilibrium. The Dubbinin-Radushkevich model was used for calculating the adsorption energy (E, kJ mol −1 ), where the adsorption takes place physically at value less than 8 kJ mol −1 , while the adsorption is chemically at higher value than 8 kJ mol −1 . As listed in Table 2, the obtained result confirmed the physical adsorption process and agrees with the thermodynamic and desorption study. Thus, it can be concluded that the adsorption mechanism of CV onto SNPCs can be achieved by physical interaction such as electrostatic interaction, hydrogen bonding interaction, as well as π-π and n-π interaction. In addition, pore filling plays role in the adsorption process, especially on onto SNPCs-7. The maximum adsorption capacity (Q max , mg g −1 ) followed the order: SNPCs-7 (487.53 mg g −1 ) > SNPCs-8 (332.02 mg g −1 ) > SNPCs-6 (134.08 mg g −1 ), which agree with the order of the surface area and porosity. The affinity between adsorbate and adsorbent can be interpreted by isotherm models, which is a helpful tool for describing the relationship between the residual concentration of the adsorbate in solution and its concentration on the surface of the adsorbent at a constant temperature. Currently, non-linear isotherm models like Langmuir [33], Freundlich [34], Langmuir-Freundlich [35], and Dubbinin-Radushkevich [36] were applied to study the adsorption behavior of CV dye onto the SNPCs. Supplementary Table S1 displays the equation and parameters of all used isotherm models. The relationship between the residual concentration of CV dye (Ce, mg L −1 ) and the adsorption capacity (qe, mg g −1 ) of SNPCs and fitting of non-linear isotherm models are shown in Figure 9. The corresponding parameters of isotherm are listed in Table 2. To determine the best model to fit the equilibrium data and to describe the adsorption behavior, values of R 2 red and χ 2 red were calculated for each model. Low values of χ 2 red and high values R 2 red imply a high resemblance between the experiment and the model. Accordingly, the best isotherm model to describe the adsorption of the CV dye onto the surfaces of SNPCs-7 and SNPCs-8 followed Freundlich model while onto the surface of SNPCs-6 followed Langmuir-Freundlich model. Thus, it can be concluded that the multilayers of CV dye onto specific heterogeneous sites of the SPNCs surface occurred at equilibrium. The Dubbinin-Radushkevich model was used for calculating the adsorption energy (E, kJ mol −1 ), where the adsorption takes place physically at value less than 8 kJ mol −1 , while the adsorption is chemically at higher value than 8 kJ mol −1 . As listed in Table 2, the obtained result confirmed the physical adsorption process and agrees with the thermodynamic and desorption study. Thus, it can be concluded that the adsorption mechanism of CV onto SNPCs can be achieved by physical interaction such as electrostatic interaction, hydrogen bonding interaction, as well as π-π and n-π interaction. In addition, pore filling plays role in the adsorption process, especially on onto SNPCs-7. The maximum adsorption capacity (Qmax, mg g −1 ) followed the order: SNPCs-7 (487.53 mg g −1 ) ˃ SNPCs-8 (332.02 mg g −1 ) ˃ SNPCs-6 (134.08 mg g −1 ), which agree with the order of the surface area and porosity.、

Effect of Contact Time and Kinetic Study
The mechanism and the rate of adsorption process can be interpreted in terms of kinetic parameters to show the efficiency of adsorbent materials. Figure 10 displays the effects of the contact time on the adsorption capacity of adsorbents towards the removal of CV dye. The adsorption capacity increased rapidly within the initial 20 min followed by slightly increase until the establishment of the equilibrium after 60 min. Within the first 5 min, 16.5%, 60.2%, and 44.3% were removed from the total CV dye concentration (300 mg L −1 ) by SNPCs-6, SNPCs-7, and SNPCs-8, respectively. This instantaneous phenomenon of adsorption indicated to the high affinity of SNPCs towards the adsorption of CV dye molecules. Currently, the adsorption kinetic of SNPCs-6, SNPCs-7, and SNPCs-8 were studied by non-linearized forms, namely pseudo-first-order (PFO) [37], pseudo-second-order (PSO) [38], and Elovich [39] models, as well as linearized forms of the intraparticle diffusion model, as listed in Table 3 and Supplementary Table S2, which displays the equation and parameters of all used kinetic models. According to the low values of nonlinear reduced chi-square statistics (χ 2 red ) and high values of reduced determination coefficients (R 2 red ), the best model for describing the adsorption kinetic of CV onto surface of SNPCs was the PSO model (χ 2 = 13.81 − 0.817 and R 2 = 0.9992 − 0.9998), compared to the PFO and Elovich models. Furthermore, the calculated value of the adsorption capacity (q e,cal .) was found to be much closer to the experimental value (q e,exp ). diffusion was not only the rate-limiting step for the adsorption process but it was achieved simultaneously by more than one adsorption mechanism. Moreover, the values of Kid (1) for the intraparticle diffusion step are smaller than that of the film diffusion on the external surface. This result indicates that the transferring of CV dye from the external surface to pores is a gradual process.    In porous materials, the adsorption kinetics by intraparticle diffusion model is an appropriate method for studying the mechanism for the transfer of dye from the surface to the pores. The two linear plots were obtained due to the varying extent of adsorption in the initial and final steps of adsorption experiment. The first step took place quickly and was assigned to the diffusion of CV from the solution to the external surface of SNPCs. The second step proceeded more slowly and was attributed to intraparticle diffusion effects. As shown in Supplementary Figure S2, the linear plot of SNPCs−6, SNPCs-7, and SNPCs-8 did not pass through the origin, confirming that the intraparticle diffusion was not only the rate-limiting step for the adsorption process but it was achieved simultaneously by more than one adsorption mechanism. Moreover, the values of Kid (1) for the intraparticle diffusion step are smaller than that of the film diffusion on the external surface. This result indicates that the transferring of CV dye from the external surface to pores is a gradual process.

Effect of Temperature and Thermodynamic Studies
The effect of temperature on adsorption of adsorbate has a great role in describing the interaction between the adsorbent and adsorbate. The thermal experiments were performed at different temperatures (25,35 Figure S3a). The increase in the adsorption capacity with temperature may be due to the decrease in the viscosity of CV dye, which facilitates the transfer of dye molecules from the outer surface into the pores of adsorbents. The obtained results agree with that obtained by Aichour [40] for the adsorption of CV dye by composite of activated bentonite/alginate.
The benefits of the adsorption process and the interaction mechanism between CV dye and adsorbent were investigated through the calculations of the thermodynamic parameters including free energy change (∆G • ), enthalpy (∆H • ), and entropy (∆S • ), using the following equations: where T is the absolute temperature (K) and R is universal gas constant (8.3144 J mol −1 K −1 ). K c is the equilibrium constant that represents the ratio of the concentration of adsorbate on adsorbent (C ad ) to the residual adsorbate concentration in solution at equilibrium state (C e ). The values of ∆H • , ∆G • , and ∆S • were calculated from the slope and intercept of the plot of lnK c with respect to 1/T (Supplementary Figure S3b), and presented results in Table 4. According to the negative values of ∆G • in the temperature range of 25-45 • C, the adsorption of CV dye onto SNPCs was feasible and spontaneous. Also, the increase in the absolute values of ∆G • at high temperatures indicated that the adsorption was favorable at higher temperatures. The positive values of ∆H • and ∆S • confirmed that the adsorption process was exothermic and the randomness increased at the solid-liquid interface, respectively, which was also supported by increasing the removal of CV with the increasing the temperature.

Recycle Study
The study of adsorption/desorption process plays an important role in clarifying the adsorption mechanism and the possibility of reusing the adsorbent and recovering the adsorbate. The reuse of adsorbent has a close relation with practical application in industries due to its cost depending on the regeneration process. In this work, the reusability and stability of the prepared adsorbents were investigated by subjecting them to five successive adsorption/desorption cycles. Figure 11 showed that the removal efficiency of all adsorbents was stable over five cycles. The adsorption efficiency after five cycles was found to be 58.05%, 99.15% and 99% for SNPCs-6, SNPCs-7, and SNPCs-8, respectively. It can be concluded that SNPCs can be used repeatedly without a loss of removal efficiency.

Proposed Mechanism of Adsorption
The proposed mechanism of adsorption can be proposed through the obtained results of the effect of pH, ionic strength, zeta potential measurement, as well as FTIR analysis after the adsorption of dye. On the basis of the effect of pH, ionic strength and zeta potential values, the adsorption capacity was varied which reflects the role of the electrostatic interaction between SNPCs and CV dye in the mechanism of adsorption. However, based on the FTIR of SNPCs after adsorption of dye, the hydrogen bonding is another role as well (Figure 12a). Figure 12a showed that the characteristic peaks of -OH bands were decreased and slightly shifted after adsorption, from 3445 to 3437 cm −1 for SNPCs-7 and 3436 to 3432 cm −1 for SNPCs-8. This result confirmed the formation of hydrogen bonding between the hydroxyl groups as H-donor on the surface of SNPCs-7 and SNPCs-8 and the nitrogen or oxygen atom as H-acceptor [41]. Similarly, slight shifting in the peaks of C=N and C=C groups and a decrease in the intensity also occurred, indicating that n-π and π-π interaction plays a role as well in the adsorption mechanism. Although oxygen containing functional groups on the surface of SNPCs-8 sample were higher than in SNPCs-7 and SNPCs-6, as confirmed by the EDX and FTIR results, the adsorption capacity of SNPCs-7 was higher than all, which clearly indicates that

Proposed Mechanism of Adsorption
The proposed mechanism of adsorption can be proposed through the obtained results of the effect of pH, ionic strength, zeta potential measurement, as well as FTIR analysis after the adsorption of dye. On the basis of the effect of pH, ionic strength and zeta potential values, the adsorption capacity was varied which reflects the role of the electrostatic interaction between SNPCs and CV dye in the mechanism of adsorption. However, based on the FTIR of SNPCs after adsorption of dye, the hydrogen bonding is another role as well (Figure 12a). Figure 12a showed that the characteristic peaks of -OH bands were decreased and slightly shifted after adsorption, from 3445 to 3437 cm −1 for SNPCs-7 and 3436 to 3432 cm −1 for SNPCs-8. This result confirmed the formation of hydrogen bonding between the hydroxyl groups as H-donor on the surface of SNPCs-7 and SNPCs-8 and the nitrogen or oxygen atom as H-acceptor [41]. Similarly, slight shifting in the peaks of C=N and C=C groups and a decrease in the intensity also occurred, indicating that n-π and π-π interaction plays a role as well in the adsorption mechanism. Although oxygen containing functional groups on the surface of SNPCs-8 sample were higher than in SNPCs-7 and SNPCs-6, as confirmed by the EDX and FTIR results, the adsorption capacity of SNPCs-7 was higher than all, which clearly indicates that pore filling plays an important role in the mechanism of adsorption. Figure 12b showed the proposed adsorption mechanism of CV dye onto surface of SNPCs.
Polymers 2020, 12,2563 16 of 20 pore filling plays an important role in the mechanism of adsorption. Figure 12b showed the proposed adsorption mechanism of CV dye onto surface of SNPCs.  Table 5 shows the adsorption capacity (q e , mg g −1 ) of SNPCs towards the removal of CV dye compared to other carbon materials and their composites. According to obtained results, it can be concluded that the SNPCs derived from P(1,5-DANPh) has remarkable higher adsorption capacity than all other carbon materials and their composites. This result reflects a promising future the importance of SNPCs materials for the removal of cationic dyes from wastewater.

Conclusions
SNPCs materials have been successfully prepared from P(1,5-DANPh) by single-step carbonization simultaneously with an alkali activation process. This approach represents a low-cost, efficient, and more productive method to obtain an effective adsorbent with high surface area and porosity. According to the results, the SNPCs-7 sample showed the highest surface area (1678.8 m 2 g −1 ) with a micro-mesoporous structure. The isotherm study suggested that the best model for describing adsorption behavior was the Freundlich model. The maximum adsorption capacities at 25 • C were ranked as follows: SNPCs-7 (487.53 mg g −1 ) > SNPCs-8 (332 mg g −1 ) > SNPCs-6 (134.1 mg g −1 ). According to the kinetic study, the adsorption was fast, followed by the PSO model, and an equilibrium state could be reached after 60 min. Moreover, the percentage of dye removal was 44.3% by the SNPCs-7 sample during the first 5 min. The prepared SNPCs showed an excellent regeneration capacity in that it can be used more than five times in succession without a significant decrease in the adsorption efficiency. The effect of pH, desorption study, and FTIR analysis confirmed that the adsorption of CV dye onto the surface of SNPCs was reversible and controlled by more than one mechanism, including electrostatic interaction, π−π stacking, hydrogen bonding, and intraparticle diffusion. The thermodynamic parameters and mean energy values calculated from the D-R model indicated that the adsorption of CV dye on the SNPCs is a spontaneous, endothermic physisorption. Due to this simple and easy preparation method, unique properties, and high efficiency, SNPCs-7 is a promising, low-cost, and effective adsorbent for removing cationic dyes from contaminated water.