Sulfur dioxide (SO2), ammonia (NH3), and nitrogen dioxide (NO2) are toxic gases that pollute the environment [1, 2]. SO2 gas is produced by burning petroleum sources and fossil fuels. We can use it in many applications, but it has many problems for human health and causes many diseases such as lung disease, and a high dose of it causes coma or death [3,4,5]. NH3 is a colorless gas produced naturally from burning fossil fuels and when used in industry such as plastic production and preparation of nitric acid, it causes many problems such as eye and nose irritation, and a high dose of it may lead to death too [6]. NO2 is a reddish-brown gas produced by engine combustion producing acid rings, and when it reacts with water, it causes problems to the environment such as damaging buildings and many health hazards [7]. Therefore, the search for new materials to use as sensors that can detect and absorb these gases is aimed. There are several nanostructured materials in zero dimensions (0D), 1D, 2D, and 3D such as nanotubes, nanocages, and nanosheets that have been studied as gas sensors to detect these gases [8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28]. Derdare et al. used C20 and MC19 (M = Ru, Ir, and Au) clusters to adsorb and detect NO2, N2O, and NH3 gases by using DFT calculations, and their work showed that adsorption of N2O and NH3 on C20 is physical adsorption while NO2 is chemical adsorption, but the change of Eg is very low after adsorption indicating that the sensitivity of C20 to these gases is very low. While the doped form of MC19( RuC19 and AuC19) sensitivity and stability was increased, the IrC19 stability decreased. They also found that it is active and can be used as a catalyst in the decomposition of N2O gas [29]. Zahedi and Seif [30] show by using DFT calculations that C48B6N6 heterofullerene is a good material for use as a gas sensor to detect and adsorb NO2 and NH3 gases. Rad e al. [31] used pristine graphene (PG) and N-doped graphene to adsorb and detect SO2 and SO3 gases. They used DFT and NBO calculations and showed that adsorption energy in the case of NDG was higher than in pristine graphene; consequently, NDG is suitable and more detectable for these gases than pristine graphene. Basharnavaz et al. [32] used the P-doped and transition metal (TM)/P-codoped graphitic carbon nitride (gCN) systems (TM = Co, Rh, and Ir elements) to adsorb and detect SO2 gas. This work by using DFT calculations showed that TM/P-codoped gCN systems have adsorption energy higher than that of the pristine gCN. Also, they found that the Ir/P-codoped gCN was a better system for adsorption and detection of the SO2 gas compared with other systems with a high adsorption energy of − 3.52 eV. Zhang et al. [27] used graphene for the adsorption of SO2 by using DFT calculations. They showed that there were four structures for graphene, namely, pristine graphene (PG), vacancy-defected graphene (VG), Ti-doped graphene (Ti-G), and Ti-doped graphene with vacancies (Ti-VG). Their results showed that Ti-doped graphene is the best structure for the adsorption of SO2 gas with the highest adsorption energy. Noei [33] explained the electronic properties of pristine Al12N12 and B12N12 nanoclusters for the adsorption of SO2 gas. The results show that the two structures are sensitive to adsorb SO2 gas. Rad and Ayub [34] study the adsorption of O3 and SO2 molecules on pristine B12N12 and Ni-decorated B12N12 nanocages. They showed that the Ni-decorated B12N12 enhances and increases the adsorption of these gases. Xi et al. [35] examined the adsorption of CO2 molecules on two stable BiC and Bi2C monolayers promising adsorbents to capture CO2 gas. Zhao et al. [36] proposed a single metal catalyst on a 2D BC3N2 substrate for the activation of CO2 and CH4 gasses into CH3COOH. Huo et al. [37] used Fe36Co44 nanostructure to catalyze the hydrolysis reaction of ammonia borane to produce H2. Zhang et al. [38] study the removal of COS chemicals by nano-hollow sphere hydrolytic catalyst. Zhao e al. [39] investigated the 2D-InSe with B-doped as bifunctional catalysts to separate CO2 and CH4 under the regulation of an external electric field.

