<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Theory Papers: Formal Analysis, Proofs, and Derivations on Hunter Heidenreich | Senior AI Research Scientist</title><link>https://hunterheidenreich.com/paper-types/theory/</link><description>Recent content in Theory Papers: Formal Analysis, Proofs, and Derivations on Hunter Heidenreich | Senior AI Research Scientist</description><image><title>Hunter Heidenreich | Senior AI Research Scientist</title><url>https://hunterheidenreich.com/img/avatar.webp</url><link>https://hunterheidenreich.com/img/avatar.webp</link></image><generator>Hugo -- 0.163.3</generator><language>en-US</language><copyright>2026 Hunter Heidenreich</copyright><lastBuildDate>Thu, 06 Aug 2026 00:00:00 +0000</lastBuildDate><atom:link href="https://hunterheidenreich.com/paper-types/theory/index.xml" rel="self" type="application/rss+xml"/><item><title>Defining Disentangled Representations via Group Theory</title><link>https://hunterheidenreich.com/notes/machine-learning/geometric-deep-learning/defining-disentangled-representations/</link><pubDate>Sat, 11 Apr 2026 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/geometric-deep-learning/defining-disentangled-representations/</guid><description>First formal definition of disentangled representations using group theory, connecting symmetry transformations to vector space decompositions.</description><content:encoded><![CDATA[<h2 id="a-theory-paper-grounding-disentanglement-in-symmetry">A Theory Paper Grounding Disentanglement in Symmetry</h2>
<p>This is a <strong>Theory</strong> paper that provides the first formal mathematical definition of disentangled representations. Rather than proposing a new learning algorithm or evaluating existing methods, the paper uses group theory and representation theory to define precisely what it means for a representation to be disentangled. The authors argue that the relevant structure of the world is captured by symmetry transformations, and that a disentangled representation must decompose into independent subspaces aligned with the decomposition of the corresponding symmetry group.</p>
<h2 id="why-disentangling-lacks-a-formal-foundation">Why Disentangling Lacks a Formal Foundation</h2>
<p>Disentangled representation learning aims to learn representations where distinct factors of variation in the data are separated into independent components. This idea has driven significant research, particularly through models like $\beta$-VAE and InfoGAN. Despite this progress, the field has lacked agreement on several fundamental questions: what constitutes the &ldquo;data generative factors,&rdquo; whether each factor should correspond to a single latent dimension or multiple dimensions, and whether a disentangled representation should have a unique axis alignment.</p>
<p>Without a formal definition, evaluating disentanglement methods remains subjective, relying on human intuition or metrics that encode different (sometimes contradictory) assumptions. For example, some metrics penalize multi-dimensional subspaces while others allow them. The lack of formal grounding also means there is no principled way to determine whether certain factors of variation (such as 3D rotations) can even be disentangled in principle.</p>
<p>The authors draw inspiration from physics, where symmetry transformations have been central to understanding world structure since <a href="https://en.wikipedia.org/wiki/Noether%27s_theorem">Noether&rsquo;s theorem</a> connected conservation laws to continuous symmetries. Gell-Mann&rsquo;s prediction of the $\Omega^{-}$ particle from symmetry-based classification of hadrons, and the unification of electricity and magnetism through shared symmetry transformations, illustrate the power of the symmetry perspective for generalization to new domains.</p>
<h2 id="symmetry-groups-as-the-foundation-for-disentanglement">Symmetry Groups as the Foundation for Disentanglement</h2>
<p>The core insight is that the &ldquo;data generative factors&rdquo; previously used to discuss disentanglement should be replaced by symmetry transformations of the world. The paper defines a disentangled representation through three key concepts.</p>
<h3 id="disentangled-group-action">Disentangled Group Action</h3>
<p>Given a group $G$ that decomposes as a <a href="https://en.wikipedia.org/wiki/Direct_product_of_groups">direct product</a> $G = G_1 \times G_2 \times \ldots \times G_n$, an action of $G$ on a set $X$ is <strong>disentangled</strong> if there exists a decomposition $X = X_1 \times X_2 \times \ldots \times X_n$ such that each subgroup $G_i$ acts only on $X_i$ and leaves all other components fixed:</p>
<p>$$(g_1, g_2) \cdot (v_1, v_2) = (g_1 \cdot_1 v_1, g_2 \cdot_2 v_2)$$</p>
<h3 id="disentangled-representation">Disentangled Representation</h3>
<p>Let $W$ be the set of world states with symmetry group $G$ acting on it. A generative process $b: W \to O$ produces observations, and an inference process $h: O \to Z$ produces representations. The composition $f = h \circ b$ maps world states to representations. The representation is <strong>disentangled</strong> if:</p>
<ol>
<li>There exists an action $\cdot: G \times Z \to Z$</li>
<li>The map $f: W \to Z$ is <strong><a href="https://en.wikipedia.org/wiki/Equivariant_map">equivariant</a></strong>: $g \cdot f(w) = f(g \cdot w)$ for all $g \in G, w \in W$</li>
<li>There exists a decomposition $Z = Z_1 \oplus Z_2 \oplus \ldots \oplus Z_n$ such that each $Z_i$ is affected only by $G_i$ and fixed by all other subgroups</li>
</ol>
<p>The equivariance condition ensures that the symmetry structure of the world is faithfully reflected in the representation space.</p>
<h3 id="linear-disentangled-representation">Linear Disentangled Representation</h3>
<p>When the group action on $Z$ is additionally constrained to be linear, the representation becomes a <strong>linear disentangled representation</strong>. This leverages <a href="https://en.wikipedia.org/wiki/Group_representation">group representation theory</a>, where the action is described by a homomorphism $\rho: G \to GL(Z)$. The representation is linearly disentangled if it decomposes as a direct sum $\rho = \rho_1 \oplus \rho_2 \oplus \ldots \oplus \rho_n$, where each $\rho_i$ acts only on $Z_i$. In matrix terms, this means $\rho(g)$ takes a block-diagonal form.</p>
<p>For the irreducible representations of a direct product group $G = G_1 \times G_2$, disentanglement requires that each irreducible component $\rho_1 \otimes \rho_2$ has at most one non-trivial factor. This prevents any subspace from being jointly affected by multiple subgroups.</p>
<h2 id="grid-world-example-and-the-so3-counterexample">Grid World Example and the SO(3) Counterexample</h2>
<p>Since this is a theory paper, the &ldquo;experiments&rdquo; consist of worked examples that illustrate the definition.</p>
<h3 id="grid-world-verification">Grid World Verification</h3>
<p>The authors consider a grid world where an object can translate horizontally, vertically, and change color, with wraparound boundaries. The symmetry group decomposes as $G = G_x \times G_y \times G_c$, where each subgroup is isomorphic to the <a href="https://en.wikipedia.org/wiki/Cyclic_group">cyclic group</a> $C_N$.</p>
<p>A CCI-VAE model trained on observations from this world learns a representation that approximately satisfies the equivariance condition $f(x, y, c) \approx (\lambda_x x, \lambda_y y, \lambda_c c)$, where each subgroup acts independently on its corresponding subspace. The group structure (commutativity of actions) is approximately preserved, though the learned representation uses translation rather than linear action, and the cyclic structure is lost.</p>
<p>For a linear disentangled representation, the map $f(x, y, c) = (e^{2\pi i x / N}, e^{2\pi i y / N}, e^{2\pi i c / N})$ over $\mathbb{C}^3$ provides an exact solution. The generator of each subgroup acts as multiplication by $e^{2\pi i / N}$ on its corresponding coordinate, yielding a truly linear and disentangled action. Equivalently, viewing $\rho$ as a representation over $\mathbb{R}^6$ (since $\mathbb{C}^3 \cong \mathbb{R}^6$), the group action is expressed using block-diagonal matrices of $2 \times 2$ rotation matrices, and each invariant subspace becomes two-dimensional.</p>
<h3 id="3d-rotations-cannot-be-disentangled">3D Rotations Cannot Be Disentangled</h3>
<p>The group of 3D rotations <a href="https://en.wikipedia.org/wiki/3D_rotation_group">$SO(3)$</a> has subgroups for rotations about the $x$, $y$, and $z$ axes. Intuitively, one might expect to disentangle these three rotation axes. However, rotations about different axes do not commute (rotating $90°$ about $x$ then $y$ gives a different result from $y$ then $x$), so $SO(3)$ cannot be written as a direct product of these subgroups. The definition correctly rules out disentangling along these lines.</p>
<p>Rotations can still be disentangled from other independent symmetries. For an object that can rotate and change color, the relevant group $G = SO(3) \times G_c$ is a valid direct product, so rotation and color form two disentangled subspaces (even though the rotation subspace is itself multi-dimensional and internally entangled).</p>
<h2 id="resolving-disagreements-and-defining-the-path-forward">Resolving Disagreements and Defining the Path Forward</h2>
<h3 id="backward-compatibility-with-existing-intuitions">Backward Compatibility with Existing Intuitions</h3>
<p>The paper evaluates its definition against three established dimensions of disentanglement:</p>
<p><strong>Modularity</strong> (each latent dimension encodes at most one factor): Satisfied by the new definition, with &ldquo;data generative factors&rdquo; replaced by &ldquo;disentangled actions of the symmetry group.&rdquo; The $SO(3)$ case shows where the new definition disagrees with naive intuition, correctly identifying that non-commuting factors cannot be disentangled.</p>
<p><strong>Compactness</strong> (each factor encoded by a single dimension): The new definition allows multi-dimensional subspaces, siding with approaches that permit distributed representations of individual factors. The dimensionality of each subspace is determined by the structure of the corresponding group representation.</p>
<p><strong>Explicitness</strong> (factors linearly decodable): The general definition does not require linearity. Linear disentangled representations are a strictly stronger condition, and the paper provides a separate formal definition for this case.</p>
<h3 id="key-consequences">Key Consequences</h3>
<p>The definition is relative to a particular decomposition of the symmetry group into subgroups. This has two implications. First, the same group may admit multiple decompositions, and different decompositions yield different disentangled representations (potentially useful for different downstream tasks). Second, identifying the &ldquo;natural&rdquo; decomposition is a separate problem that the authors leave to future work, suggesting that active perception and causal interventions may play a role.</p>
<p>The paper connects to Locatello et al. (2018), who proved that unsupervised learning of disentangled representations is impossible without inductive biases. The symmetry-based framework suggests that such biases could come from an agent&rsquo;s ability to interact with the world and discover which aspects remain invariant under various transformations.</p>
<h3 id="limitations">Limitations</h3>
<p>The paper explicitly focuses on defining disentanglement rather than solving the learning problem. It assumes that the symmetry group decomposes as a direct product of subgroups and that a useful decomposition is known. The authors acknowledge that relaxing these assumptions (e.g., discovering useful decompositions automatically) is important future work. The worked examples use toy environments, and bridging the gap to realistic data remains an open challenge.</p>
<hr>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<h3 id="data">Data</h3>
<p>This is a purely theoretical paper. The only empirical element is a qualitative demonstration using a CCI-VAE model on a grid world environment, where an object translates on a grid with wraparound and changes color through discrete steps on a circular hue axis.</p>
<h3 id="algorithms">Algorithms</h3>
<p>No new algorithms are proposed. The CCI-VAE model from Burgess et al. (2018) is used for the grid world demonstration. The paper&rsquo;s contribution is a set of formal definitions, not an algorithmic procedure.</p>
<h3 id="evaluation">Evaluation</h3>
<p>No quantitative evaluation is performed. The paper discusses how existing disentanglement metrics relate to the proposed definition, noting that they each capture different subsets of the three dimensions (modularity, compactness, explicitness) and that the formal definition provides a principled way to evaluate their relative merits.</p>
<h3 id="reproducibility-status-closed">Reproducibility Status: Closed</h3>
<p>This is a theory paper whose primary contribution is a set of formal definitions. The theoretical content (definitions, proofs, worked examples) is self-contained in the paper. No code, data, or models are released. The CCI-VAE demonstration uses a model from Burgess et al. (2018), but no implementation or training details specific to the grid world experiment are provided.</p>
<hr>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Higgins, I., Amos, D., Pfau, D., Racanière, S., Matthey, L., Rezende, D., &amp; Lerchner, A. (2018). Towards a Definition of Disentangled Representations. <em>arXiv preprint arXiv:1812.02230</em>.</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@misc</span>{higgins2018towards,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Towards a Definition of Disentangled Representations}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Higgins, Irina and Amos, David and Pfau, David and Racani\`{e}re, S\&#39;{e}bastien and Matthey, Lo\&#34;{i}c and Rezende, Danilo and Lerchner, Alexander}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{2018}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">eprint</span>=<span style="color:#e6db74">{1812.02230}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">archiveprefix</span>=<span style="color:#e6db74">{arXiv}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">primaryclass</span>=<span style="color:#e6db74">{cs.LG}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Atom-Density Representations for Machine Learning</title><link>https://hunterheidenreich.com/notes/chemistry/molecular-simulation/ml-potentials/atom-density-representations-ml/</link><pubDate>Sat, 11 Apr 2026 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/chemistry/molecular-simulation/ml-potentials/atom-density-representations-ml/</guid><description>A unified bra-ket framework connecting SOAP, Behler-Parrinello, and other atom-density representations for ML on molecules and materials.</description><content:encoded><![CDATA[<h2 id="a-unified-theory-of-atom-density-representations">A Unified Theory of Atom-Density Representations</h2>
<p>This is a <strong>Theory</strong> paper that provides a formal, basis-independent framework for constructing structural representations of atomic systems for machine learning. Rather than proposing a new representation, Willatt, Musil, and Ceriotti show that many popular approaches (SOAP power spectra, Behler-Parrinello symmetry functions, $n$-body kernels, and tensorial SOAP) are special cases of a single abstract construction based on smoothed atom densities and <a href="https://en.wikipedia.org/wiki/Haar_measure">Haar integration</a> over symmetry groups.</p>
<h2 id="the-challenge-of-representing-atomic-structures">The Challenge of Representing Atomic Structures</h2>
<p>Machine learning models for predicting molecular and materials properties require input representations that are (1) complete enough to distinguish structurally distinct configurations and (2) invariant to physical symmetries (translations, rotations, and permutations of identical atoms). This has led to a large and growing set of competing approaches: <a href="/posts/molecular-descriptor-coulomb-matrix/">Coulomb matrices</a>, symmetry functions, <a href="https://en.wikipedia.org/wiki/Radial_distribution_function">radial distribution functions</a>, wavelets, invariant polynomials, and many more.</p>
<p>The proliferation of representations makes it difficult to compare them on equal footing or to identify which design choices are fundamental and which are incidental. Internal-coordinate approaches (e.g., Coulomb matrices) are automatically translation- and rotation-invariant but require additional symmetrization over permutations, which can introduce derivative discontinuities when done via sorting. Density-based approaches such as radial distribution functions and SOAP avoid these discontinuities by working with smooth density fields, but their theoretical connections to one another have not been made explicit.</p>
<h2 id="dirac-notation-for-atomic-environments">Dirac Notation for Atomic Environments</h2>
<p>The core innovation is to describe an atomic configuration $\mathcal{A}$ as a ket $|\mathcal{A}\rangle$ in a Hilbert space, formed by placing smooth functions $g(\mathbf{r})$ (typically Gaussians) on each atom and decorating them with orthonormal element kets $|\alpha\rangle$:</p>
<p>$$
\langle \mathbf{r} | \mathcal{A} \rangle = \sum_{i} g(\mathbf{r} - \mathbf{r}_{i}) | \alpha_{i} \rangle
$$</p>
<p>This ket is basis-independent, which is the reason for adopting the Dirac notation. The same abstract object can be projected onto position space, reciprocal space, or a basis of radial functions and spherical harmonics, yielding different concrete representations that all encode the same structural information.</p>
<h3 id="symmetrization-via-haar-integration">Symmetrization via Haar Integration</h3>
<p>To impose translational invariance, the ket is averaged over the translation group. Averaging the raw density $|\mathcal{A}\rangle$ directly (first order, $\nu = 1$) discards all geometric information and retains only atom counts per element. The solution is to first take tensor products and then average:</p>
<p>$$
\left| \mathcal{A}^{(\nu)} \right\rangle_{\hat{t}} = \int \mathrm{d}\hat{t} \underbrace{\hat{t}|\mathcal{A}\rangle \otimes \hat{t}|\mathcal{A}\rangle \cdots \hat{t}|\mathcal{A}\rangle}_{\nu}
$$</p>
<p>For $\nu = 2$, this yields a translationally-invariant ket that encodes pairwise distance information between atoms, and naturally decomposes into atom-centered contributions:</p>
<p>$$
\left| \mathcal{A}^{(2)} \right\rangle_{\hat{t}} = \sum_{j} |\alpha_{j}\rangle |\mathcal{X}_{j}\rangle
$$</p>
<p>where $|\mathcal{X}_{j}\rangle$ is the environment ket centered on atom $j$, defined with a smooth cutoff function $f_{c}(r_{ij})$ that restricts each environment to a spherical neighborhood (justified by the nearsightedness principle of electronic matter). This decomposition is what justifies the widely used additive kernel between structures (a sum of kernels between environments).</p>
<h3 id="rotational-invariance-and-body-order-correlations">Rotational Invariance and Body-Order Correlations</h3>
<p>The same Haar integration procedure over the $SO(3)$ rotation group produces rotationally invariant representations:</p>
<p>$$
\left| \mathcal{X}^{(\nu)} \right\rangle_{\hat{R}} = \int \mathrm{d}\hat{R} \prod_{\aleph}^{\nu} \otimes \hat{R}\hat{U}_{\aleph}|\mathcal{X}_{j}^{\aleph}\rangle
$$</p>
<p>The order $\nu$ of the tensor product before symmetrization determines the body-order of correlations captured: $\nu$ corresponds to $(\nu + 1)$-body correlations. The $\nu = 1$ invariant ket retains only radial (distance) information (two-body). The $\nu = 2$ ket encodes three-body correlations (two distances and an angle), and is argued to be sufficient for unique reconstruction of a configuration (up to inversion symmetry), based on extensive numerical experiments. Using nonlinear kernels (tensor products of the symmetrized ket, parameterized by $\zeta$) allows the model to incorporate higher body-order correlations beyond those explicitly in the feature vector.</p>
<h2 id="recovering-soap-symmetry-functions-and-tensorial-extensions">Recovering SOAP, Symmetry Functions, and Tensorial Extensions</h2>
<p>By projecting the abstract invariant kets onto specific basis sets, the authors recover several well-known frameworks as special cases.</p>
<h3 id="behler-parrinello-symmetry-functions">Behler-Parrinello Symmetry Functions</h3>
<p>In the $\delta$-function limit of the atomic density, the $\nu = 1$ and $\nu = 2$ invariant kets in real space directly correspond to the 2-body and 3-body correlation functions. Behler-Parrinello symmetry functions are projections of these correlation functions onto suitable test functions $G$:</p>
<p>$$
\langle \alpha \beta G_{2} | \mathcal{X}_{j} \rangle = \langle \alpha | \alpha_{j} \rangle \int \mathrm{d}r, G_{2}(r), r \left\langle \beta r | \mathcal{X}_{j}^{(1)} \right\rangle_{\hat{R},, h \to \delta}
$$</p>
<p>where the $h \to \delta$ subscript indicates the Dirac delta limit of the atomic density.</p>
<h3 id="soap-power-spectrum">SOAP Power Spectrum</h3>
<p>Expanding the environmental ket in a basis of radial functions $R_{n}(r)$ and <a href="https://en.wikipedia.org/wiki/Spherical_harmonics">spherical harmonics</a> $Y_{m}^{l}(\hat{\mathbf{r}})$, the $\nu = 2$ invariant ket is the SOAP power spectrum:</p>
<p>$$
\left\langle \alpha n \alpha&rsquo; n&rsquo; l \left| \mathcal{X}_{j}^{(2)} \right\rangle_{\hat{R}} \propto \frac{1}{\sqrt{2l+1}} \sum_{m} \langle \alpha n l m | \mathcal{X}_{j} \rangle^{\star} \langle \alpha&rsquo; n&rsquo; l m | \mathcal{X}_{j} \rangle \right.
$$</p>
<p>This identity shows that the SOAP kernel, which can be expressed as a scalar product between truncated power spectrum vectors, is a natural consequence of the inner product between invariant kets. The $\nu = 3$ case yields the <a href="https://en.wikipedia.org/wiki/Bispectrum">bispectrum</a>, used as a four-body feature vector in both SOAP and Spectral Neighbor Analysis Potentials (SNAP), where its high resolution enables accurate interatomic potentials through linear regression:</p>
<p>$$
\langle \alpha_{1} n_{1} l_{1}, \alpha_{2} n_{2} l_{2}, \alpha n l | \mathcal{X}_{j}^{(3)} \rangle_{\hat{R}} \propto \frac{1}{\sqrt{2l+1}} \sum_{m, m_{1}, m_{2}} \langle \mathcal{X}_{j} | \alpha n l m \rangle \langle \alpha_{1} n_{1} l_{1} m_{1} | \mathcal{X}_{j} \rangle \langle \alpha_{2} n_{2} l_{2} m_{2} | \mathcal{X}_{j} \rangle \langle l_{1} m_{1} l_{2} m_{2} | l m \rangle
$$</p>
<p>where $\langle l_{1} m_{1} l_{2} m_{2} | l m \rangle$ is a <a href="https://en.wikipedia.org/wiki/Clebsch%E2%80%93Gordan_coefficients">Clebsch-Gordan coefficient</a>.</p>
<h3 id="tensorial-soap-lambda-soap">Tensorial SOAP ($\lambda$-SOAP)</h3>
<p>The tensorial extension of SOAP incorporates an angular momentum ket $|\lambda \mu\rangle$ into the tensor product before symmetrization:</p>
<p>$$
\left| \mathcal{X}^{(\nu)} \lambda \mu \right\rangle_{\hat{R}} = \int \mathrm{d}\hat{R}, \hat{R}|\lambda \mu\rangle \prod_{\aleph=1}^{\nu} \otimes \hat{R}|\mathcal{X}_{j}\rangle
$$</p>
<p>This construction is rotationally invariant in the full product space but covariant in the subspace of atomic environments, enabling models for tensorial properties (e.g., polarizability tensors, chemical shielding).</p>
<h3 id="distributions-vs-sorted-vectors">Distributions vs. Sorted Vectors</h3>
<p>The paper also connects density-based and sorted-vector approaches. Given a set of structural descriptors ${a_{i}}$, the sorted vector is equivalent to the inverse cumulative distribution function of the histogram of values. The Euclidean distance between sorted vectors is the $\mathcal{L}^{2}$ norm of the difference between the inverse CDFs, and the $\mathcal{L}^{1}$ norm corresponds to the <a href="https://en.wikipedia.org/wiki/Earth_mover%27s_distance">earth mover&rsquo;s distance</a>. This highlights that different symmetrization strategies encode essentially the same structural information.</p>
<h2 id="generalized-operators-for-tuning-representations">Generalized Operators for Tuning Representations</h2>
<p>The framework becomes especially powerful through the introduction of a linear Hermitian operator $\hat{U}$ that transforms the density ket before symmetrization. This operator must commute with rotations:</p>
<p>$$
\langle \alpha n l m | \hat{U} | \alpha&rsquo; n&rsquo; l&rsquo; m&rsquo; \rangle = \delta_{ll&rsquo;} \delta_{mm&rsquo;} \langle \alpha n l | \hat{U} | \alpha&rsquo; n&rsquo; l&rsquo; \rangle
$$</p>
<p>Several practical modifications to standard representations can be understood as choices of $\hat{U}$:</p>
<h3 id="dimensionality-reduction">Dimensionality Reduction</h3>
<p>A low-rank expansion of $\hat{U}$ via PCA on the spherical-harmonic covariance matrix of environments identifies linearly independent components, enabling compression of the feature vector. For a given $l$, the covariance matrix between spherical expansion coefficients is:</p>
<p>$$
C_{\alpha n \alpha&rsquo; n&rsquo;}^{(l)} = \frac{1}{N} \sum_{j} \sum_{m} \langle \alpha n l m | \mathcal{X}_{j} \rangle^{\star} \langle \mathcal{X}_{j} | \alpha&rsquo; n&rsquo; l m \rangle = \frac{\sqrt{2l+1}}{N} \sum_{j} \left\langle \alpha n, \alpha&rsquo; n&rsquo; l \left| \mathcal{X}_{j}^{(2)} \right\rangle_{\hat{R}} \right.
$$</p>
<p>The eigenvectors of $\mathbf{C}^{(l)}$ provide the mixing coefficients for a compressed representation, retaining only components with significant eigenvalues.</p>
<h3 id="radial-scaling">Radial Scaling</h3>
<p>In systems with relatively uniform atom density, the overlap kernel is dominated by the region farthest from the center. A radial scaling operator $u(r)$ (diagonal in position space) downweights distant contributions:</p>
<p>$$
\langle \alpha \mathbf{r} | \hat{U} | \mathcal{X}_{j} \rangle = u(r), \psi_{\mathcal{X}_{j}}^{\alpha}(\mathbf{r})
$$</p>
<p>This recovers the multi-scale kernels that are known to improve predictions in practice, and connects to the two-body features of Faber et al.</p>
<h3 id="alchemical-kernels">Alchemical Kernels</h3>
<p>An operator that acts only in chemical-element space introduces correlations between different elements. The &ldquo;alchemical&rdquo; projection:</p>
<p>$$
\langle J \mathbf{r} | \mathcal{X}_{j} \rangle = \sum_{\alpha} u_{J\alpha}, \psi_{\mathcal{X}_{j}}^{\alpha}(\mathbf{r})
$$</p>
<p>reduces the dimensionality from $O(n_{\mathrm{sp}}^{2})$ to $O(d_{J}^{2})$ and has been shown to produce a low-dimensional representation of elemental space that shares similarities with periodic-table groupings.</p>
<h3 id="non-factorizable-operators">Non-Factorizable Operators</h3>
<p>For more complex modifications (e.g., distance- and angle-dependent scaling of three-body correlations), the operator must act on the full product space rather than factoring into independent components. The authors show that the three-body scaling function of Faber et al. corresponds to a diagonal non-factorizable operator in the real-space representation.</p>
<h2 id="implications-and-future-directions">Implications and Future Directions</h2>
<p>The main conclusions are:</p>
<ol>
<li>
<p><strong>Unification</strong>: SOAP, Behler-Parrinello symmetry functions, $\lambda$-SOAP, bispectrum descriptors, and sorted-vector approaches all emerge from the same abstract construction, differing only in the choice of basis set, body order $\nu$, and kernel power $\zeta$.</p>
</li>
<li>
<p><strong>Systematic improvability</strong>: The $\hat{U}$ operator framework provides a principled way to tune representations, from simple radial scaling to full alchemical and non-factorizable couplings, with clear connections to existing heuristic modifications.</p>
</li>
<li>
<p><strong>Completeness hierarchy</strong>: The body-order parameter $\nu$ and kernel power $\zeta$ together control the trade-off between completeness and computational cost. The $\nu = 2$ (three-body) representation appears to be sufficient for unique structural identification, while higher orders can be recovered through nonlinear kernels.</p>
</li>
</ol>
<p><strong>Limitations</strong>: The paper is primarily theoretical and does not include extensive numerical benchmarks comparing the different instantiations of the framework. Optimization of the $\hat{U}$ operator (especially in its general form) carries a risk of overfitting that the authors acknowledge but do not resolve. The connection to neural network-based representations (message-passing networks, equivariant architectures) is not explored.</p>
<hr>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<h3 id="data">Data</h3>
<p>This is a theoretical paper that does not introduce new benchmark results. No training or test datasets are used. The ethanol molecule in Figure 2 serves as a visualization example for three-body correlation functions.</p>
<h3 id="algorithms">Algorithms</h3>
<p>The paper defines abstract constructions (Haar integration, tensor products, operator transformations) and shows how they reduce to concrete algorithms:</p>
<ul>
<li><strong>SOAP power spectrum</strong>: Expand atom density in radial functions and spherical harmonics, compute $\nu = 2$ invariant ket (Eq. 33).</li>
<li><strong>Alchemical projection</strong>: Contract element channels via learned or PCA-derived mixing coefficients (Eq. 53-55).</li>
<li><strong>Dimensionality reduction</strong>: PCA on the covariance matrix $C_{\alpha n \alpha&rsquo; n&rsquo;}^{(l)}$ of spherical expansion coefficients (Eq. 45).</li>
</ul>
<h3 id="models">Models</h3>
<p>No trained models are presented. The framework applies to kernel ridge regression / Gaussian process regression models that use these representations as inputs.</p>
<h3 id="evaluation">Evaluation</h3>
<p>No quantitative benchmarks are reported. The contribution is the theoretical framework itself, connecting and generalizing existing representations.</p>
<h3 id="hardware">Hardware</h3>
<p>Not applicable (theoretical work).</p>
<hr>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Willatt, M. J., Musil, F., &amp; Ceriotti, M. (2019). Atom-density representations for machine learning. <em>The Journal of Chemical Physics</em>, 150(15), 154110. <a href="https://doi.org/10.1063/1.5090481">https://doi.org/10.1063/1.5090481</a></p>
<p><strong>Publication</strong>: The Journal of Chemical Physics, 2019</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{willatt2019atom,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Atom-density representations for machine learning}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Willatt, Michael J. and Musil, F{\&#39;e}lix and Ceriotti, Michele}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span>=<span style="color:#e6db74">{The Journal of Chemical Physics}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span>=<span style="color:#e6db74">{150}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span>=<span style="color:#e6db74">{15}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span>=<span style="color:#e6db74">{154110}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{2019}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">doi</span>=<span style="color:#e6db74">{10.1063/1.5090481}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">eprint</span>=<span style="color:#e6db74">{1807.00408}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">archiveprefix</span>=<span style="color:#e6db74">{arXiv}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">primaryclass</span>=<span style="color:#e6db74">{physics.chem-ph}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>The Quarks of Attention: Building Blocks of Attention</title><link>https://hunterheidenreich.com/notes/machine-learning/model-architectures/quarks-of-attention/</link><pubDate>Sat, 14 Mar 2026 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/model-architectures/quarks-of-attention/</guid><description>Baldi and Vershynin's 2023 theoretical analysis decomposing attention into fundamental building blocks and proving capacity bounds for attentional circuits.</description><content:encoded><![CDATA[<h2 id="what-kind-of-paper-is-this">What kind of paper is this?</h2>
<p>This is a <strong>theory paper</strong> that takes a reductionist approach to attention mechanisms. It classifies all possible fundamental building blocks of attention (&ldquo;quarks&rdquo;) within a formal neural network framework, then proves capacity theorems for circuits built from these primitives using linear and polynomial threshold gates.</p>
<h2 id="why-decompose-attention-into-primitives">Why decompose attention into primitives?</h2>
<p>Descriptions of attention in deep learning often seem complex and obscure the underlying neural architecture. Despite the widespread use of attention in transformers and beyond, there has been little formal theory about the computational nature and capacity of attention mechanisms. Baldi and Vershynin address this by identifying the smallest building blocks and rigorously analyzing what they can compute.</p>
<h2 id="the-standard-model-and-its-extensions">The Standard Model and its extensions</h2>
<p>The paper defines the &ldquo;Standard Model&rdquo; (SM) as the class of all neural networks built from McCulloch-Pitt neurons: directed weighted graphs where neuron $i$ computes $O_i = f_i(S_i)$ with activation $S_i = \sum_j w_{ij} O_j$. The SM already has universal approximation properties, so extensions should be evaluated on efficiency (circuit size, depth, learning), not on what functions can be represented.</p>
<p>Three variable types exist in the SM: activations ($S$), outputs ($O$), and synaptic weights ($w$). Cross these with two mechanisms (addition, multiplication) and the constraint that attending signals originate from neuronal outputs, and you get six possible attention primitives.</p>
<h2 id="the-six-quarks-reduced-to-three">The six quarks, reduced to three</h2>
<table>
	<thead>
			<tr>
					<th></th>
					<th>$S$ (activation)</th>
					<th>$O$ (output)</th>
					<th>$w$ (synapse)</th>
			</tr>
	</thead>
	<tbody>
			<tr>
					<td><strong>Addition</strong></td>
					<td>Multiplexing (in SM)</td>
					<td>Additive output (in SM)</td>
					<td>Additive synaptic</td>
			</tr>
			<tr>
					<td><strong>Multiplication</strong></td>
					<td>Activation gating</td>
					<td><strong>Output gating</strong></td>
					<td><strong>Synaptic gating</strong></td>
			</tr>
	</tbody>
</table>
<p>The paper shows these reduce to three cases worth studying:</p>
<h3 id="multiplexing-additive-activation-attention">Multiplexing (additive activation attention)</h3>
<p>The attending signal $S_2$ is added to the normal activation $S_1$, producing $O_i = f_i(S_1 + S_2)$. With sigmoid or threshold activations, a large negative $S_2$ forces the output to zero regardless of $S_1$, suppressing unattended stimuli. This mechanism lives entirely within the SM and plays a central role in proving capacity lower bounds.</p>
<h3 id="output-gating">Output gating</h3>
<p>Neuron $j$ multiplies the output of neuron $i$, producing $O_i O_j$. This quadratic term is new to the SM. The gated signal $O_i O_j$ propagates to all downstream neurons of $i$. When $O_j \approx 0$, the attended neuron is silenced; when $O_j$ is large, it is enhanced.</p>
<h3 id="synaptic-gating">Synaptic gating</h3>
<p>Neuron $j$ multiplies a synaptic weight $w_{ki}$, creating a dynamic weight $w_{ki} O_j$. This produces the same local term $w_{ki} O_i O_j$ at neuron $k$ as output gating, but affects only the single downstream connection rather than all of neuron $i$&rsquo;s outputs. Synaptic gating is a fast weight mechanism: the attending network dynamically changes the program executed by the attended network.</p>
<h2 id="transformers-are-built-entirely-from-gating">Transformers are built entirely from gating</h2>
<p>The paper shows that transformer encoder modules decompose into:</p>
<ol>
<li><strong>Output gating</strong> ($mn^2$ operations): computing all $n^2$ pairwise dot products of $Q$ and $K$ vectors, each requiring $m$ element-wise multiplications</li>
<li><strong>Softmax</strong>: a standard SM extension</li>
<li><strong>Synaptic gating</strong> ($n^2$ operations): weighting $V$ vectors by the softmax outputs to form convex combinations</li>
</ol>
<p>The entire attention mechanism uses $O(mn^2)$ gating operations. The permutation invariance of transformers follows directly from the weight sharing across input positions.</p>
<h2 id="relationship-to-polynomial-neural-networks">Relationship to polynomial neural networks</h2>
<p>Gating is a special case of polynomial activation. A neuron with full quadratic activation over $n$ inputs has the form $S_i = \sum_{jk} w_{ijk} O_j O_k$, requiring $O(n^2)$ three-way synaptic weights for all possible pairs. Gating introduces only one new quadratic term per operation. The same gating concepts can also be applied to more complex units with polynomial activations of degree $d$, where one polynomial threshold unit gates the output or synapse of another.</p>
<h2 id="functional-properties-of-gating">Functional properties of gating</h2>
<p>Several examples illustrate what gating enables:</p>
<ul>
<li><strong>Shaping activation functions</strong>: When a unit with activation function $f$ is output-gated by a unit with activation function $g$ (both having the same inputs), the result is $f(S)g(S) = fg(S)$. This changes the effective activation function from $f$ to $fg$. For instance, a linear unit gated by a $(0,1)$ threshold function produces the ReLU activation.</li>
<li><strong>XOR without hidden layers</strong>: The XOR function cannot be computed by a single linear threshold gate. However, gating the OR function by the NAND function (both implementable by single linear threshold gates) produces XOR in a shallow network with no hidden layers.</li>
<li><strong>Universal approximation</strong>: Every continuous function on a compact set can be approximated to arbitrary precision by a shallow attention network of linear units gated by linear threshold gates (Theorem 4.3).</li>
</ul>
<h2 id="attention-as-sparse-quadratic-terms">Attention as sparse quadratic terms</h2>
<p>Both output and synaptic gating introduce quadratic terms of the form $w_{ki} O_i O_j$. A neuron with full quadratic activation over $n$ inputs would require $O(n^2)$ parameters. Gating introduces only one new quadratic term per operation. This is the key insight: attention mechanisms gain some of the expressiveness of quadratic activations while avoiding the combinatorial parameter explosion.</p>
<h2 id="capacity-results">Capacity results</h2>
<p>Using cardinal capacity (the base-2 logarithm of the number of distinct Boolean functions a class of circuits can implement), the paper proves bounds for attentional circuits with linear and polynomial threshold gates:</p>
<ul>
<li><strong>Single unit with output gating</strong>: a gated pair of linear threshold gates on $n$ inputs has capacity $2n^2(1 + o(1))$, compared to $n^2(1 + o(1))$ for a single gate (Theorem 6.1). This represents a doubling of capacity with a doubling of parameters (from $n$ to $2n$), a sign of efficiency.</li>
<li><strong>Multiplexing technique</strong>: additive activation attention enables a &ldquo;multiplexing&rdquo; proof strategy where one unit in a layer is selected as a function of the attending units while driving remaining units to saturation. This is the key tool for proving lower bounds.</li>
<li><strong>Attention layers</strong>: extending to layers of $m$ gated units with $n$ inputs, the capacity is $2mn^2(1 + o(1))$ for output gating (Theorem 7.1), confirming that gating approximately doubles the capacity relative to ungated layers.</li>
<li><strong>Depth reduction</strong>: gating operations available as physical primitives in a neural network can reduce the depth required for certain basic circuits.</li>
</ul>
<h2 id="limitations-and-future-work">Limitations and future work</h2>
<p>The authors note several open directions:</p>
<ul>
<li>The capacity estimates for some configurations (e.g., single-weight synaptic gating in Proposition 6.9) have gaps between the lower and upper bounds that remain to be tightened.</li>
<li>The analysis uses Boolean neurons (linear and polynomial threshold gates) as approximations. Extending results to other activation functions (sigmoid, ReLU) is left for future work.</li>
<li>The paper focuses on single layers and pairs of units. Capacity analysis for deeper attention architectures with multiple stacked layers is not addressed.</li>
<li>The theory treats attention on the time scale of individual inputs. The paper briefly notes that fast synaptic mechanisms operating on different time scales raise interesting architectural questions but does not develop this direction.</li>
</ul>
<h2 id="reproducibility">Reproducibility</h2>
<p>This is a purely theoretical paper with no associated code, datasets, or pretrained models. All results are mathematical theorems and proofs that can be verified from the paper itself. The paper is freely available on arXiv under a CC BY-NC-ND 4.0 license.</p>
<hr>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Baldi, P. &amp; Vershynin, R. (2023). The quarks of attention: Structure and capacity of neural attention building blocks. <em>Artificial Intelligence</em>, 319, 103901.</p>
<p><strong>Publication</strong>: Artificial Intelligence 2023</p>
<p><strong>Additional Resources</strong>:</p>
<ul>
<li><a href="https://www.sciencedirect.com/science/article/pii/S0004370223000474">Journal (ScienceDirect)</a></li>
<li><a href="https://arxiv.org/abs/2202.08371">arXiv</a></li>
</ul>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{baldi2023quarks,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{The quarks of attention: Structure and capacity of neural attention building blocks}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Baldi, Pierre and Vershynin, Roman}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span>=<span style="color:#e6db74">{Artificial Intelligence}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span>=<span style="color:#e6db74">{319}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span>=<span style="color:#e6db74">{103901}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{2023}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">doi</span>=<span style="color:#e6db74">{10.1016/j.artint.2023.103901}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Can Recurrent Neural Networks Warp Time? (ICLR 2018)</title><link>https://hunterheidenreich.com/notes/machine-learning/model-architectures/can-recurrent-neural-networks-warp-time/</link><pubDate>Sat, 14 Mar 2026 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/model-architectures/can-recurrent-neural-networks-warp-time/</guid><description>Tallec and Ollivier's ICLR 2018 paper deriving gating mechanisms in RNNs from time warping invariance and proposing chrono initialization for LSTMs.</description><content:encoded><![CDATA[<h2 id="what-kind-of-paper-is-this">What kind of paper is this?</h2>
<p>This is a <strong>theory paper</strong> that provides a principled derivation of gating mechanisms in recurrent neural networks from an axiom of invariance to time transformations. The theoretical insights also yield a practical contribution: the <strong>chrono initialization</strong> for LSTM gate biases.</p>
<h2 id="why-time-warping-invariance-matters-for-recurrent-models">Why time warping invariance matters for recurrent models</h2>
<p>Standard recurrent neural networks are highly sensitive to changes in the time scale of their input data. Inserting a fixed number of blank steps between elements of an input sequence can make an otherwise easy task impossible for a vanilla RNN to learn. This fragility arises because the class of functions representable by an ordinary RNN is not closed under time rescaling.</p>
<p>The vanishing gradient problem compounds this issue: learning long-term dependencies requires gradient signals to persist across many time steps, but stability of the dynamical system causes these signals to decay exponentially. Prior solutions include gating mechanisms (LSTMs, GRUs) introduced on engineering grounds, and orthogonal weight constraints that limit representational power and make forgetting difficult.</p>
<p>Tallec and Ollivier ask a clean theoretical question: what structural properties must a recurrent model have to be invariant to arbitrary time transformations in its input?</p>
<h2 id="deriving-gates-from-time-warping-invariance">Deriving gates from time warping invariance</h2>
<p>The core insight starts from the continuous-time formulation of a basic RNN:</p>
<p>$$\frac{\mathrm{d}h(t)}{\mathrm{d}t} = \tanh(W_x x(t) + W_h h(t) + b) - h(t)$$</p>
<p>Applying a time warping $t \gets c(t)$ (any increasing differentiable function) to the input data $x(c(t))$ transforms this equation into:</p>
<p>$$\frac{\mathrm{d}h(t)}{\mathrm{d}t} = \frac{\mathrm{d}c(t)}{\mathrm{d}t} \tanh(W_x x(t) + W_h h(t) + b) - \frac{\mathrm{d}c(t)}{\mathrm{d}t} h(t)$$</p>
<p>The derivative $\frac{\mathrm{d}c(t)}{\mathrm{d}t}$ of the time warping appears as a multiplicative factor. For the model class to represent this equation for any time warping, a learnable function $g(t)$ must replace the unknown derivative:</p>
<p>$$\frac{\mathrm{d}h(t)}{\mathrm{d}t} = g(t) \tanh(W_x x(t) + W_h h(t) + b) - g(t) h(t)$$</p>
<p>Discretizing with a Taylor expansion ($\delta t = 1$) yields:</p>
<p>$$h_{t+1} = g_t \tanh(W_x x_t + W_h h_t + b) + (1 - g_t) h_t$$</p>
<p>This is a gated recurrent network with input gate $g_t$ and forget gate $(1 - g_t)$, where $g_t$ is computed by a sigmoid function of the inputs. The value $1/g(t_0)$ represents the local forgetting time of the network at time $t_0$.</p>
<h3 id="the-special-case-of-linear-time-rescaling">The special case of linear time rescaling</h3>
<p>For the simpler case of a constant time rescaling $c(t) = \alpha t$, the same derivation produces a leaky RNN:</p>
<p>$$h_{t+1} = \alpha \tanh(W_x x_t + W_h h_t + b) + (1 - \alpha) h_t$$</p>
<p>Leaky RNNs are invariant to global time rescalings but fail with variable warpings. Full gating (where $g_t$ depends on the input) is required for invariance to general time warpings.</p>
<h3 id="per-unit-gates-and-the-connection-to-lstms">Per-unit gates and the connection to LSTMs</h3>
<p>Extending to per-unit gates $g_t^i$ allows different units to operate at different characteristic timescales:</p>
<p>$$h_{t+1}^i = g_t^i \tanh(W_x^i x_t + W_h^i h_t + b^i) + (1 - g_t^i) h_t^i$$</p>
<p>This closely resembles the LSTM cell update equation, where $(1 - g_t^i)$ corresponds to the forget gate $f_t$ and $g_t^i$ corresponds to the input gate $i_t$. The derivation naturally ties these two gates (they sum to 1), a constraint that has been used successfully in practice.</p>
<h2 id="chrono-initialization-for-gate-biases">Chrono initialization for gate biases</h2>
<p>The theoretical framework provides a principled initialization strategy. If the sequential data has temporal dependencies in a range $[T_{\text{min}}, T_{\text{max}}]$, then gate values $g$ should lie in $[1/T_{\text{max}}, 1/T_{\text{min}}]$. Since gate values center around $\sigma(b_g)$ when inputs are centered, the biases should be initialized as:</p>
<p>$$b_g \sim -\log(\mathcal{U}([T_{\text{min}}, T_{\text{max}}]) - 1)$$</p>
<p>For LSTMs specifically, the <strong>chrono initialization</strong> sets:</p>
<p>$$b_f \sim \log(\mathcal{U}([1, T_{\text{max}} - 1]))$$
$$b_i = -b_f$$</p>
<p>where $T_{\text{max}}$ is the expected range of long-term dependencies. This contrasts with the standard practice of setting forget gate biases to 1 or 2.</p>
<h2 id="experimental-validation">Experimental validation</h2>
<h3 id="time-warping-robustness">Time warping robustness</h3>
<p>On a character recall task with artificially warped sequences, three architectures are compared (64 units each):</p>
<ul>
<li><strong>Vanilla RNNs</strong> fail with even moderate warping coefficients</li>
<li><strong>Leaky RNNs</strong> perfectly solve uniform warpings but fail with variable warpings</li>
<li><strong>Gated RNNs</strong> achieve perfect performance under both uniform and variable warpings for all tested warping factors</li>
</ul>
<p>This directly validates the theory: leaky RNNs handle constant time rescalings, but only gated models handle general time warpings.</p>
<h3 id="synthetic-tasks-copy-and-adding">Synthetic tasks (copy and adding)</h3>
<p>Using 128-unit LSTMs:</p>
<ul>
<li><strong>Copy task</strong> ($T = 500, 2000$): Chrono initialization converges to the solution while standard initialization plateaus at the memoryless baseline</li>
<li><strong>Variable copy</strong> ($T = 500, 1000$): Chrono matches standard for smaller $T$ but outperforms for $T = 1000$</li>
<li><strong>Adding task</strong> ($T = 200, 750$): Chrono converges significantly faster, approximately 7x faster for $T = 750$</li>
</ul>
<h3 id="real-world-tasks">Real-world tasks</h3>
<ul>
<li><strong>Permuted MNIST</strong> (512-unit LSTM): Chrono achieves 96.3% vs. 95.4% for standard initialization</li>
<li><strong>Character-level text8</strong> (2000-unit LSTM): Slight improvement (1.37 vs. 1.38 bits-per-character)</li>
<li><strong>Word-level Penn Treebank</strong> (10-layer RHN): Comparable results to the baseline (65.4 test perplexity)</li>
</ul>
<p>Short-term dependency tasks show minimal differences, consistent with the theory that chrono initialization primarily helps when long-term dependencies dominate.</p>
<h2 id="limitations">Limitations</h2>
<p>The continuous-to-discrete time correspondence relies on a Taylor expansion with step size $\delta t = 1$. This approximation holds when the derivative of the time warping is not too large ($g_t \lesssim 1$). Discrete-time gated models are therefore invariant to time warpings that stretch time (such as interspersing data with blanks or introducing long-term dependencies), but they cannot handle warpings that compress events faster than the model&rsquo;s time step. Additionally, the chrono initialization requires specifying $T_{\text{max}}$, the expected range of long-term dependencies, which may not be known in advance.</p>
<h2 id="reproducibility">Reproducibility</h2>
<p><strong>Status: Partially Reproducible.</strong></p>
<p>The paper describes all hyperparameters, architectures, and training procedures in sufficient detail to reproduce the experiments. The synthetic tasks (copy, adding, time warping) follow standard setups from prior work with clearly specified parameters. The real-world experiments (permuted MNIST, text8, Penn Treebank) use established benchmarks with referenced codebases (the text8 setup reuses code from Cooijmans et al. 2016).</p>
<p>The chrono initialization itself requires minimal implementation effort: it only changes the bias initialization of gate units, with no modifications to the model architecture or training procedure.</p>
<p>No official code repository is provided by the authors. No pre-trained models or datasets beyond standard benchmarks are released.</p>
<hr>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Tallec, C. &amp; Ollivier, Y. (2018). Can recurrent neural networks warp time? <em>International Conference on Learning Representations (ICLR 2018)</em>.</p>
<p><strong>Publication</strong>: ICLR 2018</p>
<p><strong>Additional Resources</strong>:</p>
<ul>
<li><a href="https://openreview.net/forum?id=SJcKhk-Ab">OpenReview</a></li>
<li><a href="https://arxiv.org/abs/1804.11188">arXiv</a></li>
</ul>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@inproceedings</span>{tallec2018can,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Can recurrent neural networks warp time?}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Tallec, Corentin and Ollivier, Yann}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">booktitle</span>=<span style="color:#e6db74">{International Conference on Learning Representations}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{2018}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Score Matching and Denoising Autoencoders: A Connection</title><link>https://hunterheidenreich.com/notes/machine-learning/generative-models/score-matching-denoising-autoencoders/</link><pubDate>Sun, 21 Dec 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/generative-models/score-matching-denoising-autoencoders/</guid><description>Theoretical paper proving the equivalence between training Denoising Autoencoders and performing Score Matching on a Parzen density estimator.</description><content:encoded><![CDATA[<h2 id="what-kind-of-paper-is-this">What kind of paper is this?</h2>
<p>This is a <strong>Theory Paper</strong>.</p>
<p>Its primary contribution is a formal mathematical derivation connecting two previously distinct techniques: Score Matching (SM) and Denoising Autoencoders (DAE). It provides the &ldquo;why&rdquo; behind the empirical success of DAEs by grounding them in the probabilistic framework of energy-based models. It relies on proofs and equivalence relations (e.g., $J_{ESMq_{\sigma}} \sim J_{DSMq_{\sigma}}$).</p>
<h2 id="what-is-the-motivation">What is the motivation?</h2>
<p>The paper bridges a gap between two successful but disconnected approaches in unsupervised learning:</p>
<ol>
<li><strong>Denoising Autoencoders (DAE):</strong> Empirically successful for pre-training deep networks. They previously lacked a clear probabilistic interpretation.</li>
<li><strong>Score Matching (SM):</strong> A theoretically sound method for estimating unnormalized density models that avoids the partition function problem but requires computing expensive second derivatives.</li>
</ol>
<p>By connecting them, the authors aim to define a proper probabilistic model for DAEs (allowing sampling/ranking) and find a simpler way to apply score matching that avoids second derivatives.</p>
<h2 id="what-is-the-novelty-here">What is the novelty here?</h2>
<p>The core novelty is the <strong>Denoising Score Matching (DSM)</strong> framework and the proof of its equivalence to DAEs. Key contributions include:</p>
<ul>
<li><strong>Equivalence Proof:</strong> Showing that training a DAE with Gaussian noise is equivalent to matching the score of a model against a non-parametric Parzen density estimator of the data.</li>
<li><strong>Denoising Score Matching ($J_{DSM}$):</strong> A new objective that learns a score function by trying to denoise corrupted samples. This avoids the explicit second derivatives required by standard Implicit Score Matching ($J_{ISM}$).</li>
<li><strong>Explicit Energy Function:</strong> Deriving the specific energy function $E(x;\theta)$ that corresponds to the standard sigmoid DAE architecture.</li>
<li><strong>Justification for Tied Weights:</strong> Providing a theoretical justification for tying encoder and decoder weights, which arises naturally from differentiating the energy function.</li>
</ul>
<h2 id="what-experiments-were-performed">What experiments were performed?</h2>
<p>The validation in this theoretical paper is purely mathematical and focuses on formal proofs:</p>
<ul>
<li><strong>Derivation of Equivalence:</strong> The paper formally proves the chain of equivalences:
$$J_{ISMq_{\sigma}} \sim J_{ESMq_{\sigma}} \sim J_{DSMq_{\sigma}} \sim J_{DAE\sigma}$$
where $q_{\sigma}$ is the Parzen density estimate.</li>
<li><strong>Appendix Proof:</strong> A detailed proof is provided to show that Explicit Score Matching ($J_{ESM}$) on the Parzen density is equivalent to the proposed Denoising Score Matching ($J_{DSM}$) objective.</li>
</ul>
<h2 id="what-outcomesconclusions">What outcomes/conclusions?</h2>
<ul>
<li><strong>Theoretical Unification:</strong> DAE training is formally equivalent to Score Matching on a smoothed data distribution ($q_{\sigma}$).</li>
<li><strong>New Training Objective:</strong> The $J_{DSM}$ objective offers a computationally efficient way to perform score matching (no Hessian required) by using a denoising objective.</li>
<li><strong>Probabilistic Interpretation:</strong> DAEs can now be understood as Energy-Based Models (EBMs), allowing for operations like sampling (via Hybrid Monte Carlo) and likelihood ranking, which were previously ill-defined for standard autoencoders.</li>
<li><strong>Regularization Insight:</strong> The smoothing kernel width $\sigma$ in the Parzen estimator corresponds to the noise level in the DAE. This suggests that DAEs are learning a regularized version of the score, which may explain their robustness.</li>
<li><strong>Connection to Regularized Score Matching:</strong> The paper notes that Kingma and LeCun (2010) independently proposed a regularized score matching criterion $J_{ISMreg}$ derived by approximating $J_{ISMq_{\sigma}}$. The four $q_{\sigma}$-based objectives in this work (including the DAE objective) can be seen as approximation-free forms of regularized score matching, with the additional advantage that $J_{DSMq_{\sigma}}$ does not require second derivatives.</li>
</ul>
<hr>
<h2 id="key-concepts-explained">Key Concepts Explained</h2>
<h3 id="1-score-and-score-matching">1. &ldquo;Score&rdquo; and &ldquo;Score Matching&rdquo;</h3>
<p><strong>What does &ldquo;score&rdquo; actually mean?</strong></p>
<p>In this paper (and probabilistic modeling generally), the <strong>score</strong> is the gradient of the log-density with respect to the <em>data vector</em> $x$.</p>
<ul>
<li><strong>Definition:</strong> $\psi(x) = \nabla_x \log p(x)$.</li>
<li><strong>Intuition:</strong> It is a vector field pointing in the direction of highest probability increase. Crucially, calculating the score avoids the intractable partition function $Z$, because $\nabla_x \log p(x) = \nabla_x \log \tilde{p}(x) - \nabla_x \log Z = \nabla_x \log \tilde{p}(x)$. The constant $Z$ vanishes upon differentiation.</li>
</ul>
<p><strong>What is Score Matching?</strong></p>
<p>Score Matching is a training objective for unnormalized models. It minimizes the squared Euclidean distance between the model&rsquo;s score $\psi(x;\theta)$ and the data&rsquo;s true score $\nabla_x \log q(x)$.</p>
<h3 id="2-the-parzen-density-estimator">2. The Parzen Density Estimator</h3>
<p><strong>What is it?</strong></p>
<p>It is a non-parametric method for estimating a probability density function from finite data. It places a smooth kernel (here, a Gaussian) centered at every data point in the training set $D_n$.</p>
<ul>
<li><strong>Formula:</strong> $q_{\sigma}(\tilde{x}) = \frac{1}{n} \sum_{t=1}^n \mathcal{N}(\tilde{x}; x^{(t)}, \sigma^2 I)$.</li>
</ul>
<p><strong>Why smooth the data?</strong></p>
<ol>
<li>
<p><strong>To define the score:</strong> The empirical data distribution is a set of Dirac deltas (spikes). The gradient (score) of a Dirac delta is undefined. Smoothing creates a differentiable surface, allowing a valid target score $\nabla_{\tilde{x}} \log q_{\sigma}(\tilde{x})$ to be computed.</p>
</li>
<li>
<p><strong>To model corruption:</strong> The Parzen estimator with Gaussian kernels mathematically models the process of taking a clean data point $x$ and adding Gaussian noise - the exact procedure used in Denoising Autoencoders.</p>
</li>
</ol>
<h3 id="3-why-avoiding-second-derivatives-matters">3. Why avoiding second derivatives matters</h3>
<p>Standard <strong>Implicit Score Matching (ISM)</strong> eliminates the need for the unknown data score, but introduces a new cost: it requires computing the trace of the Hessian (the sum of second partial derivatives) of the log-density.</p>
<ul>
<li><strong>The Cost:</strong> For high-dimensional data (like images) and deep networks, computing second derivatives of the log-density is computationally expensive.</li>
<li>This paper shows that <strong>Denoising Score Matching (DSM)</strong> allows you to bypass Hessian computation entirely. By using the Parzen target, the objective simplifies to matching a first-order vector, making it scalable to deep neural networks.</li>
</ul>
<h3 id="4-the-equivalence-chain---why-each-step">4. The equivalence chain - why each step?</h3>
<p>The chain $J_{ISMq_{\sigma}} \sim J_{ESMq_{\sigma}} \sim J_{DSMq_{\sigma}} \sim J_{DAE\sigma}$ connects the concepts.</p>
<ul>
<li>
<p><strong>$J_{ISMq_{\sigma}} \sim J_{ESMq_{\sigma}}$ (Implicit $\to$ Explicit):</strong>
<strong>Why:</strong> Integration by parts. This is Hyvärinen&rsquo;s original proof (2005): integration by parts moves the derivative from $\psi$ onto the data density $q$, producing a term involving $q$&rsquo;s gradient (the score). The boundary term vanishes because $q_{\sigma}$ decays to zero at infinity (Hyvärinen&rsquo;s 2005 regularity condition for Implicit Score Matching). The result allows replacing the unknown data score with a computable term involving only the model&rsquo;s score and its Jacobian.</p>
</li>
<li>
<p><strong>$J_{ESMq_{\sigma}} \sim J_{DSMq_{\sigma}}$ (Explicit $\to$ Denoising):</strong>
<strong>Why:</strong> The explicit score of the Parzen density is known. When $x$ is perturbed to $\tilde{x}$ by Gaussian noise $\epsilon \sim \mathcal{N}(0, \sigma^2 I)$, the gradient of the log-density pointing back to the mean is exactly $\frac{1}{\sigma^2}(x - \tilde{x})$. Minimizing the error against the true score becomes minimizing the error against this restoration vector.</p>
</li>
<li>
<p><strong>$J_{DSMq_{\sigma}} \sim J_{DAE\sigma}$ (Denoising $\to$ Autoencoder):</strong>
<strong>Why:</strong> Algebraic substitution. If you define the model&rsquo;s score $\psi(\tilde{x};\theta)$ to be proportional to the reconstruction error ($\propto x^r - \tilde{x}$), the score matching loss $J_{DSM}$ becomes proportional to the standard autoencoder squared loss $|x^r - x|^2$.</p>
</li>
</ul>
<h3 id="5-energy-based-models-ebms-connection">5. Energy-Based Models (EBMs) connection</h3>
<p><strong>What is an EBM?</strong></p>
<p>An EBM defines a probability distribution via an energy function $E(x;\theta)$, where $p(x;\theta) \propto e^{-E(x;\theta)}$.</p>
<p><strong>Why standard autoencoders lack probabilistic interpretation:</strong></p>
<p>A standard autoencoder acts as a deterministic map $x \to x^r$, providing a reconstruction error. It lacks a normalization constant or a defined density function to support sampling or probability queries.</p>
<p><strong>What does this enable?</strong></p>
<p>By proving the equivalence, the DAE is formally defined as an EBM. This enables:</p>
<ol>
<li><strong>Sampling:</strong> Using MCMC methods (like Hybrid Monte Carlo) to generate new data from the DAE.</li>
<li><strong>Ranking:</strong> Calculating the energy of inputs to determine which are more &ldquo;likely&rdquo; or &ldquo;normal&rdquo; (useful for anomaly detection).</li>
</ol>
<h3 id="6-the-specific-energy-function-form">6. The specific energy function form</h3>
<p>The function is:</p>
<p>$$E(x; W, b, c) = - \frac{1}{\sigma^2} \left( \langle c, x \rangle - \frac{1}{2}|x|^2 + \sum_{j=1}^{d_h} \text{softplus}(\langle W_j, x \rangle + b_j) \right)$$</p>
<p><strong>Why does it have that specific form?</strong></p>
<p>It was derived via integration to ensure its derivative matches the DAE architecture. The authors worked backward from the DAE&rsquo;s reconstruction function (sigmoid + linear) to find the scalar field that generates it.</p>
<p><strong>Where does the quadratic term come from?</strong></p>
<p>The score (negative energy gradient) needs to look like $\psi(x) \propto c - x + W^T\text{sigmoid}(Wx + b)$.</p>
<ul>
<li>The term $-x$ in the score arises because $\nabla_x(-\frac{1}{2}|x|^2) = -x$. Including $-\frac{1}{2}|x|^2$ inside the energy&rsquo;s numerator produces this linear term after differentiation.</li>
</ul>
<p><strong>How does differentiating it recover the DAE reconstruction?</strong></p>
<ul>
<li>$\nabla_x \sum_j \text{softplus}(\langle W_j, x \rangle + b_j) = W^T \sigma(Wx + b)$ (The encoder part).</li>
<li>$\nabla_x \langle c, x \rangle = c$ (The bias).</li>
<li>$\nabla_x (-\frac{1}{2}|x|^2) = -x$ (The input subtraction).</li>
<li>Result: $-\nabla_x E \propto c + W^T h - x = x^r - x$.</li>
</ul>
<h3 id="7-tied-weights-justification">7. &ldquo;Tied weights&rdquo; justification</h3>
<p><strong>What does it mean for weights to be &ldquo;tied&rdquo;?</strong></p>
<p>The decoder matrix is the transpose of the encoder matrix ($W^T$).</p>
<p><strong>Why is this theoretically justified?</strong></p>
<p>Because the reconstruction function is interpreted as the <strong>gradient</strong> of an energy function. A vector field can only be the gradient of a scalar field if its Jacobian is symmetric.</p>
<ul>
<li>In the DAE energy derivative, the encoder contributes $W^T \sigma(Wx + b)$. If the decoder used a separate matrix $U$, the resulting vector field would not be a valid gradient of any scalar energy function (unless $U = W^T$).</li>
<li>Therefore, for a DAE to correspond to a valid probabilistic Energy-Based Model, the weights <em>must</em> be tied.</li>
</ul>
<p><strong>The necessity of tied weights:</strong></p>
<p>Within this parametrization, tied weights are a mathematical necessity: a separate decoder matrix $U \neq W^T$ would make the reconstruction function an invalid gradient of any scalar energy, breaking the EBM correspondence.</p>
<hr>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<p>Since this is a theoretical paper, the &ldquo;reproducibility&rdquo; lies in the mathematical formulations derived.</p>
<h3 id="data">Data</h3>
<ul>
<li><strong>Input Data ($D_n$):</strong> The theory assumes a set of training examples $D_n = {x^{(1)}, &hellip;, x^{(n)}}$ drawn from an unknown true pdf $q(x)$.</li>
<li><strong>Parzen Density Estimate ($q_{\sigma}$):</strong> The theoretical targets are derived from a kernel-smoothed empirical distribution:
$$q_{\sigma}(\tilde{x}) = \frac{1}{n} \sum_{t=1}^n q_{\sigma}(\tilde{x}|x^{(t)})$$
where the kernel is an isotropic Gaussian of variance $\sigma^2$.</li>
</ul>
<h3 id="algorithms">Algorithms</h3>
<p><strong>1. Denoising Score Matching (DSM) Objective</strong></p>
<p>The paper proposes this objective as a tractable alternative to standard score matching. It minimizes the distance between the model score and the gradient of the log-noise density:</p>
<p>$$J_{DSMq_{\sigma}}(\theta) = \mathbb{E}_{q_{\sigma}(x,\tilde{x})} \left[ \frac{1}{2} \left| \psi(\tilde{x};\theta) - \frac{\partial \log q_{\sigma}(\tilde{x}|x)}{\partial \tilde{x}} \right|^2 \right]$$</p>
<p>For Gaussian noise, the target score is simply $\frac{1}{\sigma^2}(x - \tilde{x})$.</p>
<p><strong>2. Equivalence Chain</strong></p>
<p>The central result connects four objectives:</p>
<p>$$J_{ISMq_{\sigma}} \sim J_{ESMq_{\sigma}} \sim J_{DSMq_{\sigma}} \sim J_{DAE\sigma}$$</p>
<p>This implies optimizing the DAE reconstruction error is minimizing a score matching objective.</p>
<h3 id="models">Models</h3>
<p><strong>1. The Denoising Autoencoder (DAE)</strong></p>
<ul>
<li><strong>Corruption:</strong> Additive isotropic Gaussian noise $\tilde{x} = x + \epsilon, \epsilon \sim \mathcal{N}(0, \sigma^2 I)$.</li>
<li><strong>Encoder:</strong> $h = \text{sigmoid}(W\tilde{x} + b)$.</li>
<li><strong>Decoder:</strong> $x^r = W^T h + c$ (Tied weights $W$).</li>
<li><strong>Loss:</strong> Squared reconstruction error $|x^r - x|^2$. (The equivalence with DSM introduces a $\frac{1}{2\sigma^4}$ scaling factor.)</li>
</ul>
<p><strong>2. The Corresponding Energy Function</strong></p>
<p>To make the DAE equivalent to Score Matching, the underlying Energy-Based Model $p(x;\theta) \propto e^{-E(x;\theta)}$ must have the following energy function:</p>
<p>$$E(x; W, b, c) = - \frac{1}{\sigma^2} \left( \langle c, x \rangle - \frac{1}{2}|x|^2 + \sum_{j=1}^{d_h} \text{softplus}(\langle W_j, x \rangle + b_j) \right)$$</p>
<p>Note the scaling by $1/\sigma^2$ and the quadratic term $|x|^2$.</p>
<h3 id="evaluation">Evaluation</h3>
<ul>
<li><strong>Metric:</strong> Theoretical Equivalence ($\sim$).</li>
<li><strong>Condition:</strong> The equivalence holds provided $\sigma &gt; 0$ and the density $q_{\sigma}$ is differentiable and vanishes at infinity (Hyvärinen&rsquo;s 2005 regularity condition for Implicit Score Matching).</li>
</ul>
<hr>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Vincent, P. (2011). A Connection Between Score Matching and Denoising Autoencoders. <em>Neural Computation</em>, 23(7), 1661-1674. <a href="https://doi.org/10.1162/NECO_a_00142">https://doi.org/10.1162/NECO_a_00142</a></p>
<p><strong>Publication</strong>: Neural Computation 2011</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{vincentConnectionScoreMatching2011,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span> = <span style="color:#e6db74">{A {{Connection Between Score Matching}} and {{Denoising Autoencoders}}}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span> = <span style="color:#e6db74">{Vincent, Pascal}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span> = <span style="color:#ae81ff">2011</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">month</span> = jul,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span> = <span style="color:#e6db74">{Neural Computation}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span> = <span style="color:#e6db74">{23}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span> = <span style="color:#e6db74">{7}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span> = <span style="color:#e6db74">{1661--1674}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">doi</span> = <span style="color:#e6db74">{10.1162/NECO_a_00142}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div><p><strong>Additional Resources</strong>:</p>
<ul>
<li><a href="https://www.iro.umontreal.ca/~vincentp/Publications/smdae_techreport.pdf">Official PDF</a></li>
</ul>
]]></content:encoded></item><item><title>A Convexity Principle for Interacting Gases (McCann 1997)</title><link>https://hunterheidenreich.com/notes/machine-learning/generative-models/convexity-principle-interacting-gases/</link><pubDate>Sun, 21 Dec 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/generative-models/convexity-principle-interacting-gases/</guid><description>Introduces displacement interpolation to prove ground state uniqueness via optimal transport, with mathematical tools later used in generative modeling.</description><content:encoded><![CDATA[<h2 id="what-kind-of-paper-is-this">What kind of paper is this?</h2>
<p>This is a <a href="/notes/research-methods/ai-physical-sciences-paper-taxonomy/">Theory</a> paper. It relies entirely on formal mathematical derivation to establish existence and uniqueness properties for energy functionals. It introduces a new mathematical structure (displacement interpolation) to analyze the geometry of probability measures.</p>
<h2 id="what-is-the-motivation">What is the motivation?</h2>
<p>The paper addresses the uniqueness of stationary configurations (ground states) for a gas model where particles interact via attractive forces while resisting compression.</p>
<p>The total energy functional $E(\rho)$ includes an interaction term $G(\rho)$ that lacks convexity under standard linear interpolation ($(1-t)\rho + t\rho&rsquo;$), making it difficult to prove that a unique minimizer exists. Standard convexity tools and rearrangement inequalities are also insufficient for cases without specific symmetries (like spherical symmetry) or when convexity of the potential fails.</p>
<h2 id="what-is-the-novelty-here">What is the novelty here?</h2>
<p>The core novelty is the introduction of <strong>Displacement Interpolation</strong>.</p>
<ul>
<li><strong>New Interpolant</strong>: The paper defines an interpolant $\rho_t$ by moving mass along the gradient of a convex potential $\psi$ (transport map).</li>
<li><strong>Displacement Convexity</strong>: It proves that the internal energy $U(\rho)$ and potential energy $G(\rho)$ become convex functions of $t$ along this displacement path. This is a property specific to displacement interpolation.</li>
<li><strong>Generalization</strong>: This framework generalizes the classical <strong>Brunn-Minkowski inequality</strong> from sets to measures.</li>
</ul>
<h3 id="theoretical-framework">Theoretical Framework</h3>
<h4 id="mathematical-setup">Mathematical Setup</h4>
<p><strong>Probability Measures</strong></p>
<p>The gas state is represented by absolutely continuous probability measures $\rho \in \mathcal{P}_{ac}(\mathbb{R}^d)$ with finite second moments.</p>
<p><strong>Energy Functional</strong></p>
<p>The gas model is defined by the total energy functional $E(\rho)$:
$$E(\rho) := \underbrace{\int_{\mathbb{R}^d} A(\rho(x))dx}_{\text{Internal Energy } U(\rho)} + \underbrace{\frac{1}{2} \iint d\rho(x)V(x-y)d\rho(y)}_{\text{Potential Energy } G(\rho)}$$</p>
<h4 id="key-construction-displacement-interpolation">Key Construction: Displacement Interpolation</h4>
<p>The core theoretical tool is the construction of the interpolant $\rho_t$ between two probability measures $\rho$ and $\rho&rsquo;$:</p>
<ol>
<li><strong>Transport Map</strong>: By Brenier&rsquo;s theorem, there exists a convex function $\psi$ such that $\nabla\psi_{\#}\rho = \rho&rsquo;$ (push-forward).</li>
<li><strong>Interpolation</strong>: The interpolant at time $t \in [0,1]$ is defined as the push-forward of $\rho$ under the linear interpolation of the identity and the transport map:
$$\rho_t := [(1-t)\text{id} + t\nabla\psi]_{\#}\rho$$</li>
</ol>
<p>This is the &ldquo;displacement interpolation&rdquo; where mass moves along straight lines from initial to final positions.</p>
<h4 id="assumptions-for-uniqueness">Assumptions for Uniqueness</h4>
<p>The main existence and uniqueness theorem (Theorem 3.1) requires one condition on the interaction potential, two conditions on the equation of state, and one regularity condition:</p>
<ol>
<li><strong>Interaction</strong>: $V(x)$ is strictly convex.</li>
<li><strong>(P1) Equation of State</strong>: $P(\rho) / \rho^{(d-1)/d}$ is non-decreasing. This is equivalent to convexity of $U$ under mass-preserving dilations, and is satisfied by polytropic gases $P(\rho) = \rho^q$ with $q &gt; 1$.</li>
<li><strong>(P2) Growth Condition</strong>: $P(\rho) \cdot \rho^{-2}$ is not integrable at $\infty$. This ensures the energy minimizer has no singular part with respect to Lebesgue measure.</li>
<li><strong>Regularity</strong>: $\rho \in \mathcal{P}_{ac}(\mathbb{R}^d)$ (absolutely continuous probability measures).</li>
</ol>
<h4 id="main-results">Main Results</h4>
<p><strong>Theorem 2.2</strong> (Displacement Convexity of Internal Energy): Under condition (A1) (that $\lambda^d A(\lambda^{-d})$ is convex non-increasing on $(0, \infty)$ with $A(0) = 0$, ensuring internal energy decreases as the gas dilates), the internal energy $U(\rho)$ is convex along displacement interpolation paths. Strict convexity follows unless $\nabla^2\psi(x) = I$ holds $\rho$-a.e., i.e., $\rho&rsquo;$ is a translate of $\rho$.</p>
<p><strong>Theorem 3.1</strong> (Existence and Uniqueness of Ground State): For any equation of state satisfying (P1) and (P2) with a strictly convex interaction potential $V$, the total energy $E(\rho)$ attains a unique minimizer up to translation. The minimizer can be taken to be even, meaning $\rho_g(x) = \rho_g(-x)$.</p>
<p><strong>Theorem 3.3</strong> (Uniqueness for Spherically Symmetric Potentials): When the strict convexity of $V(x)$ is relaxed to spherical symmetry (with $V$ not constant), uniqueness up to translation still holds provided (P1) holds strictly. This extends the main result to cases like Coulomb-type interactions.</p>
<p><strong>Lemma 3.2</strong>: A decomposition lemma for convex functions. Let $\psi$ and $\phi$ be convex on $\mathbb{R}^d$, and let $\Omega \subset \mathbb{R}^d$ be an open convex set on which both are finite. Suppose $\phi$ is differentiable on $\Omega$ with a locally Lipschitz gradient. If their Aleksandrov second derivatives agree almost everywhere on $\Omega$, then $\psi - \phi$ is convex on $\Omega$. This underpins the proof of Theorem 3.3.</p>
<h2 id="what-experiments-were-performed">What experiments were performed?</h2>
<p>The validation consists entirely of rigorous mathematical proofs:</p>
<ul>
<li><strong>Convexity Proofs</strong>: Deriving inequalities to show $E(\rho_t) \le (1-t)E(\rho) + tE(\rho&rsquo;)$.</li>
<li><strong>Existence/Uniqueness</strong>: Using the new convexity principle to prove that the energy minimizer is unique up to translation.</li>
</ul>
<h2 id="what-outcomesconclusions">What outcomes/conclusions?</h2>
<ul>
<li><strong>Uniqueness of Ground State</strong>: For equations of state satisfying specific monotonicity conditions (e.g., polytropic gases), the energy minimizing state is unique up to translation.</li>
<li><strong>Brunn-Minkowski Extension</strong>: The internal energy convexity implies the Brunn-Minkowski inequality as a special case ($A(\rho) = -\rho^{(d-1)/d}$).</li>
<li><strong>Norm Concavity</strong>: The functional $|\rho_t|_q^{-p/d}$ is shown to be concave along the interpolation path for conjugate $p, q$ with $q \geq (d-1)/d$.</li>
</ul>
<h3 id="relevance-to-machine-learning">Relevance to Machine Learning</h3>
<p>This 1997 paper establishes the mathematical foundations of displacement convexity in optimal transport theory, which underpins several modern generative modeling techniques. The displacement interpolation framework introduced here is used in:</p>
<ul>
<li><strong>Flow Matching</strong>: Uses optimal transport probability paths (straight-line interpolations with constant speed) to generate samples. See the <a href="../flow-matching-for-generative-modeling/">Flow Matching note</a> for details on how OT paths differ from diffusion paths.</li>
<li><strong>Wasserstein GANs</strong>: Use the Wasserstein distance (optimal transport metric) for training stability.</li>
<li><strong>Continuous Normalizing Flows</strong>: Use OT-inspired transport maps for probability density transformation.</li>
</ul>
<p>McCann&rsquo;s convexity principle proves that energy functionals become convex along displacement paths, a mathematical structure that underpins the geometry used in flow matching and optimal transport-based generative modeling.</p>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: McCann, R. J. (1997). A Convexity Principle for Interacting Gases. <em>Advances in Mathematics</em>, 128(1), 153-179. <a href="https://doi.org/10.1006/aima.1997.1634">https://doi.org/10.1006/aima.1997.1634</a></p>
<p><strong>Publication</strong>: Advances in Mathematics 1997</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{mccannConvexityPrincipleInteracting1997,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span> = <span style="color:#e6db74">{A {{Convexity Principle}} for {{Interacting Gases}}}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span> = <span style="color:#e6db74">{McCann, Robert J.}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span> = <span style="color:#ae81ff">1997</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">month</span> = jun,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span> = <span style="color:#e6db74">{Advances in Mathematics}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span> = <span style="color:#e6db74">{128}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span> = <span style="color:#e6db74">{1}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span> = <span style="color:#e6db74">{153--179}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">issn</span> = <span style="color:#e6db74">{00018708}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">doi</span> = <span style="color:#e6db74">{10.1006/aima.1997.1634}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">urldate</span> = <span style="color:#e6db74">{2025-12-21}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Kinetic Oscillations in CO Oxidation on Pt(100): Theory</title><link>https://hunterheidenreich.com/notes/chemistry/molecular-simulation/surface-science/kinetic-oscillations-pt100-1985/</link><pubDate>Sun, 14 Dec 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/chemistry/molecular-simulation/surface-science/kinetic-oscillations-pt100-1985/</guid><description>Theoretical model using coupled differential equations to explain CO oxidation oscillations via surface phase transitions on platinum.</description><content:encoded><![CDATA[














<figure class="post-figure center ">
    <img src="/img/notes/co-pt100-hollow.webp"
         alt="Carbon monoxide molecule adsorbed on Pt(100) FCC surface in hollow site configuration"
         title="Carbon monoxide molecule adsorbed on Pt(100) FCC surface in hollow site configuration"
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption">CO molecule adsorbed in hollow site on Pt(100) surface. The surface structure and CO binding configurations are central to understanding the oscillatory behavior.</figcaption>
    
</figure>

<h2 id="contribution-theoretical-modeling-of-kinetic-oscillations">Contribution: Theoretical Modeling of Kinetic Oscillations</h2>
<p><strong>Theory ($\Psi_{\text{Theory}}$)</strong>.</p>
<p>This paper derives a microscopic mechanism based on experimental kinetic data to explain observed kinetic oscillations. It relies heavily on <strong>formal analysis</strong>, including a <strong>Linear Stability Analysis</strong> of a simplified model to derive eigenvalues and characterize stationary points (stable nodes, saddle points, and foci) whose appearance and disappearance drive relaxation oscillations. The primary contribution is the mathematical formulation of the surface phase transition.</p>
<h2 id="motivation-explaining-periodicity-in-surface-reactions">Motivation: Explaining Periodicity in Surface Reactions</h2>
<p>Experimental studies had shown that the catalytic oxidation of Carbon Monoxide (CO) on Platinum (100) surfaces exhibits temporal oscillations and spatial wave patterns at low pressures ($10^{-4}$ Torr). While the individual elementary steps (adsorption, desorption, reaction) were known, the mechanism driving the periodicity was not understood. Prior models relied on indirect evidence; this work aimed to ground the theory in new LEED (Low-Energy Electron Diffraction) observations showing that the surface structure itself transforms periodically between a reconstructed <code>hex</code> phase and a bulk-like <code>1x1</code> phase.</p>
<h2 id="novelty-the-surface-phase-transition-model">Novelty: The Surface Phase Transition Model</h2>
<p>The core novelty is the <strong>Surface Phase Transition Model</strong>. The authors propose that the oscillations are driven by the reversible phase transition of the Pt surface atoms, which is triggered by critical adsorbate coverages:</p>
<ol>
<li><strong>State Dependent Kinetics</strong>: The <code>hex</code> and <code>1x1</code> phases have vastly different sticking coefficients for Oxygen (negligible on <code>hex</code>, high on <code>1x1</code>).</li>
<li><strong>Critical Coverage Triggers</strong>: The transition depends on whether local CO coverage exceeds a critical threshold ($U_{a,grow}$) or falls below another ($U_{a,crit}$).</li>
<li><strong>Trapping-Desorption</strong>: The model introduces a &ldquo;trapping&rdquo; term where CO diffuses from the weakly-binding <code>hex</code> phase to the strongly-binding <code>1x1</code> patches, creating a feedback loop.</li>
</ol>
<h2 id="methodology-reaction-diffusion-simulations">Methodology: Reaction-Diffusion Simulations</h2>
<p>As a theoretical paper, the &ldquo;experiments&rdquo; were computational simulations and mathematical derivations:</p>
<ul>
<li><strong>Linear Stability Analysis</strong>: They simplified the 4-variable model to a 3-variable system ($u$, $v$, $a$), then treated the phase fraction $a$ as a slowly varying parameter. This allowed them to perform a 2-variable stability analysis on the $u$-$v$ subsystem, identifying the conditions for oscillations through the appearance and disappearance of stationary points as $a$ varies.</li>
<li><strong>Hysteresis Simulation</strong>: They simulated temperature-programmed variations to match experimental CO adsorption hysteresis loops, fitting the critical coverage parameters ($U_{a,grow} \approx 0.5$).</li>
<li><strong>Reaction-Diffusion Simulation</strong>: They numerically integrated the full set of 4 coupled differential equations over a 1D spatial grid (40 compartments) to reproduce temporal oscillations and propagating wave fronts.</li>
</ul>
<h2 id="results-mechanisms-of-spatiotemporal-self-organization">Results: Mechanisms of Spatiotemporal Self-Organization</h2>
<ul>
<li><strong>Mechanism Validation</strong>: The model successfully reproduced the asymmetric oscillation waveform (a slow plateau followed by a steep breakdown) observed in work function and LEED measurements.</li>
<li><strong>Phase Transition Role</strong>: Confirmed that the &ldquo;slow&rdquo; step driving the oscillation period is the phase transformation, specifically the requirement for CO to build up to a critical level to nucleate the reactive <code>1x1</code> phase.</li>
<li><strong>Spatial Self-Organization</strong>: The addition of diffusion terms allowed the model to reproduce wave propagation, showing that defects at crystal edges can act as &ldquo;pacemakers&rdquo; or triggers for the rest of the surface.</li>
<li><strong>Chaotic Behavior</strong>: Under slightly different conditions (e.g., $T = 470$ K instead of 480 K), the coupled system produces irregular, chaotic work function oscillations. This arises when not every trigger compartment oscillation drives a wave into the bulk because the bulk has not yet recovered from the previous wave front. The authors note that such irregular behavior is the rule rather than the exception in experimental observations.</li>
<li><strong>Quantitative Limitations</strong>: The calculated oscillation periods are at least one order of magnitude shorter than experimental values (1 to 4 min). This discrepancy arises mainly from unrealistically high values of $k_5$ and $k_8$ used to reduce computational time. The model also restricts spatial analysis to a 1D grid, which oversimplifies the true 2D wave patterns seen in experiments. The authors note that microscopic adsorbate-adsorbate interactions and island formation are not included, which would require multi-scale modeling.</li>
</ul>
<hr>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<p>To faithfully replicate this study, one must implement the system of four coupled differential equations. The hardware requirements are negligible by modern standards.</p>
<h3 id="models">Models</h3>
<p>The system tracks four state variables:</p>
<ol>
<li>$u_a$: CO coverage on the <code>1x1</code> phase (normalized to local area $a$)</li>
<li>$u_b$: CO coverage on the <code>hex</code> phase (normalized to local area $b$)</li>
<li>$v_a$: Oxygen coverage on the <code>1x1</code> phase (normalized to local area $a$)</li>
<li>$a$: Fraction of surface in <code>1x1</code> phase ($b = 1 - a$)</li>
</ol>
<p><strong>The Governing Equations:</strong></p>
<p><strong>CO coverage on 1x1 phase:</strong>
$$
\begin{aligned}
\frac{\partial u_a}{\partial t} = k_1 a p_{CO} - k_2 u_a + k_3 a u_b - k_4 u_a v_a / a + k_5 \nabla^2(u_a/a)
\end{aligned}
$$</p>
<p><strong>CO coverage on hex phase:</strong>
$$
\begin{aligned}
\frac{\partial u_b}{\partial t} = k_1 b p_{CO} - k_6 u_b - k_3 a u_b
\end{aligned}
$$</p>
<p><strong>Oxygen coverage on 1x1 phase:</strong>
$$
\begin{aligned}
\frac{\partial v_a}{\partial t} = k_7 a p_{O_2} \left[ \left(1 - 2 \frac{u_a}{a} - \frac{5}{3} \frac{v_a}{a}\right)^2 + \alpha \left(1 - \frac{5}{3}\frac{v_a}{a}\right)^2 \right] - k_4 u_a v_a / a
\end{aligned}
$$</p>
<p><strong>The Phase Transition Logic ($da/dt$):</strong></p>
<p>The growth of the <code>1x1</code> phase ($a$) is piecewise, defined by critical coverages:</p>
<ul>
<li>If $U_a &gt; U_{a,grow}$ and $\partial u_a/\partial t &gt; 0$: island growth with $\partial a/\partial t = (1/U_{a,grow}) \cdot \partial u_a/\partial t$</li>
<li>If $c = U_a/U_{a,crit} + V_a/V_{a,crit} &lt; 1$: decay to hex with $\partial a/\partial t = -k_8 a c$</li>
<li>Otherwise: $\partial a/\partial t = 0$</li>
</ul>
<h3 id="algorithms">Algorithms</h3>
<ul>
<li><strong>Time Integration</strong>: Runge-Kutta-Merson routine.</li>
<li><strong>Spatial Integration</strong>: Crank-Nicholson algorithm for the diffusion term.</li>
<li><strong>Time Step</strong>: $\Delta t = 10^{-4}$ s.</li>
<li><strong>Spatial Grid</strong>: 1D array of 40 compartments, total length 0.4 cm (each compartment 0.01 cm).</li>
<li><strong>Boundary Conditions</strong>: Closed ends (no flux). Defects simulated by setting $\alpha$ higher in the first 3 &ldquo;edge&rdquo; compartments.</li>
</ul>
<h3 id="data">Data</h3>
<p>Replication requires the specific rate constants. Note: $k_3$ and $\alpha$ are fitting parameters.</p>
<table>
	<thead>
			<tr>
					<th>Parameter</th>
					<th>Symbol</th>
					<th>Value (at 480 K)</th>
					<th>Description</th>
			</tr>
	</thead>
	<tbody>
			<tr>
					<td>CO Stick</td>
					<td>$k_1$</td>
					<td>$2.94 \times 10^5$ ML/s/Torr</td>
					<td>Pre-exponential factor</td>
			</tr>
			<tr>
					<td>CO Desorp (1x1)</td>
					<td>$k_2$</td>
					<td>$1.5$ s$^{-1}$ ($U_a = 0.5$)</td>
					<td>$E_a = 37.3$ (low cov), $33.5$ kcal/mol (high cov)</td>
			</tr>
			<tr>
					<td>Trapping</td>
					<td>$k_3$</td>
					<td>$50 \pm 30$ s$^{-1}$</td>
					<td>Hex to 1x1 diffusion</td>
			</tr>
			<tr>
					<td>Reaction</td>
					<td>$k_4$</td>
					<td>$10^3 - 10^5$ ML$^{-1}$s$^{-1}$</td>
					<td>Langmuir-Hinshelwood</td>
			</tr>
			<tr>
					<td>Diffusion</td>
					<td>$k_5$</td>
					<td>$4 \times 10^{-4}$ cm$^2$/s</td>
					<td>CO surface diffusion (elevated for computational speed; realistic: $10^{-7}$ to $10^{-5}$)</td>
			</tr>
			<tr>
					<td>CO Desorp (hex)</td>
					<td>$k_6$</td>
					<td>$11$ s$^{-1}$</td>
					<td>$E_a = 27.5$ kcal/mol</td>
			</tr>
			<tr>
					<td>O2 Adsorption</td>
					<td>$k_7$</td>
					<td>$5.6 \times 10^5$ ML/s/Torr</td>
					<td>Only on 1x1 phase</td>
			</tr>
			<tr>
					<td>Phase Trans</td>
					<td>$k_8$</td>
					<td>$0.4 - 2.0$ s$^{-1}$</td>
					<td>Relaxation constant</td>
			</tr>
			<tr>
					<td>Defect Coeff</td>
					<td>$\alpha$</td>
					<td>$0.1 - 0.5$</td>
					<td>Fitting param for defects</td>
			</tr>
			<tr>
					<td>Crit Cov (Grow)</td>
					<td>$U_{a,grow}$</td>
					<td>$0.5 \pm 0.1$</td>
					<td>Trigger for hex to 1x1</td>
			</tr>
			<tr>
					<td>Crit Cov (Decay)</td>
					<td>$U_{a,crit}$</td>
					<td>$0.32$</td>
					<td>Trigger for 1x1 to hex (CO)</td>
			</tr>
			<tr>
					<td>Crit O Cov</td>
					<td>$V_{a,crit}$</td>
					<td>$0.4$</td>
					<td>Trigger for 1x1 to hex (O)</td>
			</tr>
	</tbody>
</table>
<h3 id="evaluation">Evaluation</h3>
<p>The model was evaluated by comparing the simulated temporal oscillations and spatial wave patterns against experimental work function measurements and LEED observations.</p>
<h3 id="hardware">Hardware</h3>
<p>The hardware requirements are negligible by modern standards. The original simulations were likely performed on a mainframe or minicomputer of the era. Today, they can be run on any standard personal computer.</p>
<hr>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Imbihl, R., Cox, M. P., Ertl, G., Müller, H., &amp; Brenig, W. (1985). Kinetic oscillations in the catalytic CO oxidation on Pt(100): Theory. <em>The Journal of Chemical Physics</em>, 83(4), 1578-1587. <a href="https://doi.org/10.1063/1.449834">https://doi.org/10.1063/1.449834</a></p>
<p><strong>Publication</strong>: The Journal of Chemical Physics 1985</p>
<p><strong>Related Work</strong>: See also <a href="/notes/chemistry/molecular-simulation/surface-science/oscillatory-co-oxidation-pt110-1992/">Oscillatory CO Oxidation on Pt(110)</a> for the same catalytic system on a different crystal face, demonstrating that surface phase transitions drive oscillatory behavior across multiple platinum surfaces.</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{imbihl1985kinetic,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Kinetic oscillations in the catalytic CO oxidation on Pt(100): Theory}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Imbihl, R and Cox, MP and Ertl, G and M{\&#34;u}ller, H and Brenig, W}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span>=<span style="color:#e6db74">{The Journal of Chemical Physics}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span>=<span style="color:#e6db74">{83}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span>=<span style="color:#e6db74">{4}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span>=<span style="color:#e6db74">{1578--1587}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{1985}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">publisher</span>=<span style="color:#e6db74">{American Institute of Physics}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Distributed Representations: A Foundational Theory</title><link>https://hunterheidenreich.com/notes/machine-learning/model-architectures/distributed-representations/</link><pubDate>Sun, 14 Dec 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/model-architectures/distributed-representations/</guid><description>Hinton's 1984 technical report establishing the theoretical efficiency of distributed representations over local encoding in neural networks.</description><content:encoded><![CDATA[<h2 id="what-kind-of-paper-is-this">What kind of paper is this?</h2>
<p>This is primarily a <strong>Theory</strong> paper, with strong secondary elements of <strong>Method</strong> and <strong>Position</strong>.</p>
<p>It is a theoretical work because its core contribution is the formal mathematical derivation of the encoding accuracy and error properties of distributed schemes (coarse coding) compared to local schemes. It serves as a position paper by challenging the &ldquo;grandmother cell&rdquo; (local representation) intuition prevalent in AI at the time and advocating for the &ldquo;constructive&rdquo; view of memory.</p>
<h2 id="what-is-the-motivation">What is the motivation?</h2>
<p>The motivation is to overcome the inefficiency of <strong>local representations</strong>, where one hardware unit corresponds to exactly one entity, and to challenge traditional metaphors of memory.</p>
<ul>
<li><strong>Inefficiency</strong>: In local representations, high accuracy requires an exponential number of units (accuracy $\propto \sqrt[k]{n}$ for $k$ dimensions).</li>
<li><strong>Brittleness</strong>: Local representations lack natural support for generalization; learning a fact about one concept (e.g., &ldquo;chimps like onions&rdquo;) requires extra machinery to transfer to similar concepts (e.g., &ldquo;gorillas&rdquo;).</li>
<li><strong>Hardware Mismatch</strong>: Massive parallelism is wasted if units are active rarely (1 bit of info per unit active 50% of the time vs. almost 0 for sparse local units).</li>
<li><strong>The &ldquo;Filing Cabinet&rdquo; Metaphor</strong>: The paper challenges the standard view of memory as a storage system of literal copies. It motivates a shift toward understanding memory as a reconstructive inference process.</li>
</ul>
<h2 id="what-is-the-novelty-here">What is the novelty here?</h2>
<p>The paper introduces formal mechanisms that explain <em>why</em> distributed representations are superior:</p>
<ol>
<li><strong>Coarse Coding Efficiency</strong>: Hinton proves that using broad, overlapping receptive fields (&ldquo;coarse coding&rdquo;) yields higher accuracy for a fixed number of units than non-overlapping local fields. For a $k$-dimensional feature space with $n$ units of receptive field radius $r$, accuracy scales as $a \propto n \cdot r^{k-1}$. This is far superior to local encoding, where accuracy scales as $a \propto n^{1/k}$.</li>
<li><strong>Automatic Generalization</strong>: It demonstrates that generalization is an emergent property of vector overlap. Modifying weights for one pattern automatically affects similar patterns (conspiracy effect).</li>
<li><strong>Memory as Reconstruction</strong>: It posits that memory is a reconstructive process where items are created afresh from fragments using plausible inference rules (connection strengths). This blurs the line between veridical recall and confabulation.</li>
<li><strong>Gradual Concept Formation</strong>: Distributed representations allow new concepts to emerge gradually through weight modifications that progressively differentiate existing concepts. This avoids the discrete decisions and spare hardware units required by local representations.</li>
<li><strong>Solution to the Binding Problem</strong>: It proposes that true part/whole hierarchies are formed by fusing the identity of a part with its role to produce a single, new subpattern. The representation of the whole is then the sum of these combined identity/role representations.</li>
</ol>















<figure class="post-figure center ">
    <img src="/img/notes/distributed-representations-binding.svg"
         alt="Diagram showing distributed representations with three pools of units (AGENT, RELATIONSHIP, PATIENT) connected via role/identity bindings"
         title="Diagram showing distributed representations with three pools of units (AGENT, RELATIONSHIP, PATIENT) connected via role/identity bindings"
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption">The binding problem solution: true hierarchies require creating unique subpatterns that fuse an identity with its role, where the whole is represented as the sum of these combined representations.</figcaption>
    
</figure>

<h2 id="what-experiments-were-performed">What experiments were performed?</h2>
<p>The paper performs analytical derivations and two specific computer simulations:</p>
<ol>
<li><strong>Arbitrary Mapping Simulation</strong>: A 3-layer network trained to map 20 grapheme strings (e.g., words) to 20 unrelated semantic vectors.</li>
<li><strong>Damage &amp; Recovery Analysis</strong>:
<ul>
<li><strong>Lesioning</strong>: Removing a single word-set unit to observe error patterns. This produced &ldquo;Deep Dyslexia&rdquo;-like semantic errors (e.g., reading &ldquo;PEACH&rdquo; as &ldquo;APRICOT&rdquo;), where the clean-up effect settles on a similar but incorrect meaning.</li>
<li><strong>Noise Injection</strong>: Adding noise to all connections involving word-set units, reducing performance from 99.3% to 64.3%.</li>
<li><strong>Retraining</strong>: Measuring the speed of relearning after noise damage (&ldquo;spontaneous recovery&rdquo;), where unrehearsed items recover alongside rehearsed ones due to shared weights.</li>
</ul>
</li>
</ol>
<h2 id="what-outcomesconclusions">What outcomes/conclusions?</h2>
<ol>
<li><strong>Accuracy Scaling</strong>: For a $k$-dimensional feature space, the accuracy $a$ of a distributed representation scales as $a \propto n \cdot r^{k-1}$ (where $r$ is the receptive field radius), vastly outperforming local schemes.</li>
<li><strong>Reliability</strong>: Distributed systems exhibit graceful degradation. Removing units causes slight noise across many items.</li>
<li><strong>Spontaneous Recovery</strong>: When retraining a damaged network on a subset of items, the network &ldquo;spontaneously&rdquo; recovers unrehearsed items due to weight sharing, which is a qualitative signature of distributed representations.</li>
<li><strong>Limitations of Coarse Coding</strong>: The paper identifies that coarse coding requires relatively sparse features. Crowding too many feature-points together causes receptive fields to contain too many features, preventing the activity pattern from discriminating between combinations.</li>
<li><strong>Sequential Processing Constraint</strong>: When constituent structure is represented using identity/role bindings, only one structure can be represented at a time. Hinton argues this matches the empirical observation that people are, to a first approximation, sequential symbol processors.</li>
<li><strong>Learning Problem Deferred</strong>: The paper acknowledges that discovering which sets of items should correspond to single units is a difficult search problem, and defers the learning question to separate work (Hinton, Sejnowski, and Ackley, 1984).</li>
</ol>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<p>The following details are extracted from Section 5 (&ldquo;Implementing an Arbitrary Mapping&rdquo;) to facilitate reproduction of the &ldquo;Deep Dyslexia&rdquo; and &ldquo;Arbitrary Mapping&rdquo; simulation.</p>
<h3 id="data">Data</h3>
<p>The simulation uses synthetic data representing words and meanings.</p>
<table>
	<thead>
			<tr>
					<th>Purpose</th>
					<th>Dataset</th>
					<th>Size</th>
					<th>Notes</th>
			</tr>
	</thead>
	<tbody>
			<tr>
					<td>Training</td>
					<td>Synthetic Grapheme/Sememe Pairs</td>
					<td>20 pairs</td>
					<td>20 different grapheme strings mapped to random semantic vectors.</td>
			</tr>
	</tbody>
</table>
<ul>
<li><strong>Input (Graphemes)</strong>: 30 total units.
<ul>
<li>Structure: Divided into 3 groups of 10 units each.</li>
<li>Encoding: Each &ldquo;word&rdquo; (3 letters) activates exactly 1 unit in each group (sparse binary).</li>
</ul>
</li>
<li><strong>Output (Sememes)</strong>: 30 total units.
<ul>
<li>Structure: Binary units.</li>
<li>Encoding: Meanings are random vectors where each unit is active with probability $p=0.2$.</li>
</ul>
</li>
</ul>
<h3 id="algorithms">Algorithms</h3>
<ul>
<li><strong>Learning Rule</strong>: The paper cites &ldquo;Hinton, Sejnowski &amp; Ackley (1984)&rdquo; (Boltzmann Machines) for the specific learning algorithm used to set weights.</li>
<li><strong>False Positive Analysis</strong>: The probability $f$ that a semantic feature is incorrectly activated is derived as:</li>
</ul>
<p>$$f = (1 - (1-p)^{(w-1)})^u$$</p>
<p>Where:</p>
<ul>
<li>$p$: Probability of a sememe being in a word meaning ($0.2$).</li>
<li>$w$: Number of words in a &ldquo;word-set&rdquo; (cluster).</li>
<li>$u$: Number of active &ldquo;word-set&rdquo; units per word.</li>
</ul>
<h3 id="models">Models</h3>
<p>The simulation uses a specific three-layer architecture.</p>
<table>
	<thead>
			<tr>
					<th>Layer</th>
					<th>Type</th>
					<th>Count</th>
					<th>Connectivity</th>
			</tr>
	</thead>
	<tbody>
			<tr>
					<td><strong>Input</strong></td>
					<td>Grapheme Units</td>
					<td>30</td>
					<td>Connected to all Intermediate units (no direct link to Output).</td>
			</tr>
			<tr>
					<td><strong>Hidden</strong></td>
					<td>&ldquo;Word-Set&rdquo; Units</td>
					<td>20</td>
					<td>Fully connected to Input and Output.</td>
			</tr>
			<tr>
					<td><strong>Output</strong></td>
					<td>Sememe Units</td>
					<td>30</td>
					<td>Connected to all Intermediate units. Includes lateral inhibition (implied for &ldquo;clean up&rdquo;).</td>
			</tr>
	</tbody>
</table>
<ul>
<li><strong>Weights</strong>: Binary/Integer logic in theoretical analysis, but &ldquo;stochastic&rdquo; weights in the Boltzmann simulation.</li>
<li><strong>Thresholds</strong>: Sememe units have variable thresholds dynamically adjusted to be slightly less than the number of active word-set units.</li>
</ul>
<h3 id="evaluation">Evaluation</h3>
<p>The simulation evaluated the robustness of the mapping.</p>
<table>
	<thead>
			<tr>
					<th>Metric</th>
					<th>Value</th>
					<th>Baseline</th>
					<th>Notes</th>
			</tr>
	</thead>
	<tbody>
			<tr>
					<td><strong>Accuracy (Clean)</strong></td>
					<td>99.9%</td>
					<td>N/A</td>
					<td>Correct pattern produced 99.9% of the time after learning.</td>
			</tr>
			<tr>
					<td><strong>Lesion Error Rate</strong></td>
					<td>1.4%</td>
					<td>N/A</td>
					<td>140 errors in 10,000 tests after removing 1 word-set unit.</td>
			</tr>
			<tr>
					<td><strong>Semantic Errors</strong></td>
					<td>~60% of errors</td>
					<td>N/A</td>
					<td>83 of the 140 lesion errors were &ldquo;Deep Dyslexia&rdquo; errors (producing a valid but wrong semantic pattern).</td>
			</tr>
			<tr>
					<td><strong>Post-Noise Accuracy</strong></td>
					<td>64.3%</td>
					<td>99.3%</td>
					<td>Performance after adding noise to all connections involving word-set units. The 99.3% baseline (reported separately from the 99.9% clean accuracy above) reflects the pre-noise measurement at the time of this specific experiment.</td>
			</tr>
	</tbody>
</table>
<h3 id="hardware">Hardware</h3>
<ul>
<li><strong>Compute</strong>: Minimal. The original simulation ran on 1980s hardware (likely VAX-11 or similar).</li>
<li><strong>Replication</strong>: Reproducible on any modern CPU in milliseconds.</li>
</ul>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Hinton, G. E. (1984). Distributed Representations. <em>Technical Report CMU-CS-84-157</em>, Carnegie-Mellon University.</p>
<p><strong>Publication</strong>: CMU Computer Science Department Technical Report, October 1984</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@techreport</span>{hinton1984distributed,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Distributed representations}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Hinton, Geoffrey E}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{1984}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">institution</span>=<span style="color:#e6db74">{Carnegie-Mellon University}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span>=<span style="color:#e6db74">{CMU-CS-84-157}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>The Number of Isomeric Hydrocarbons of the Methane Series</title><link>https://hunterheidenreich.com/notes/chemistry/molecular-representations/notations/number-of-isomeric-hydrocarbons/</link><pubDate>Mon, 08 Sep 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/chemistry/molecular-representations/notations/number-of-isomeric-hydrocarbons/</guid><description>Henze and Blair's 1931 JACS paper deriving exact recursive formulas for counting constitutional alkane isomers.</description><content:encoded><![CDATA[<h2 id="a-theoretical-foundation-for-mathematical-chemistry">A Theoretical Foundation for Mathematical Chemistry</h2>
<p>This is a foundational <strong>theoretical paper</strong> in mathematical chemistry and chemical graph theory. It derives <strong>exact mathematical laws</strong> governing molecular topology. The paper also serves as a <strong>benchmark resource</strong>, establishing the first systematic isomer counts that corrected historical errors and whose recursive method remains the basis for modern molecular enumeration.</p>
<h2 id="historical-motivation-and-the-failure-of-centric-trees">Historical Motivation and the Failure of Centric Trees</h2>
<p>The primary motivation was the lack of a rigorous mathematical relationship between carbon content ($N$) and isomer count.</p>
<ul>
<li><strong>Previous failures, reached by two different routes</strong>: <a href="https://doi.org/10.1002/cber.187500801227">Cayley (1875)</a> (as cited by Henze and Blair, referring to the Berichte der deutschen chemischen Gesellschaft summary) built &ldquo;centric&rdquo; and &ldquo;bicentric&rdquo; trees and predicted counts through $C_{13}$, erring at $C_{12}$ and $C_{13}$. <a href="https://doi.org/10.1002/cber.187500802191">Schiff (1875)</a>, almost simultaneously, used combinations and permutations rather than trees, reached the dodecanes, and arrived at Cayley&rsquo;s same wrong value there. Both errors were first corrected by Hermann around 1880, who typed the isomers by the number of branches on the fundamental chain; his method reaches $C_{13}$ and no further. Tiemann (1893), Delannoy (1894), Losanitsch (1897), Goldberg (1898), Trautz (1924), and David (1928) followed, as cited in the paper, none achieving general accuracy: Losanitsch&rsquo;s $C_{12}$ and $C_{14}$ totals are wrong, and Goldberg&rsquo;s formula fails above $C_{10}$.</li>
<li><strong>The theoretical gap, which has two independent causes</strong>: a formula anchored on a &ldquo;centric&rdquo; or &ldquo;bicentric&rdquo; center of symmetry fails once the carbon content is large enough to introduce additional centers of symmetry. Separately, a formula requiring one more term per unit increase in carbon content (Delannoy, and David after him) fails past the point where those terms have been established. The paper names these as alternatives; neither implies the other, and both put counts for larger molecules like $C_{40}$ out of reach.</li>
</ul>
<p>This work aimed to develop a theoretically sound, generalizable method that could be extended to any number of carbons.</p>
<h2 id="core-innovation-recursive-enumeration-of-graphs">Core Innovation: Recursive Enumeration of Graphs</h2>
<p>The core novelty is the proof that the count of hydrocarbons is a recursive function of the count of alkyl radicals (alcohols) of size $N/2$ or smaller. The authors rely on a preliminary calculation of the total number of isomeric alcohols (the methanol series) to make this hydrocarbon enumeration possible. By defining $T_k$ as the exact number of possible isomeric alkyl radicals strictly containing $k$ carbon atoms, graph enumeration transforms into a mathematical recurrence.</p>
<p>To prevent double-counting when several branches of the same carbon content attach to a central carbon, Henze and Blair applied combinations with repetition. Same carbon content does not mean same structure: there are $T_k$ structurally distinct radicals at size $k$, and it is precisely because branches of equal size may differ that a plain product would miscount. Because the branches are topologically unordered, connecting $x$ of them at size $k$ gives:</p>
<p>$$ \binom{T_k + x - 1}{x} $$</p>
<p>For example, if a Group B central carbon is bonded to three identical sub-branches of length $k$, the combinatoric volume for that precise topological partition resolves to:</p>
<p>$$ \frac{T_k (T_k + 1)(T_k + 2)}{6} $$</p>
<p>Summing these constrained combinatorial partitions across all valid branch sizes (governed by the Even/Odd bisection rules) yields the exact isomer count for $N$ without overestimating due to symmetric permutations.</p>
<p><strong>The Symmetry Constraints</strong>: The paper rigorously divides the problem space to prevent double-counting:</p>
<ul>
<li><strong>Group A (Centrosymmetric)</strong>: Hydrocarbons that can be bisected into two smaller alkyl radicals.
<ul>
<li><em>Even $N$</em>: Split into two radicals of size $N/2$.</li>
<li><em>Odd $N$</em>: Split into sizes $(N+1)/2$ and $(N-1)/2$.</li>
</ul>
</li>
<li><strong>Group B (Asymmetric)</strong>: Hydrocarbons whose graphic formula cannot be symmetrically bisected. They contain exactly one central carbon atom attached to 3 or 4 branches. To prevent double-counting, Henze and Blair established strict maximum branch sizes:
<ul>
<li><em>Even $N$</em>: No branch can be larger than $(N/2 - 1)$ carbons.</li>
<li><em>Odd $N$</em>: No branch can be larger than $(N-3)/2$ carbons.</li>
<li><em>The Combinatorial Partitioning</em>: They further subdivided these into three cases for the 3-branch type (a) and five for the 4-branch type (b), each with its own closed-form expression. The axis is carbon content, not structure: type (a) splits into all three branches of different content, two equal and one different, and all three equal; type (b) adds four-equal and two-plus-two. Cases (b4) and (b5) are possible only at odd $N$, since they require $(N-1)$ to be divisible by four and by two respectively, and Table I carries no b4 or b5 rows at all in its even-carbon half.</li>
</ul>
</li>
</ul>















<figure class="post-figure center ">
    <img src="/img/notes/hexane-and-its-five-isomers-by-even-and-odd-decomposition.webp"
         alt="The five structural isomers of hexane classified into Group A and Group B based on their decomposition"
         title="The five structural isomers of hexane classified into Group A and Group B based on their decomposition"
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption">The five isomers of hexane ($C_6$) classified by Henze and Blair&rsquo;s symmetry scheme. Group A molecules (top row) can be bisected along a bond (highlighted in red) into two $C_3$ alkyl radicals. Group B molecules (bottom row) have a central carbon atom (red circle) with 3-4 branches, preventing symmetric bisection.</figcaption>
    
</figure>

<p>This classification is the key insight that enables the recursive formulas. By exhaustively partitioning hydrocarbons into these mutually exclusive groups, the authors could derive separate combinatorial expressions for each and sum them without double-counting.</p>
<p>For each structural class, combinatorial formulas are derived that depend on the number of isomeric alcohols ($T_k$) where $k &lt; N$. This transforms the problem of counting large molecular graphs into a recurrence relation based on the counts of smaller, simpler sub-graphs.</p>
<h2 id="two-hand-enumerations-the-fitting-set-and-the-held-out-check">Two Hand-Enumerations: The Fitting Set and the Held-Out Check</h2>
<p>The paper contains two separate hand-enumerations, and they play opposite roles.</p>
<ol>
<li><strong>The fitting set, $C_4$ through $C_{10}$</strong>: in the paper&rsquo;s own words, &ldquo;the data utilized in deriving these recursion formulas were the totals of the isomers of the series $\mathrm{C_4H_{10}}$ to $\mathrm{C_{10}H_{22}}$ inclusive as obtained by actual writing of their structural formulas.&rdquo; Seven hand-counted totals are what the recursion was built against.</li>
<li><strong>The held-out set, $C_{11}$ through $C_{14}$</strong>: because the calculated tridecane and tetradecane totals &ldquo;differed from the totals previously accepted in the literature, it seemed desirable also to write and count all the structural formulas &hellip; of the undecanes, dodecanes, tridecanes and tetradecanes.&rdquo; The enumeration was run because the formulas contradicted the incumbent numbers, and it came back agreeing with the formulas: &ldquo;The numbers so obtained agree exactly with the totals as calculated.&rdquo;
<ul>
<li><em>Key correction</em>: the count for tetradecane ($C_{14}$) is <strong>1,858</strong>, against erroneous values previously published by <a href="https://doi.org/10.1002/cber.189703002144" title="Die Isomerie-Arten bei den Homologen der Paraffin-Reihe">Losanitsch (1897)</a>, whose results for $C_{12}$ and $C_{14}$ the paper identifies as incorrect.</li>
</ul>
</li>
<li><strong>Extrapolation to $N = 40$</strong>, reaching over $6.2 \times 10^{13}$ isomers, far beyond anything previously computed and four times past the largest hand-verified point.</li>
</ol>
<p>Read as an experiment, this is a seven-point fit with a four-point held-out test, and the test was triggered by the formulas disagreeing with the accepted answer rather than by a pre-registered protocol. That is a stronger validation than it first looks in one respect, since the held-out counts were produced by a method entirely unlike the formulas, and a weaker one in another, since nothing beyond $C_{14}$ was ever checked by hand.</p>
<p><strong>Table I</strong> is the paper&rsquo;s other tabulated result. It reports how many terms each of the eight cases contributes at every carbon content through $C_{40}$, growing from 1 term at $C_3$ to 274 at $C_{40}$. Its practical use is as the work estimate for a hand calculation, and its structural use is the odd-only behavior of cases (b4) and (b5) noted above.</p>
<h2 id="benchmark-outcomes-and-scaling-limits">Benchmark Outcomes and Scaling Limits</h2>
<ul>
<li><strong>The Constitutional Limit</strong>: The paper establishes the mathematical ground truth for organic molecular graphs by strictly counting <em>constitutional</em> (structural) isomers. The derivation completely excludes 3D stereoisomerism (enantiomers and diastereomers). For modern geometric deep learning applications (e.g., generating 3D conformers), Henze and Blair&rsquo;s scaling sequence serves as a lower bound, representing a severe underestimation of the true number of spatial configurations feasible within chemical space.</li>
<li><strong>Theoretical outcome</strong>: The paper proves that the problem&rsquo;s inherent complexity requires a recursive approach.</li>
<li><strong>Benchmark resource, with the verified range bounded</strong>: Table II publishes counts up to $C_{40}$, correcting historical errors and establishing the first systematic tabulation across this range. The hand-verified range ends at $C_{14}$; everything above it is the recursion carried forward by hand arithmetic, and the published $C_{40}$ is wrong. The recursive method itself is exact and remains the basis for the accepted values in <a href="https://oeis.org/A000602">OEIS A000602</a>, which is why an independent implementation of it (below) reproduces 1,858 at $C_{14}$ and disagrees with the paper only where the hand arithmetic ran long.</li>
</ul>















<figure class="post-figure center ">
    <img src="/img/notes/number-of-isomeric-hydrocarbons-of-the-methane-series.webp"
         alt="Log-scale plot showing exponential growth of alkane isomer counts from C1 to C40"
         title="Log-scale plot showing exponential growth of alkane isomer counts from C1 to C40"
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption">The number of structural isomers grows super-exponentially with carbon content, reaching over 62 trillion for C₄₀. This plot, derived from Henze and Blair&rsquo;s Table II, illustrates the combinatorial explosion that makes direct enumeration intractable for larger molecules.</figcaption>
    
</figure>

<p>The plot above illustrates the growth rate, and the Table II figures behind it are worth stating exactly. Methane ($C_1$) through propane ($C_3$) each have exactly one isomer, then the count accelerates: 2 at $C_4$, 75 at $C_{10}$, 1,858 at $C_{14}$, 366,319 at $C_{20}$, 36,797,588 at $C_{25}$, 4,111,846,763 at $C_{30}$, and 62,491,178,805,831 at $C_{40}$. The modern OEIS-verified value at $C_{40}$ is 62,481,801,147,341, so the paper&rsquo;s figure is high by 9,377,658,490, about 0.015%. The recursion is exact; what drifts is thirteen digits of hand arithmetic. This super-exponential scaling is why brute-force enumeration stops being an option and why the recurrence was necessary.</p>
<ul>
<li><strong>Foundational impact</strong>: This work established the mathematical framework that would later evolve into modern chemical graph theory and computational chemistry approaches for molecular enumeration. In the context of AI for molecular generation, this is an early form of <strong>expressivity analysis</strong>, defining the size of the chemical space that generative models must learn to cover.</li>
</ul>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<ul>
<li>
<p><strong>Algorithms</strong>: The exact mathematical recursive formulas and combinatorial partitioning logic are fully provided in the text, allowing for programmatic implementation.</p>
</li>
<li>
<p><strong>Evaluation</strong>: hand-enumeration of structural formulas, used twice and for opposite purposes. $C_4$ to $C_{10}$ is the data the recursion was derived from; $C_{11}$ to $C_{14}$ is the held-out check, run after the formulas disagreed with the accepted literature totals, and it agreed exactly with them. Nothing above $C_{14}$ was ever hand-verified.</p>
</li>
<li>
<p><strong>Data</strong>: Table I gives the number of terms contributed by each of the eight cases at every carbon content through $C_{40}$ (1 term at $C_3$, 274 at $C_{40}$). Table II gives the isomer counts themselves through $C_{40}$. The counts are exact through $C_{14}$ and accumulate arithmetic error beyond it. The corrected integer sequence is maintained in the On-Line Encyclopedia of Integer Sequences (OEIS) as <a href="https://oeis.org/A000602">A000602</a>.</p>
</li>
<li>
<p><strong>Code</strong>: The OEIS page provides Mathematica and Maple implementations. The following pure Python implementation uses the OEIS generating functions (which formalize Henze and Blair&rsquo;s recursive method) to compute the corrected isomer counts up to any arbitrary $N$:</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-python" data-lang="python"><span style="display:flex;"><span><span style="color:#66d9ef">def</span> <span style="color:#a6e22e">compute_alkane_isomers</span>(max_n: int) <span style="color:#f92672">-&gt;</span> list[int]:
</span></span><span style="display:flex;"><span>    <span style="color:#e6db74">&#34;&#34;&#34;
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">    Computes the number of alkane structural isomers C_nH_{2n+2}
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">    up to max_n using the generating functions from OEIS A000602.
</span></span></span><span style="display:flex;"><span><span style="color:#e6db74">    &#34;&#34;&#34;</span>
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">if</span> max_n <span style="color:#f92672">==</span> <span style="color:#ae81ff">0</span>: <span style="color:#66d9ef">return</span> [<span style="color:#ae81ff">1</span>]
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    <span style="color:#75715e"># Helper: multiply two polynomials (cap at degree max_n)</span>
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">def</span> <span style="color:#a6e22e">poly_mul</span>(a: list[int], b: list[int]) <span style="color:#f92672">-&gt;</span> list[int]:
</span></span><span style="display:flex;"><span>        res <span style="color:#f92672">=</span> [<span style="color:#ae81ff">0</span>] <span style="color:#f92672">*</span> (max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>)
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">for</span> i, v_a <span style="color:#f92672">in</span> enumerate(a):
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">for</span> j, v_b <span style="color:#f92672">in</span> enumerate(b):
</span></span><span style="display:flex;"><span>                <span style="color:#66d9ef">if</span> i <span style="color:#f92672">+</span> j <span style="color:#f92672">&lt;=</span> max_n: res[i <span style="color:#f92672">+</span> j] <span style="color:#f92672">+=</span> v_a <span style="color:#f92672">*</span> v_b
</span></span><span style="display:flex;"><span>                <span style="color:#66d9ef">else</span>: <span style="color:#66d9ef">break</span>
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">return</span> res
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    <span style="color:#75715e"># Helper: evaluate P(x^k) by spacing out terms</span>
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">def</span> <span style="color:#a6e22e">poly_pow</span>(a: list[int], k: int) <span style="color:#f92672">-&gt;</span> list[int]:
</span></span><span style="display:flex;"><span>        res <span style="color:#f92672">=</span> [<span style="color:#ae81ff">0</span>] <span style="color:#f92672">*</span> (max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>)
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">for</span> i, v <span style="color:#f92672">in</span> enumerate(a):
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">if</span> i <span style="color:#f92672">*</span> k <span style="color:#f92672">&lt;=</span> max_n: res[i <span style="color:#f92672">*</span> k] <span style="color:#f92672">=</span> v
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">else</span>: <span style="color:#66d9ef">break</span>
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">return</span> res
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    <span style="color:#75715e"># T represents the alkyl radicals (OEIS A000598), T[0] = 1</span>
</span></span><span style="display:flex;"><span>    T <span style="color:#f92672">=</span> [<span style="color:#ae81ff">0</span>] <span style="color:#f92672">*</span> (max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>)
</span></span><span style="display:flex;"><span>    T[<span style="color:#ae81ff">0</span>] <span style="color:#f92672">=</span> <span style="color:#ae81ff">1</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    <span style="color:#75715e"># Iteratively build coefficients of T</span>
</span></span><span style="display:flex;"><span>    <span style="color:#75715e"># We only need to compute the (n-1)-th degree terms at step n</span>
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">for</span> n <span style="color:#f92672">in</span> range(<span style="color:#ae81ff">1</span>, max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>):
</span></span><span style="display:flex;"><span>        <span style="color:#75715e"># Extract previously calculated slices</span>
</span></span><span style="display:flex;"><span>        t_prev <span style="color:#f92672">=</span> T[:n]
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>        <span style="color:#75715e"># T(x^2) and T(x^3) terms up to n-1</span>
</span></span><span style="display:flex;"><span>        t2_term <span style="color:#f92672">=</span> T[(n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span>) <span style="color:#f92672">//</span> <span style="color:#ae81ff">2</span>] <span style="color:#66d9ef">if</span> (n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span>) <span style="color:#f92672">%</span> <span style="color:#ae81ff">2</span> <span style="color:#f92672">==</span> <span style="color:#ae81ff">0</span> <span style="color:#66d9ef">else</span> <span style="color:#ae81ff">0</span>
</span></span><span style="display:flex;"><span>        t3_term <span style="color:#f92672">=</span> T[(n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span>) <span style="color:#f92672">//</span> <span style="color:#ae81ff">3</span>] <span style="color:#66d9ef">if</span> (n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span>) <span style="color:#f92672">%</span> <span style="color:#ae81ff">3</span> <span style="color:#f92672">==</span> <span style="color:#ae81ff">0</span> <span style="color:#66d9ef">else</span> <span style="color:#ae81ff">0</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>        <span style="color:#75715e"># T(x)^2 and T(x)^3 terms up to n-1</span>
</span></span><span style="display:flex;"><span>        t_squared_n_1 <span style="color:#f92672">=</span> sum(t_prev[i] <span style="color:#f92672">*</span> t_prev[n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span> <span style="color:#f92672">-</span> i] <span style="color:#66d9ef">for</span> i <span style="color:#f92672">in</span> range(n))
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>        t_cubed_n_1 <span style="color:#f92672">=</span> sum(
</span></span><span style="display:flex;"><span>            T[i] <span style="color:#f92672">*</span> T[j] <span style="color:#f92672">*</span> T[n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span> <span style="color:#f92672">-</span> i <span style="color:#f92672">-</span> j]
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">for</span> i <span style="color:#f92672">in</span> range(n)
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">for</span> j <span style="color:#f92672">in</span> range(n <span style="color:#f92672">-</span> i)
</span></span><span style="display:flex;"><span>        )
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>        <span style="color:#75715e"># T(x) * T(x^2) term up to n-1</span>
</span></span><span style="display:flex;"><span>        t_t2_n_1 <span style="color:#f92672">=</span> sum(
</span></span><span style="display:flex;"><span>            T[i] <span style="color:#f92672">*</span> T[j]
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">for</span> i <span style="color:#f92672">in</span> range(n)
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">for</span> j <span style="color:#f92672">in</span> range((n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span> <span style="color:#f92672">-</span> i) <span style="color:#f92672">//</span> <span style="color:#ae81ff">2</span> <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>)
</span></span><span style="display:flex;"><span>            <span style="color:#66d9ef">if</span> i <span style="color:#f92672">+</span> <span style="color:#ae81ff">2</span><span style="color:#f92672">*</span>j <span style="color:#f92672">==</span> n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span>
</span></span><span style="display:flex;"><span>        )
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>        T[n] <span style="color:#f92672">=</span> (t_cubed_n_1 <span style="color:#f92672">+</span> <span style="color:#ae81ff">3</span> <span style="color:#f92672">*</span> t_t2_n_1 <span style="color:#f92672">+</span> <span style="color:#ae81ff">2</span> <span style="color:#f92672">*</span> t3_term) <span style="color:#f92672">//</span> <span style="color:#ae81ff">6</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    <span style="color:#75715e"># Calculate Alkanes (OEIS A000602) from fully populated T</span>
</span></span><span style="display:flex;"><span>    T2 <span style="color:#f92672">=</span> poly_pow(T, <span style="color:#ae81ff">2</span>)
</span></span><span style="display:flex;"><span>    T3 <span style="color:#f92672">=</span> poly_pow(T, <span style="color:#ae81ff">3</span>)
</span></span><span style="display:flex;"><span>    T4 <span style="color:#f92672">=</span> poly_pow(T, <span style="color:#ae81ff">4</span>)
</span></span><span style="display:flex;"><span>    T_squared <span style="color:#f92672">=</span> poly_mul(T, T)
</span></span><span style="display:flex;"><span>    T_cubed <span style="color:#f92672">=</span> poly_mul(T_squared, T)
</span></span><span style="display:flex;"><span>    T_fourth <span style="color:#f92672">=</span> poly_mul(T_cubed, T)
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    term2 <span style="color:#f92672">=</span> [(T_squared[i] <span style="color:#f92672">-</span> T2[i]) <span style="color:#f92672">//</span> <span style="color:#ae81ff">2</span> <span style="color:#66d9ef">for</span> i <span style="color:#f92672">in</span> range(max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>)]
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    term3_inner <span style="color:#f92672">=</span> [
</span></span><span style="display:flex;"><span>        T_fourth[i]
</span></span><span style="display:flex;"><span>        <span style="color:#f92672">+</span> <span style="color:#ae81ff">6</span> <span style="color:#f92672">*</span> poly_mul(T_squared, T2)[i]
</span></span><span style="display:flex;"><span>        <span style="color:#f92672">+</span> <span style="color:#ae81ff">8</span> <span style="color:#f92672">*</span> poly_mul(T, T3)[i]
</span></span><span style="display:flex;"><span>        <span style="color:#f92672">+</span> <span style="color:#ae81ff">3</span> <span style="color:#f92672">*</span> poly_mul(T2, T2)[i]
</span></span><span style="display:flex;"><span>        <span style="color:#f92672">+</span> <span style="color:#ae81ff">6</span> <span style="color:#f92672">*</span> T4[i]
</span></span><span style="display:flex;"><span>        <span style="color:#66d9ef">for</span> i <span style="color:#f92672">in</span> range(max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>)
</span></span><span style="display:flex;"><span>    ]
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    alkanes <span style="color:#f92672">=</span> [<span style="color:#ae81ff">1</span>] <span style="color:#f92672">+</span> [<span style="color:#ae81ff">0</span>] <span style="color:#f92672">*</span> max_n
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">for</span> n <span style="color:#f92672">in</span> range(<span style="color:#ae81ff">1</span>, max_n <span style="color:#f92672">+</span> <span style="color:#ae81ff">1</span>):
</span></span><span style="display:flex;"><span>        alkanes[n] <span style="color:#f92672">=</span> T[n] <span style="color:#f92672">-</span> term2[n] <span style="color:#f92672">+</span> term3_inner[n <span style="color:#f92672">-</span> <span style="color:#ae81ff">1</span>] <span style="color:#f92672">//</span> <span style="color:#ae81ff">24</span>
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span>    <span style="color:#66d9ef">return</span> alkanes
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#75715e"># Calculate and verify</span>
</span></span><span style="display:flex;"><span>isomers <span style="color:#f92672">=</span> compute_alkane_isomers(<span style="color:#ae81ff">40</span>)
</span></span><span style="display:flex;"><span>print(<span style="color:#e6db74">f</span><span style="color:#e6db74">&#34;C_14 isomers: </span><span style="color:#e6db74">{</span>isomers[<span style="color:#ae81ff">14</span>]<span style="color:#e6db74">}</span><span style="color:#e6db74">&#34;</span>)   <span style="color:#75715e"># Output: 1858</span>
</span></span><span style="display:flex;"><span>print(<span style="color:#e6db74">f</span><span style="color:#e6db74">&#34;C_40 isomers: </span><span style="color:#e6db74">{</span>isomers[<span style="color:#ae81ff">40</span>]<span style="color:#e6db74">}</span><span style="color:#e6db74">&#34;</span>)   <span style="color:#75715e"># Output: 62481801147341</span>
</span></span></code></pre></div></li>
<li>
<p><strong>Hardware</strong>: Derived analytically and enumerated manually by the authors in 1931 without computational hardware.</p>
</li>
</ul>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Henze, H. R., &amp; Blair, C. M. (1931). The number of isomeric hydrocarbons of the methane series. <em>Journal of the American Chemical Society</em>, 53(8), 3077-3085. <a href="https://doi.org/10.1021/ja01359a034">https://doi.org/10.1021/ja01359a034</a></p>
<p><strong>Publication</strong>: Journal of the American Chemical Society (JACS) 1931</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{henze1931number,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{The number of isomeric hydrocarbons of the methane series}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Henze, Henry R and Blair, Charles M}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span>=<span style="color:#e6db74">{Journal of the American Chemical Society}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span>=<span style="color:#e6db74">{53}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span>=<span style="color:#e6db74">{8}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span>=<span style="color:#e6db74">{3077--3085}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{1931}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">publisher</span>=<span style="color:#e6db74">{ACS Publications}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Communication in the Presence of Noise: Shannon's 1949 Paper</title><link>https://hunterheidenreich.com/notes/machine-learning/model-architectures/communication-in-the-presence-of-noise/</link><pubDate>Mon, 08 Sep 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/machine-learning/model-architectures/communication-in-the-presence-of-noise/</guid><description>Shannon's 1949 foundational paper establishing information theory, channel capacity, and the sampling theorem for communication systems.</description><content:encoded><![CDATA[<h2 id="what-kind-of-paper-is-this">What kind of paper is this?</h2>
<p>This is a foundational <strong>Theory</strong> paper. It establishes the mathematical framework for modern information theory and defines the ultimate physical limits of communication for an entire system, from the information source to the final destination.</p>
<h2 id="what-is-the-motivation">What is the motivation?</h2>
<p>The central motivation was to develop a general theory of communication that could quantify information and determine the maximum rate at which it can be transmitted reliably over a noisy channel. Prior to this work, communication system design was largely empirical. Shannon sought to create a mathematical foundation to understand the trade-offs between key parameters like bandwidth, power, and noise, independent of any specific hardware or modulation scheme. To frame this, he conceptualized a general communication system as consisting of five essential elements: an information source, a transmitter, a channel, a receiver, and a destination.</p>
<h2 id="what-is-the-novelty-here">What is the novelty here?</h2>
<p>The novelty is a complete, end-to-end mathematical theory of communication built upon several key concepts and theorems:</p>
<ol>
<li><strong>Geometric Representation of Signals</strong>: Shannon introduced the idea of representing signals as points in a high-dimensional vector space. A signal of duration $T$ and bandwidth $W$ is uniquely specified by $2TW$ numbers (its samples), which are treated as coordinates in a $2TW$-dimensional space. This transformed problems in communication into problems of high-dimensional geometry. In this representation, signal energy corresponds to squared distance from the origin, and noise introduces a &ldquo;sphere of uncertainty&rdquo; around each transmitted point.</li>
</ol>















<figure class="post-figure center ">
    <img src="/img/notes/geometric-interpretation-of-signals-as-spheres.webp"
         alt="Sphere packing illustration showing the geometric interpretation of channel capacity. A large dashed circle represents the total signal space with radius proportional to the square root of P&#43;N. Inside are multiple smaller blue circles (uncertainty spheres) with radius proportional to the square root of N, each centered on a distinct message point."
         title="Sphere packing illustration showing the geometric interpretation of channel capacity. A large dashed circle represents the total signal space with radius proportional to the square root of P&#43;N. Inside are multiple smaller blue circles (uncertainty spheres) with radius proportional to the square root of N, each centered on a distinct message point."
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption"><strong>Sphere Packing and Channel Capacity</strong>: Each transmitted message corresponds to a point in high-dimensional signal space. Noise creates an &lsquo;uncertainty sphere&rsquo; of radius $\sqrt{N}$ around each point. The channel capacity equals how many non-overlapping uncertainty spheres can be packed into the total signal sphere of radius $\sqrt{P+N}$.</figcaption>
    
</figure>

<ol start="2">
<li>
<p><strong>Theorem 1 (The Sampling Theorem)</strong>: The paper provides an explicit statement and proof that a signal containing no frequencies higher than $W$ is perfectly determined by its samples taken at a rate of $2W$ samples per second (i.e., spaced $1/2W$ seconds apart). Shannon credits Nyquist for pointing out the fundamental importance of the time interval $1/2W$ seconds in connection with telegraphy, and names this the &ldquo;Nyquist interval&rdquo; corresponding to the band $W$. This theorem is the theoretical bedrock of all modern digital signal processing.</p>
</li>
<li>
<p><strong>Theorem 2 (Channel Capacity for AWGN)</strong>: This is the paper&rsquo;s most celebrated result, now known as the <strong>Shannon-Hartley theorem</strong> (a name assigned retrospectively, not used in the paper itself). It provides an exact formula for the capacity $C$ (the maximum rate of error-free communication) of a channel with bandwidth $W$, signal power $P$, and additive white Gaussian noise of power $N$:
$$ C = W \log_2 \left(1 + \frac{P}{N}\right) $$
It proves that for any transmission rate below $C$, a coding scheme exists that can achieve an arbitrarily low error frequency.</p>
<p><strong>Random Coding Proof Technique</strong>: Shannon&rsquo;s proof employs a <strong>random coding argument</strong>: he proved that if you choose signal points at random from the sphere of radius $\sqrt{2TWP}$, the average error frequency vanishes for any transmission rate below capacity. This non-constructive proof (meaning it establishes that good codes must exist without constructing any specific one) established that &ldquo;good&rdquo; codes exist almost everywhere in the signal space, even if we don&rsquo;t know how to build them efficiently. The random coding argument became a fundamental tool in information theory, shifting the focus from building specific codes to proving existence and understanding fundamental limits.</p>
</li>
</ol>















<figure class="post-figure center ">
    <img src="/img/notes/shannons-ideal-capacity-curve-and-sampling-theorem.webp"
         alt="Two plots illustrating Shannon&#39;s key theorems: (Left) The ideal capacity curve showing bits per cycle vs SNR in dB, with an example operating point at 10dB. (Right) The sampling theorem demonstrating how a continuous signal is perfectly captured by samples taken at the Nyquist rate of 2W."
         title="Two plots illustrating Shannon&#39;s key theorems: (Left) The ideal capacity curve showing bits per cycle vs SNR in dB, with an example operating point at 10dB. (Right) The sampling theorem demonstrating how a continuous signal is perfectly captured by samples taken at the Nyquist rate of 2W."
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption"><strong>Left</strong>: Shannon&rsquo;s ideal capacity curve, showing how channel capacity (in bits per cycle) increases logarithmically with signal-to-noise ratio. <strong>Right</strong>: The sampling theorem in action, where a band-limited continuous signal is fully determined by discrete samples taken at twice its maximum frequency.</figcaption>
    
</figure>

<ol start="4">
<li>
<p><strong>Theorem 3 (Channel Capacity for Arbitrary Noise)</strong>: Shannon generalized the capacity concept to channels with any type of noise. Entropy power is defined as $N_1 = \frac{1}{2\pi e} e^{2h(X)}$, where $h(X)$ is the differential entropy of the noise distribution (the continuous analog of discrete entropy $H$: where $H$ counts the average bits per symbol from a discrete source, $h(X)$ measures the same unpredictability for continuous-valued random variables); it quantifies how spread out a distribution is in an information-theoretic sense, with Gaussian noise having the highest entropy power for a given variance. He showed that the capacity for a channel with arbitrary noise of power $N$ is bounded by the noise&rsquo;s <strong>entropy power</strong> $N_1$. Shannon proved that <strong>white Gaussian noise is the worst possible type of noise</strong> for any given noise power. Because the Gaussian distribution maximizes entropy for a given variance, the entropy power $N_1$ of any noise with power $N$ satisfies $N_1 \leq N$, with equality only for the Gaussian case. Since channel capacity decreases as entropy power increases, Gaussian noise achieves the highest $N_1$ (equal to $N$) and therefore imposes the lowest capacity bound. This means a system designed to handle white Gaussian noise will perform at least as well against any other noise type of the same power.</p>
<p><strong>Arbitrary Gaussian Noise and the Water-Filling Principle</strong>: Shannon extended his analysis to Gaussian noise with a non-flat power spectrum $N(f)$, using the calculus of variations (a technique for optimizing over functions rather than fixed variables) to find the power allocation $P(f)$ that maximizes capacity. He proved that optimal capacity is achieved when the sum $P(f) + N(f)$ is constant across the utilized frequency band. This leads to what is now known as the &ldquo;water-filling&rdquo; principle: allocate more signal power to quieter frequency bands, and allocate zero power to any band where noise exceeds the constant threshold. This provides the foundation for modern adaptive power allocation across frequency bands.</p>
</li>
</ol>















<figure class="post-figure center ">
    <img src="/img/notes/the-water-filling-principle.webp"
         alt="The water-filling principle for optimal power allocation. Gray area shows noise power N(f) varying across frequencies, orange area shows signal power P(f) allocated to fill up to a constant level lambda, such that P(f) &#43; N(f) equals a constant."
         title="The water-filling principle for optimal power allocation. Gray area shows noise power N(f) varying across frequencies, orange area shows signal power P(f) allocated to fill up to a constant level lambda, such that P(f) &#43; N(f) equals a constant."
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption"><strong>The Water-Filling Principle</strong>: The condition $P(f) + N(f) = \lambda$ is Shannon&rsquo;s derivation; &lsquo;water-filling&rsquo; is the modern retrospective label for it. When noise power varies across frequencies, optimal capacity is achieved by allocating more signal power to &lsquo;quieter&rsquo; frequency bands. Like filling a container with water, power is poured in until the total (signal + noise) reaches a constant level $\lambda$. Frequencies with noise above this threshold receive no power at all.</figcaption>
    
</figure>

<ol start="5">
<li>
<p><strong>Theorem 4 (now known as the Source Coding Theorem)</strong>: This theorem addresses the information source itself. It proves that it&rsquo;s possible to encode messages from a discrete source into binary digits such that the average number of bits per source symbol approaches the source&rsquo;s <strong>entropy</strong>, $H$. This establishes entropy as the fundamental limit of data compression.</p>
</li>
<li>
<p><strong>Theorem 5 (Information Rate for Continuous Sources)</strong>: For continuous (analog) signals, Shannon introduced a concept foundational to rate-distortion theory. He defined the rate $R$ at which a continuous source generates information relative to a specific fidelity criterion (i.e., a tolerable amount of error, $N_1$, in the reproduction). This provides an early theoretical foundation for what later became rate-distortion theory.</p>
</li>
</ol>
<h2 id="what-experiments-were-performed">What experiments were performed?</h2>
<p>The paper is primarily theoretical, with &ldquo;experiments&rdquo; consisting of rigorous <strong>mathematical derivations and proofs</strong>. The channel capacity theorem, for instance, is proven using a geometric sphere-packing argument in the high-dimensional signal space.</p>
<p>However, Shannon does include a quantitative <strong>theoretical benchmark against existing 1949 technology</strong>. He plots his theoretical &ldquo;Ideal Curve&rdquo; against calculated limits of Pulse Code Modulation (PCM) and Pulse Position Modulation (PPM) systems in Figure 6. The PCM points were calculated from formulas in another paper, and the PPM points were from unpublished calculations by B. McMillan. This comparison reveals that the entire series of plotted points for these contemporary systems operated approximately <strong>8 dB</strong> below the ideal power limit over most of the practical range. Interestingly, PPM systems approached to within <strong>3 dB</strong> of the ideal curve specifically at very small $P/N$ ratios, highlighting that different modulation schemes are optimal for different regimes (PCM for high SNR, PPM for power-limited scenarios).</p>
<h2 id="what-outcomesconclusions">What outcomes/conclusions?</h2>
<p>The primary outcome was a complete, unified theory that quantifies both information itself (entropy) and the ability of a channel to transmit it (capacity).</p>
<ul>
<li>
<p><strong>Decoupling of Source and Channel</strong>: A key conclusion is that the problem of communication can be split into two distinct parts: encoding sequences of message symbols into sequences of binary digits (where the average digits per symbol approaches the entropy $H$), and then mapping these binary digits into a particular signal function of long duration to combat noise. A source can be transmitted reliably if and only if its rate $R$ (or entropy $H$) is less than the channel capacity $C$.</p>
</li>
<li>
<p><strong>The Limit is on Rate</strong>: A central conclusion is that noise in a channel imposes a maximum <strong>rate</strong> of transmission. Below this rate, error-free communication is theoretically possible.</p>
</li>
<li>
<p><strong>The Threshold Effect and Topological Necessity</strong>: To approach capacity, one must map a lower-dimensional message space into the high-dimensional signal space efficiently, winding through the available signal sphere to fill its volume (as illustrated with the efficient mapping in Fig. 4 of the paper). This complex mapping creates a sharp <strong>threshold effect</strong>: below a certain noise level, recovery is essentially perfect; above it, the system fails catastrophically because the &ldquo;uncertainty spheres&rdquo; around signal points begin to overlap. Shannon provides a topological explanation for why this threshold is unavoidable: it is not possible to map a region of higher dimensionality into a region of lower dimensionality continuously. To compress bandwidth (reducing the number of dimensions in signal space), the mapping from message space to signal space must necessarily be discontinuous. This required discontinuity creates vulnerable points where a small noise perturbation can cause the received signal to &ldquo;jump&rdquo; to an entirely different interpretation. The threshold is an inevitable consequence of dimensional reduction.</p>
</li>
<li>
<p><strong>The Exchange Relation</strong>: Shannon explicitly states that the key parameters $T$ (time), $W$ (bandwidth), $P$ (power), and $N$ (noise) can be &ldquo;altered at will&rdquo; without changing the total information transmitted, provided $TW \log(1 + P/N)$ is held constant. This exchangeability enables trade-offs such as using more bandwidth to compensate for lower power.</p>
</li>
<li>
<p><strong>Characteristics of an Ideal System</strong>: The theory implies that to approach the channel capacity limit, one must use very complex and long codes. An ideal system exhibits five key properties: (1) the transmission rate approaches $C$, (2) the error probability approaches zero, (3) the transmitted signal&rsquo;s statistical properties approach those of white noise, (4) the threshold effect becomes very sharp (errors increase rapidly if noise exceeds the designed value), and (5) <strong>the required delay increases indefinitely</strong>. This final constraint is a crucial practical limitation: achieving near-capacity performance requires encoding over increasingly long message blocks, introducing latency that may be unacceptable for real-time applications.</p>
</li>
</ul>
<h2 id="reproducibility-details">Reproducibility Details</h2>
<h3 id="algorithms">Algorithms</h3>
<p>The paper introduces the theoretical foundation for the <strong>water-filling algorithm</strong> for optimal power allocation across frequency bands with varying noise levels. The mathematical condition derived is that $P(f) + N(f)$ must be constant across the utilized frequency band.</p>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Shannon, C. E. (1949). Communication in the Presence of Noise. <em>Proceedings of the IRE</em>, 37(1), 10-21. <a href="https://doi.org/10.1109/JRPROC.1949.232969">https://doi.org/10.1109/JRPROC.1949.232969</a></p>
<p><strong>Publication</strong>: Proceedings of the IRE, 1949</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{shannon1949communication,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Shannon, C. E.}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span>=<span style="color:#e6db74">{Proceedings of the IRE}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Communication in the Presence of Noise}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{1949}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span>=<span style="color:#e6db74">{37}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">number</span>=<span style="color:#e6db74">{1}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span>=<span style="color:#e6db74">{10-21}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">doi</span>=<span style="color:#e6db74">{10.1109/JRPROC.1949.232969}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item><item><title>Lennard-Jones on Adsorption and Diffusion on Surfaces</title><link>https://hunterheidenreich.com/notes/chemistry/molecular-simulation/classical-methods/processes-of-adsorption/</link><pubDate>Sun, 17 Aug 2025 00:00:00 +0000</pubDate><guid>https://hunterheidenreich.com/notes/chemistry/molecular-simulation/classical-methods/processes-of-adsorption/</guid><description>Lennard-Jones's 1932 foundational paper introducing potential energy surface models to unify physical and chemical adsorption.</description><content:encoded><![CDATA[<h2 id="the-theoretical-foundation-of-adsorption-and-diffusion">The Theoretical Foundation of Adsorption and Diffusion</h2>
<p>This paper represents a foundational <strong>Theory</strong> contribution with dual elements of <strong>Systematization</strong>. It derives physical laws for adsorption potentials (Section 2) and diffusion kinetics (Section 4) from first principles, validating them against external experimental data (Ward, Benton). It bridges <strong>electronic structure theory</strong> (potential curves) and <strong>statistical mechanics</strong> (diffusion rates). It provides a unifying theoretical framework to explain a range of experimental observations.</p>
<h2 id="reconciling-physisorption-and-chemisorption">Reconciling Physisorption and Chemisorption</h2>
<p>The primary motivation was to reconcile conflicting experimental evidence regarding the nature of gas-solid interactions. At the time, it was observed that the same gas and solid could interact weakly at low temperatures (consistent with van der Waals forces) but exhibit strong, chemical-like bonding at higher temperatures, a process requiring significant activation energy. The paper seeks to provide a single, coherent model that can explain both &ldquo;physical adsorption&rdquo; (physisorption) and &ldquo;activated&rdquo; or &ldquo;chemical adsorption&rdquo; (chemisorption) and the transition between them.</p>
<h2 id="quantum-mechanical-potential-energy-surfaces-for-adsorption">Quantum Mechanical Potential Energy Surfaces for Adsorption</h2>
<p>The core novelty is the application of quantum mechanical potential energy surfaces to the problem of surface adsorption. The key conceptual breakthroughs are:</p>
<ol>
<li>
<p><strong>Dual Potential Energy Curves</strong>: The paper proposes that the state of the system must be described by at least two distinct potential energy curves as a function of the distance from the surface:</p>
<ul>
<li>One curve represents the interaction of the intact molecule with the surface (e.g., H₂ with a metal). This corresponds to weak, long-range van der Waals forces.</li>
<li>A second curve represents the interaction of the dissociated constituent atoms with the surface (e.g., 2H atoms with the metal). This corresponds to strong, short-range chemical bonds.</li>
</ul>
</li>
<li>
<p><strong>Activated Adsorption via Curve Crossing</strong>: The transition from the molecular (physisorbed) state to the atomic (chemisorbed) state occurs at the intersection of these two potential energy curves. For a molecule to dissociate and chemisorb, it must possess sufficient energy to reach this crossing point. This energy is identified as the <strong>energy of activation</strong>, which had been observed experimentally.</p>
</li>
<li>
<p><strong>Unified Model</strong>: This model unifies physisorption and chemisorption into a single continuous process. A molecule approaching the surface is first trapped in the shallow potential well of the physisorption curve. If it acquires enough thermal energy to overcome the activation barrier, it can transition to the much deeper potential well of the chemisorption state. This provides a clear physical picture for temperature-dependent adsorption phenomena.</p>
</li>
<li>
<p><strong>Quantum Mechanical Basis for Cohesion</strong>: To explain the nature of the chemisorption bond itself, Lennard-Jones draws on the then-recent quantum theory of metals (Sommerfeld, Bloch). In a metal, electrons are not bound to individual atoms but instead occupy shared energy states (bands) spread across the crystal. When an atom approaches the surface, local energy levels form in the gap between the bulk bands, creating sites where bonding can occur. The adsorption bond arises from the interaction between the valency electron of the approaching atom and conduction electrons of the metal, forming a closed shell analogous to a homopolar bond.</p>
</li>
</ol>
<h2 id="validating-theory-against-experimental-gas-solid-interactions">Validating Theory Against Experimental Gas-Solid Interactions</h2>
<p>This is a theoretical paper with no original experiments performed by the author. However, Lennard-Jones validates his theoretical framework against existing experimental data from other researchers:</p>
<ul>
<li><strong>Ward&rsquo;s data</strong>: Hydrogen absorption on copper, used to validate the square root time law for slow sorption kinetics (§4)</li>
<li><strong>Activated adsorption experiments</strong>: Benton and White (hydrogen on nickel), Taylor and Williamson, and Taylor and McKinney all provided isobar data showing temperature-dependent transitions between adsorption types (§3). Garner and Kingman documented three distinct adsorption regimes at different temperatures.</li>
<li><strong>van der Waals constant data</strong>: Used existing measurements of diamagnetic susceptibility to calculate predicted heats of adsorption (e.g., argon on copper yielding approximately 6000 cal/gram atom, nitrogen roughly 2500 cal/gram mol, hydrogen roughly 1300 cal/gram mol)</li>
<li><strong>KCl crystal calculations</strong>: Computed the full attractive potential field of argon above a KCl crystal lattice, accounting for the discrete ionic structure to produce detailed potential energy curves at different surface positions (§2)</li>
</ul>
<p>The validation approach involves deriving theoretical predictions from first principles and showing they match the functional form and magnitude of independently measured experimental results.</p>
<h2 id="the-lennard-jones-diagram-and-activated-adsorption">The Lennard-Jones Diagram and Activated Adsorption</h2>
<p><strong>Key Outcomes</strong>:</p>
<ul>
<li>The paper introduced the now-famous Lennard-Jones diagram for surface interactions, plotting potential energy versus distance from the surface for both molecular and dissociated atomic species. This graphical model became a cornerstone of surface science.</li>
<li>Derived the square root time law ($S \propto \sqrt{t}$) for slow sorption kinetics, validated against Ward&rsquo;s experimental data.</li>
<li>Established quantitative connection between adsorption potentials and measurable atomic properties (diamagnetic susceptibility).</li>
</ul>
<p><strong>Conclusions</strong>:</p>
<ul>
<li>The nature of adsorption is determined by the interplay between two distinct potential states (molecular and atomic).</li>
<li>&ldquo;Activated adsorption&rdquo; is the process of overcoming an energy barrier to transition from a physically adsorbed molecular state to a chemically adsorbed atomic state.</li>
<li>The model predicts that the specific geometry of the surface (i.e., the lattice spacing) and the orientation of the approaching molecule are critical, as they influence the shape of the potential energy surfaces and thus the magnitude of the activation energy.</li>
<li>The reverse process (recombination of atoms and desorption of a molecule) also requires activation energy to move from the chemisorbed state back to the molecular state.</li>
<li>This entire mechanism is proposed as a fundamental factor in heterogeneous <strong>catalysis</strong>, where the surface acts to lower the activation energy for molecular dissociation, facilitating chemical reactions.</li>
</ul>
<p><strong>Limitations</strong>:</p>
<ul>
<li>The initial &ldquo;method of images&rdquo; derivation assumes a perfectly continuous conducting surface, an approximation that breaks down at the atomic orbital level close to the surface.</li>
<li>While Lennard-Jones uses one-dimensional calculations to estimate initial potential well depths, he later qualitatively extends this to 3D &ldquo;contour tunnels&rdquo; to explain surface migration. However, these early geometric approximations lack the many-body, multi-dimensional complexity natively handled by modern Density Functional Theory (DFT) simulations.</li>
</ul>
<hr>
<h2 id="mathematical-derivations">Mathematical Derivations</h2>
<h3 id="van-der-waals-calculation-section-2">Van der Waals Calculation (Section 2)</h3>
<p>The paper derives the attractive force between a neutral atom and a metal surface using the <strong>classical method of electrical images</strong>. The key steps are:</p>
<ol>
<li><strong>Method of Images</strong>: Lennard-Jones models the metal as a continuum of perfectly mobile electric fluid (a perfectly polarisable system). When a neutral atom approaches, its instantaneous dipole moment induces image charges in the metal surface.</li>
</ol>















<figure class="post-figure center ">
    <img src="/img/notes/method-of-images-atom-surface.webp"
         alt="Diagram showing an atom with nucleus (&#43;Ne) and electrons (-e) at distance R from a conducting surface, with its electrical image reflected on the opposite side"
         title="Diagram showing an atom with nucleus (&#43;Ne) and electrons (-e) at distance R from a conducting surface, with its electrical image reflected on the opposite side"
         
         
         loading="lazy"
         class="post-image">
    
    <figcaption class="post-caption">An atom and its electrical image in a conducting surface. The nucleus (+Ne) and electrons create mirror charges across the metal plane.</figcaption>
    
</figure>

<ol start="2">
<li><strong>The Interaction Potential</strong>: The resulting potential energy $W$ of an atom at distance $R$ from the metal surface is:</li>
</ol>
<p>$$W = -\frac{e^2 \overline{r^2}}{6R^3}$$</p>
<p>where $\overline{r^2}$ is the mean square distance of electrons from the nucleus.</p>
<ol start="3">
<li><strong>Connection to Measurable Properties</strong>: This theoretical potential can be calculated using <strong>diamagnetic susceptibility</strong> ($\chi$). The interaction simplifies to:</li>
</ol>
<p>$$W = \mu R^{-3}$$</p>
<p>where $\mu = mc^2\chi/L$, with $m$ the electron mass, $c$ the speed of light, $\chi$ the diamagnetic susceptibility, and $L$ Loschmidt&rsquo;s number ($6.06 \times 10^{23}$). This connects the adsorption potential to measurable magnetic properties of the atom.</p>
<ol start="4">
<li><strong>Repulsive Forces and Equilibrium</strong>: By assuming repulsive forces account for approximately 40% of the potential at equilibrium, Lennard-Jones estimates heats of adsorption. For argon on copper, this yields approximately 6000 cal per gram atom. Similar calculations give roughly 2500 cal/gram mol for nitrogen on copper and 1300 cal/gram mol for hydrogen.</li>
</ol>
<hr>
<h2 id="kinetic-theory-of-slow-sorption-section-4">Kinetic Theory of Slow Sorption (Section 4)</h2>
<p>The paper extends beyond surface phenomena to model how gas <em>enters</em> the bulk solid (absorption). This section is critical for understanding time-dependent adsorption kinetics.</p>
<h3 id="the-cracks-hypothesis">The &ldquo;Cracks&rdquo; Hypothesis</h3>
<p>Lennard-Jones proposes that &ldquo;slow sorption&rdquo; is <strong>lateral diffusion along surface cracks</strong> (fissures between microcrystal boundaries) in the solid. The outer surface presents not a uniform plane but a network of narrow, deep crevasses where gas can penetrate. This reframes the problem: the rate-limiting step is diffusion along these crack walls, explaining why sorption rates differ from predictions based on bulk diffusion coefficients.</p>
<h3 id="the-diffusion-equation">The Diffusion Equation</h3>
<p>The problem is formulated using Fick&rsquo;s second law:</p>
<p>$$\frac{\partial n}{\partial t} = D \frac{\partial^{2}n}{\partial x^{2}}$$</p>
<p>where $n$ is the concentration of adsorbed atoms, $t$ is time, $D$ is the diffusion coefficient, and $x$ is the position along the crack.</p>
<h3 id="derivation-of-the-diffusion-coefficient">Derivation of the Diffusion Coefficient</h3>
<p>The diffusion coefficient is derived from kinetic theory:</p>
<p>$$D = \frac{\bar{c}^2 \tau^2}{2\tau^*}$$</p>
<p>where:</p>
<ul>
<li>$\bar{c}$ is the mean lateral velocity of mobile atoms parallel to the surface</li>
<li>$\tau$ is the time an atom spends in the mobile (activated) state</li>
<li>$\tau^*$ is the interval between activation events</li>
</ul>
<p>Atoms are &ldquo;activated&rdquo; to a mobile state with energy $E_0$, after which they can migrate along the surface.</p>
<h3 id="the-square-root-law">The Square Root Law</h3>
<p>Solving the diffusion equation for a semi-infinite crack yields the total amount of gas absorbed $S$ as a function of time:</p>
<p>$$S = 2n_0 \sqrt{\frac{Dt}{\pi}}$$</p>
<p>This predicts that <strong>absorption scales with the square root of time</strong>:</p>
<p>$$S \propto \sqrt{t}$$</p>
<h3 id="experimental-validation">Experimental Validation</h3>
<p>Lennard-Jones validates this derivation by re-analyzing Ward&rsquo;s experimental data on the Copper/Hydrogen system. Plotting the absorbed quantity against $\sqrt{t}$ produces linear curves, confirming the theoretical prediction. From the slope of the $\log_{10}(S^2/q^2t)$ vs. $1/T$ plot, Ward determined an activation energy of 14,100 cal per gram-molecule for the surface diffusion process.</p>
<hr>
<h2 id="surface-topography-and-3d-contours">Surface Topography and 3D Contours</h2>
<p>The notes above imply a one-dimensional process (distance from surface). The paper explicitly expands this to three dimensions to explain surface migration.</p>
<h3 id="potential-tunnels">Potential &ldquo;Tunnels&rdquo;</h3>
<p>Lennard-Jones models the surface potential as <strong>3D contour surfaces</strong> resembling &ldquo;underground caverns&rdquo; or tunnels. The potential energy landscape above a crystalline surface has periodic minima and saddle points.</p>
<h3 id="surface-migration">Surface Migration</h3>
<p>Atoms migrate along &ldquo;tunnels&rdquo; of low potential energy between surface atoms. The activation energy for surface diffusion corresponds to the barrier height between adjacent potential wells on the surface. This geometric picture explains:</p>
<ul>
<li>Why certain crystallographic orientations are more reactive</li>
<li>The temperature dependence of surface diffusion rates</li>
<li>The role of surface defects in catalysis</li>
</ul>
<h2 id="reproducibility">Reproducibility</h2>
<p>This is a 1932 theoretical paper with no associated code, datasets, or models. The mathematical derivations are fully presented in the text and can be followed from first principles. The experimental data referenced (Ward&rsquo;s copper/hydrogen measurements, Benton and White&rsquo;s nickel/hydrogen isobars) are cited from independently published sources. No computational artifacts exist.</p>
<ul>
<li><strong>Status</strong>: Closed (theoretical paper, no reproducibility artifacts)</li>
<li><strong>Hardware</strong>: N/A (analytical derivations only)</li>
</ul>
<h2 id="paper-information">Paper Information</h2>
<p><strong>Citation</strong>: Lennard-Jones, J. E. (1932). Processes of Adsorption and Diffusion on Solid Surfaces. <em>Transactions of the Faraday Society</em>, 28, 333-359. <a href="https://doi.org/10.1039/tf9322800333">https://doi.org/10.1039/tf9322800333</a></p>
<p><strong>Publication</strong>: Transactions of the Faraday Society, 1932</p>
<div class="highlight"><pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"><code class="language-bibtex" data-lang="bibtex"><span style="display:flex;"><span><span style="color:#a6e22e">@article</span>{lennardjones1932processes,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">title</span>=<span style="color:#e6db74">{Processes of adsorption and diffusion on solid surfaces}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">author</span>=<span style="color:#e6db74">{Lennard-Jones, John Edward}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">journal</span>=<span style="color:#e6db74">{Transactions of the Faraday Society}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">volume</span>=<span style="color:#e6db74">{28}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">pages</span>=<span style="color:#e6db74">{333--359}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">year</span>=<span style="color:#e6db74">{1932}</span>,
</span></span><span style="display:flex;"><span>  <span style="color:#a6e22e">publisher</span>=<span style="color:#e6db74">{Royal Society of Chemistry}</span>
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div>]]></content:encoded></item></channel></rss>