{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Notebook 4: Linear Regression (Ising)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Learning Goal\n", "Let us now apply linear regression to an example that is familiar from Statistical Mechanics: the Ising model. The goal of this notebook is to revisit the concepts of in-sample and out-of-sample errors, as well as $L2$- and $L1$-regularization, in an example that is more intuitive to physicists. \n", "\n", "## Overview\n", "Consider the 1D Ising model with nearest-neighbor interactions \n", "\n", "$$H[\\boldsymbol{S}]=-J\\sum_{j=1}^L S_{j}S_{j+1}$$\n", "\n", "on a chain of length $L$ with periodic boundary conditions and $S_j=\\pm 1$ Ising spin variables. In one dimension, this paradigmatic model has no phase transition at finite temperature. \n", "\n", "\n", "### Exercises (optional): ### \n", "We invite the reader who is unfamiliar with the property of the Ising model to solve the following problems.\n", "