In this work, we study the adsorption of three toxic gases on Al24N24 and Al24N23C nanocages by using DFT calculations to decrease air pollution. The adsorption energies, NBO, PDOS, NCI, and QTAIM were determined.

Computational details

In this study, all the geometries of nanocages and gas molecules before and after adsorption on nanocages were fully optimized based on density functional theory (DFT) without any symmetry constraint. The B3LYP and 6-31 g(d) level of theory were used for NO2 and SO2 systems and 6-31 g(d,p) for NH3 systems. The calculations were carried out by Gaussian 09 [40]. The adsorption energy of a gas molecule on the nanocages was obtained from the following equation:


where Egas@nanocage, Egas, and Enanocage are the total energy of the gas molecule on the nanocage (Al24N24 and Al24N23C), the total energy of the gas molecule, and the total energy of the nanocage (Al24N24 and Al24N23C), respectively.

Thermodynamic parameters at T = 298.15 K and P = 1 atm such as Gibbs-free energy change (ΔG), enthalpy change (ΔH), and entropy change (ΔS) of the adsorption were evaluated.

Results and discussion

Geometry analysis

The adsorption capacity, which is one of the most important parameters that determine catalytic activity, indicates the selectivity of a particular substance by comparing it with other materials [41,42,43]. In this work, theoretical methods were used to study the adsorption of three industrial gases NO2, SO2, and NH3 based on the adsorbent material Al24N24 nanocage. As evident from Fig. 1, the nanocage of Al24N24 consists of 12 tetragons, 8 hexagons, and 6 octagons. As seen in Fig. 1, in pristine Al24N24, the bond distances between nitrogen and aluminum that are shared between 6- and 8-membered rings are 1.78 Å, 4- and 8-membered rings are 1.83 Å, and for 4- and 6-membered rings are 1.86 Å. By the replacement of one nitrogen with one carbon atom (Al24N23C nanocage), the bond distance between the doping atom and aluminum atom increases by 0.11 and 0.12 Å in comparison with pristine Al24N24.

Fig. 1
figure 1

The optimized geometries and electrostatic potential map (ESP) of Al24N24 and Al24N23C

Electrostatic potential map (ESP) is a useful tool for predicting the reactivity sites for a nucleophilic and electrophilic attack. As shown in Fig. 1, the red and blue colors represent the regions of negative (related to electrophilic reactivity) and positive (related to nucleophilic reactivity) electrostatic potential respectively. The negative regions are localized on the N atom, and the positive regions of ESP are localized on Al and C atoms.

Interaction of NO2, SO2, and NH3 with Al24N24 and Al24N23C nanocages

The optimized geometry configurations of NO2 on Al24N24 and Al24N23C nanocages are shown in Fig. 2. The three different configurations of NO2 on Al24N24 are represented as A1 to C1 and A2 to C2 for Al24N23C nanocages. Configuration A1 displays a nitrogen atom in a NO2 molecule interacting with an aluminum atom of pristine AL24N24 nanocage presented in Table 1, by distance 2.12 Å and adsorption energy − 0.19 eV. In complex A2, the NO2 molecule interacting with the doped carbon Al24N24 nanocage is different from that in configuration A1; the NO2 molecule interacts through nitrogen with carbon-doped Al24N24 and oxygen with the aluminum atom of Al24N23C. The additional interaction C of figuration A2 is responsible for strong binding energy by forming a C–N bond with a distance of 1.39 Å and the adsorption energy − 3.65 eV. A comparison between complex A1 and B1 indicates that the oxygen atom in the NO2 molecule strongly interacts with pristine Al24N24 nanocage as in complex B1, while in complex B2, by carbon-doped Al24N24, the interaction of nitrogen and oxygen atoms in NO2 is stronger than the two oxygen atoms of NO2 molecule. As seen in Table 1, the results reveal that adsorption energies are enhanced by carbon doping Al24N24. As shown in complex C1 and C2 in Fig. 2, the interaction of nitrogen in NO2 molecule is attracted by nitrogen of pristine Al24N24 and carbon of Al24N23C leading to the formation of N–N bond in pristine Al24N24 and C–N bond in Al24N23C nanocage. The bond lengths in both complex C1(N–N) and C2 (C-N) are 1.40 Å and 1.30 Å respectively.

