Author Archives: wdengquantum.me

Diffusion Models

Problem: State and prove Tweedie’s formula. Solution: Tweedie’s formula asserts that if \(p(\mathbf x|\boldsymbol{\mu},\sigma)=\frac{1}{\det(\sqrt{2\pi}\sigma)}e^{-(\mathbf x-\boldsymbol{\mu})^T\sigma^{-2}(\mathbf x-\boldsymbol{\mu})/2}\) is normally distributed, then without needing to know anything about the prior \(p(\boldsymbol{\mu}|\sigma)\) on the mean random vector \(\boldsymbol{\mu}\), one has the following Bayesian … Continue reading

Posted in Blog | Leave a comment

Information Geometry

Problem: Let \(\boldsymbol{\Theta}\) be a smooth statistical manifold, and let \(D:\boldsymbol{\Theta}^2\to [0,\infty)\) be a smooth function. What does it mean for \((\boldsymbol{\Theta},D)\) to be a “divergence manifold“? Solution: The notion of a divergence manifold relaxes the axioms of a metric … Continue reading

Posted in Blog | Leave a comment

Autoencoders

VAE $\textbf{Problem}$: Apply the PRAC-DTDT-ID workflow to a (vanilla) $\textit{autoencoder}$. $\textbf{Solution}$: Problem: to learn a lower-dimensional latent manifold representation of the input manifold (this is justified by the $\textit{submanifold hypothesis}$, namely that the data-generating distribution $p(\mathbf x)$ is essentially supported … Continue reading

Posted in Blog | Leave a comment

Graph Neural Networks

Problem: Give a broad sketch of the current state of the field of research in graph neural networks. Solution: Problem: Okay, so now explain what a graph neural network (GNN) actually is. Solution: A GNN is basically any neural network … Continue reading

Posted in Blog | Leave a comment

Renormalization Group

Problem: Consider a Landau-Ginzburg statistical field theory involving a single real scalar field \(\phi(\mathbf x)\) for \(\mathbf x\in\mathbf R^d\) governed by the canonically normalized free energy density: \[\mathcal F(\phi,\partial\phi/\partial\mathbf x,…)=\frac{1}{2}\biggr|\frac{\partial\phi}{\partial\mathbf x}\biggr|^2+\frac{\phi^2}{2\xi^2}+…\] Explain what the \(+…\) means, explain which terms have … Continue reading

Posted in Blog | Leave a comment

Convolutional Neural Networks

CNNs_Part_1 $\textbf{Problem}$: Write functions that take an arbitrary grayscale image and convolve them with a Sobel edge detection kernel. Apply both functions to a grayscale image of your choice. $\textbf{Solution}$: InĀ [1]: import numpy as np import matplotlib.pyplot as plt sobel_horizontal_kernel … Continue reading

Posted in Blog | Leave a comment

Hamilton’s Optics-Mechanics Analogy

Problem: Deduce the Hamilton-Jacobi equation of classical mechanics. Solution: Instead of viewing the action \(S=S[\mathbf x(t)]\) as a functional of the particle’s trajectory \(\mathbf x(t)\), it can be viewed more simply as a scalar field \(S(\mathbf x,t)\) in which the … Continue reading

Posted in Blog | Leave a comment

Pseudo-Riemannian Geometry

Problem: Define the signature of a matrix. Hence, state and prove Sylvester’s law of inertia. Solution: The signature of an \(n\times n\) matrix \(A\) is a \(3\)-tuple \((n_+,n_-,n_0)\) where \(n_+\) is the number of positive eigenvalues of \(A\) (including multiplicity), … Continue reading

Posted in Blog | Leave a comment

Reinforcement Learning (Part \(1\))

Problem: How does the paradigm of reinforcement learning (RL) fit within the broader context of machine learning? Solution: It is instructive to compare/contrast reinforcement learning with supervised learning. In this way, it will be seen that RL can in fact … Continue reading

Posted in Blog | Leave a comment

Density Functional Theory

Problem: In one sentence, what is the essence of DFT? Solution: To replace \(\Psi\mapsto n\), where the number density of a system of \(N\) identical quantum particles (usually electrons) \(n(\mathbf x)\) is: \[n(\mathbf x):=N\int d^3\mathbf x_2…d^3\mathbf x_N |\Psi(\mathbf x,\mathbf x_2,…,\mathbf … Continue reading

Posted in Blog | Leave a comment