Layered
double hydroxides (LDHs) are a significant sink of anions (CO<sub>3</sub><sup>2–</sup>, SO<sub>4</sub><sup>2–</sup>,
NO<sub>3</sub><sup>–</sup>, Cl<sup>–</sup>, etc.) and
divalent transition-metal cations in soil. The anion exchange capacity
gives rise to functional materials. The stability of LDHs is determined
by the interaction between cation-bearing layers and intercalated
water and anions, which is correlated with polytypism and coordination
structure. A systematic investigation is performed to show the influence
of cation ratio, anion type, and water content on polytypism, swelling
behavior, and interlayer structure of Mg–Al-LDHs using molecular
dynamics simulations. LDHs intercalated with NO<sub>3</sub><sup>–</sup> ions exhibit a polytype transition from 3<i>R</i><sub>1</sub> (three-layer rhombohedral polytype) to 1<i>T</i> (one-layer trigonal polytype) with increasing water content. NO<sub>3</sub><sup>–</sup> ions exhibit a <i>D</i><sub>3<i>h</i></sub> point group symmetry at low water contents.
The polytype transition coincides with the complete transformation
into tilted NO<sub>3</sub><sup>–</sup> ion with a <i>C</i><sub>2<i>v</i></sub> point group symmetry. The transition
appears at a lower water content when the Mg/Al ratio is lower. LDHs
with SO<sub>4</sub><sup>2–</sup> ions exhibit a three-stage
polytypism. The first and last stages are 3<i>R</i><sub>1</sub>. The intermediate stage could be 1<i>T</i> or a
mixture of different <i>O</i>(octahedra)-type interlayers,
which depends on the cation ratio. The relative popularity of SO<sub>4</sub><sup>2–</sup> ions with a <i>C</i><sub><i>s</i></sub> point group symmetry is characteristic for the intermediate
stage, while mostly SO<sub>4</sub><sup>2–</sup> ions exhibit
a <i>C</i><sub>3<i>v</i></sub> symmetry. There
is no clear relevance between cation ratio and water content at which
a polytype transition happens. The configurational adjustments of
NO<sub>3</sub><sup>–</sup> and SO<sub>4</sub><sup>2–</sup> ions facilitate the swelling behavior of LDHs. LDHs with CO<sub>3</sub><sup>2–</sup> or Cl<sup>–</sup> ions always
maintain a 3<i>R</i><sub>1</sub> polytype irrespective of
water content and hardly swell. The configurations of anions and water
reflect local coordination structure due to hydrogen bonds. The layer-stacking
way influences long-ranged Coulombic interactions. Hydrogen-bonding
structure and long-ranged Coulombic interactions collectively determine
polytypism and stability of LDHs