Fig. 2
figure 2

Adsorption configurations of NO2 on Al24N24 and Al24N23C

Table 1 Structural parameters of NO2 adsorbed on AL24N24 and AL24N23C nanocage. The value between brackets is calculated by the cc-PVDZ basis set

For SO2 gas adsorbed on the two nanocages Al24N24 and Al24N23C, the most stable orientations D1 and E1 for Al24N24, D2, and E2 for Al24N23C nanocages are depicted in Fig. 3. The adsorption energies for SO2 molecules in orientations D1 and D2 as shown in Table 2 are − 0.58 eV and − 2.10 eV, respectively. The interactions of the complex D1 and D2 are different like complex B1 and B2 of NO2 adsorbed on Al24N24 and Al24N23C. The presence of carbon doped in Al24N24 leads to improving the adsorption energy by about 3.62 times Al24N24 nanocage. The interaction of the sulfur atom in the SO2 molecule with the nitrogen of Al24N24 and carbon-doped Al24N23C is stronger as in orientations E1 and E2. The adsorption energies of the complexes E1 and E2 are − 2.58 eV and − 3.10 eV respectively.

Fig. 3
figure 3

Adsorption configurations of SO2 on Al24N24 and Al24N23C

Table 2 Structural parameters of SO2 adsorbed on AL24N24 and AL24N23C nanocage. The value between brackets is calculated by the cc-PVDZ basis set

The response of carbon-doped Al24N24 nanocage is decreased towards the NH3 gas molecule. As shown in Fig. 4, there are three configurations for the adsorption of NH3 gas on Al24N24 and carbon-doped Al24N23C, the configuration F1, and the NH3 molecule prefers to lie on the aluminum atom of Al24N24 with adsorption energy − 1.41 eV as in Table 3. In configurations F2 and G2, NH3 binds with aluminum and carbon of Al24N23C, and the calculated adsorption energies for the complex F2 and G2 are − 1.36 eV and 0.41 eV showing that the interaction of NH3 with the carbon of Al24N23C is physical adsorption.

Fig. 4
figure 4

Adsorption configurations of NH3 on Al24N24 and Al24N23C

Table 3 Structural parameters of NH3 adsorbed on AL24N24 and AL24N23C nanocage. The value between brackets is calculated by the cc-PVDZ basis set

When the gas is adsorbed physically, we can reuse the substrate, while if a chemical bond is formed between the gas molecule and the substrate; it means that the desorption process is difficult. As presented in Tables 1 and 2, the doped Al24N24 by carbon atom for SO2 and NO2 molecules is chemically adsorbed, so this nanocage is not suitable for sensing SO2 and NO2 gas molecules. In the case of NH3 systems, the binding of the NH3 gas molecule with the aluminum atom as seen in Table 3 configuration F2 is lower in adsorption energy than configuration F1. As revealed from their results, pristine AL24N24 nanocage is sensitive to the three gas molecules while carbon-doped (Al24N23C) nanocage is sensitive only to NH3 gas molecule. We propose a diagnostic test for the effect of the basis set by using cc-PVDZ as a single-energy calculation, as seen in Tables 1, 2, and 3; the calculated adsorption energies show change ranges from 0 to 0.17 eV in the case of NO2, from 0.11 to 0.31 eV for SO2, and from 0.01 to 0.05 eV for NH3 as we compare with the basis set used for this study mentioned in computational details.

NBO charges and dipole moment

The dipole moment and the charge transfer for the adsorbed gases on pristine Al24N24 and carbon-doped Al24N23C nanocages were investigated. As seen in Table 1, the dipole moment of the pristine Al24N24 nanocage is 0.0068 Debye. After doping with carbon, the dipole moment was changed to 0.6913 Debye. The adsorption of NO2, SO2, and NH3 gases on the two nanocages brings a change in the dipole moment. As seen in Fig. 5, the dipole moment vectors of the SO2 and NO2 adsorbed on Al24N24 and Al24N23C nanocages point away from these two groups. For configuration D1 where the SO2 group is adsorbed on Al24N24 nanocage, the dipole moment vector points forward to this group. For the NH3 group adsorbed on Al24N24 and Al24N23C nanocages, the directions of dipole moment vectors point forward to this group. The charge transferred was determined for all complexes. As seen in Tables 1, 2, and 3, the charge transfers from the nanocage to the SO2 and NO2 gas molecules due to the withdrawing nature of the SO2 and NO2 molecules. For configuration C1, this is due to N–N bond formation between NO2 gas and Al24N24 nanocage and for configuration D1 because SO2 binds to the Al24N24 through an oxygen atom of SO2 molecule. As a comparison between configuration A2 and C2 where NO2 adsorbs on carbon-doped nanocage (Al24N23C), the value of charge transferred for configuration C2 is larger than in configuration A2; this indicates stronger interaction between NO2 and nanocage in configuration C2 than that of configuration A2. Note that when the value of charge transfer increases, a strong interaction between gas molecules and substrates occurs. For NH3 systems, the charge is transferred from the gas molecule to the nanocage.

Fig. 5
figure 5

Dipole moment directions for the two nanocages together with the adsorbed gas molecules

Thermodynamic parameters and density of states

The analysis of interaction energies is expanded to include enthalpies (H), Gibbs-free energies (G), and entropies (S) of interaction. The thermodynamic parameters for the adsorbed gases SO2, NO2, and NH3 such as Gibbs-free energy change (ΔG), enthalpy change (ΔH), and entropy change (ΔS) were determined at T = 298.15 K and P = 1 atm.

As seen in Table 4, the negative values of Gibbs-free energies indicate the spontaneous adsorption of gases molecule on the two nanocages. The higher value of ΔG implies a strong interaction between the gas molecule and substrate. The enthalpy change values are higher than the Gibbs-free energy values which indicate that the enthalpy is stabilized. The ΔG for the configurations A1 and G2 have a positive value confirming weak adsorption for these complexes.

Table 4 Thermodynamic parameters of the gas molecules adsorbed on nanocages

In Tables 1, 2, and 3, the quantum parameters and the electronic properties of the gaseous molecule were evaluated. The HOMO of most complexes is shifted to higher energy. The HOMOs of adsorbed gases were comparable. After the adsorption of this NO2, SO2, and NH3 on the Al24N24 and Al24N23C, the energy gap for all systems decreased.

The PDOS analysis

To characterize the interactions between SO2, NO2, and NH3 gases with the study nanocages (Al24N24 and Al24N23C), the projected density of states (PDOS) was examined. After adsorbing SO2, NO2, and NH3 gases on Al24N24 and Al24N23C, the PDOS of O-2sp, N-2sp, C-2sp, S-3sp, NH3-sp, Al-3 s, and Al-3p orbitals was displayed in Figs. 6, 7, 8, and 9. It is important to note that the charge transfers from Al to the anti-bonding states of NO2 and SO2 molecule that elongates the N–O and S–O bond to 1.341 Å, and 1.372 Å at C2 and E2, respectively. It was shown that the O-2sp, N-2sp, and S-3sp orbitals were found to be particularly localized close to the Fermi level; facilitating their interactions with the C-2sp, Al-3 s, and Al-3p states in Al24N23C nanocage indicates the NO2 and SO2 may have a higher binding energy (Eb) if it is close to the C atom in the Al24N23C nanocage. Figure 6 shows that the Al-3 s and Al-3p orbitals are pushed to lower energies as a result of electron transfer from the Al atoms to the NO2 and SO2 molecules, which considerably aids in the adsorption of NO2 and SO2.

Fig. 6
figure 6

PDOS of configuration A1, B1, C1, and C2

Fig. 7
figure 7

PDOS of configuration D1 and D2

Fig. 8
figure 8

PDOS of configuration E1 and E2

Fig. 9
figure 9

PDOS of configuration F1, F2, and G2

By the binding energies indicated in Tables 1 and 2, it is seen that the Al-3p orbitals of C2′s PDOS display increased intensity, indicating that C2 is more significant than both E2 and C1 configurations. Furthermore, from − 6.20 to − 12.70 eV, the N-2sp states of adsorbed NO2 contribute significantly to the C-2sp (HOMO), indicating that the C atom uses its valence orbitals to interact with the O-2sp, N-2sp, Al-3 s, and Al-3p states of NO2 as well as the Al24N23C nanocage. Due to the distribution of S-3sp states in a broad range from − 5.40 to − 14.30 eV (E2) below the Fermi level, the S-3sp orbitals of SO2 also show a stronger hybridization with the C-2sp, Al-3 s, and Al-3p orbitals of Al24N23C. Agreeing with their binding energies, the charge-transfer values between the S, N, and C atoms of NO2 and SO2 and the Al24N23C nanocage suggest that the charge-transfer is more important for the stability of these complexes than the electrostatic interactions. On the other hand, a weak connection between the substrate and the NH3 molecule results from the soft hybridization of the NH3 and Al24N23C′s C-2p orbitals.

Non-covalent interaction (NCI) analysis

To identify non-covalent bonds, such as hydrogen bonds, steric clashes, Van der Waals (vdW), and reduced density gradients, the quantum mechanical electron density has been used (RDG) determined by the following equation:

$$RDG\left(r\right)=\frac{1}{2(3{\pi }^{2}{)}^{1/3}}\frac{\left|\nabla \rho (r)\right|}{\rho (r{)}^{4/3}}$$

where the \(\rho\) value can represent the bond strength, whereas the value of sign(2) × \(\rho\) is used to evaluate the nature of the interaction between the SO2, NO2, and NH3 gases and the investigated nanocages (Al24N24 and Al24N23C). 2 is the second-largest eigenvalue of the electron density in the Hessian matrix, where sign(2) × \(\rho\)  < 0 denotes an attractive interaction and sign(2) × ρ > 0 denotes a repulsive interaction.

To study the non-covalent interactions between the NO2, SO2, and NH3 gases and the investigated nanocages, the scatter graphs between the reduced density gradient (RDG) and the electron density (\(\rho\)) have been shown in Figs. 10 and 11. As seen in Figs. 10 and 11, sign(λ2)\(\rho\)) increases for red areas suggesting high steric repulsions inside the nanocage, whereas sign(λ2)\(\rho\) decreases for blue areas indicating strong contacts. The green areas between the complex’s elements approaching 0 are Van der Waals interactions, which are weak intermolecular forces. The considerable vdW interaction between the NH3 and the Al24N23C (G2) nanocages is visible, as can be seen in Fig. 11. This conclusion is supported by the geometric analysis, which considers weak interactions.

Fig. 10
figure 10

Non-covalent interaction of G2 and F1

Fig. 11
figure 11

Non-covalent interaction of Al24N23C nanocage, A1, C2, D1, and E2

Additionally, blue and green blended spikes were seen at greater electron densities and sign(λ2)\(\rho\)< 0, which shows that the C2, E2, and F1 complexes have developed partial covalent connections. The blue and green patches between the gas molecule and the nanocages, as well as the intermolecular contact, were visible in the partial covalent bond as shown in Figs. 10 and 11. Higher interaction intensity was seen for C2 and E2 configurations due to the partial covalent contact between the SO2 and NO2 molecules with the Al24N23C nanocage in the RDG versus sign(2) × ρ graph.

Quantum theory of atoms in molecules (QTAIM)

A well-known method for examining the topology of interactions is QTAIM (covalent or non-covalent). For the most stable configuration of C2, E2, and F1 complexes, measurements of several topological parameters, including electron density (ρr), Laplacian (\({\nabla }^{2}\) ρr), and total electron energy density (Hr) at the bond critical points (BCP), have been made in order to characterize the strength and type of bond (Table 5). Shared shell interactions (covalent bonds) exist when the ρr is larger than 0.20 a.u., is higher than 0.20 a.u, and the Laplacian is higher but negative. Al24N23C nanocage’s Al-to-carbon bond is demonstrated to be partially covalent in the presence of \({\nabla }^{2}\) ρr > 0 and Hr < 0 [44]. However, ρr < 0.1 a.u [45] indicates closed-shell interactions (ionic, hydrogen bonding, or van der Waals interactions). Figure 12 displays the BCP between the atoms of the complexes under investigation. As shown in Table 5, the results for the C2 complex indicate that the N–C bond should be regarded as a strong polar covalent bond because its ρr value is 0.326 a.u, which is somewhat higher than the S–C in E2. According to the binding energies, the Al–C (Al24N23C) bond in the C2 complex has a higher ρr value for BCP than the same bond in the E2 configuration. A weaker association between NH3 and nanocages is also indicated by the fact that F1′s electron density (0.050 a.u.) is lower than that of C2 and E2. The low values of ρr < 0.1 for Al–C, Al1–O, Al2–O, and Al–N bonds of SO2, NO2, and NH3 at Al24N24 and Al24N23C nanocages show that the charge dissipates in the distance between the two nuclei and that the interactions can be categorized as a closed-shell type, which is related to strong non-covalent interactions [46, 47].

Table 5 The topological parameters, including electron density (ρr), Laplacian of electron density (\({\nabla }^{2}\)ρr), the density of kinetic energy (Gr), the density of potential energy (Vr), and the density of total energy (Hr) in (a.u.) at the bond critical point (BCPs) for the most stable configurations C2, E2, and F1
Fig. 12
figure 12

AIM molecular graphs for C2, E2, and F1


In this paper, the aim was to investigate the use of Al24N24 and Al24N23C nanocages toward three harmful gases (NO2, SO2, and NH3). The adsorption properties were determined through adsorption energies, charge transfer, dipole moment, thermodynamic parameters, PDOS, NCI, and QTAIM, and the following results are obtained:

  • Introducing carbon-doped increases the adsorption energies for NO2 and SO2 gases, while decreasing for NH3 gas

  • The charge is transferred from the NH3 gas molecule to the nanocage, while for NO2 and SO2 systems, the charge transfers from the nanocage to the SO2 and NO2 gas molecules except configurations C1 and D1.

  • The directions of dipole moment vectors for the NH3 system point forward to this group, while dipole moment vectors of the SO2 and NO2 adsorbed on Al24N24 and Al24N23C nanocages point away from these two groups except configuration D1.

  • The Gibbs-free energy change (ΔG) for all configurations is negative except that A1 and G2 have a positive value confirming weak adsorption for these complexes.

  • The energy gaps decreased after adsorping NO2, SO2, and NH3 on Al24N24 and Al24N23C nanocages.

  • Higher interaction intensity was observed for C2 and E2 configurations due to the partial covalent contact between the SO2 and NO2 molecules with the Al24N23C nanocage.

  • The results obtained from QTAIM for the C2 complex indicate that the N–C bond should be regarded as a strong polar covalent bond because its ρr value is 0.326 a.u and a weaker association between NH3 and Al24N24 nanocages is indicated by electron density (0.050 a.u.) that is lower than that of configuration C2 and E2.

These results confirm that Al24N24 and Al24N23C nanocages were used as promising materials for the removal of NO2, SO2, and NH3 toxic gases.