Ideal Spin-(1/2)Paramagnetism

from Statistical Physics using Mathematica
© James J. Kelly, 1996-2002

Introduction

An ideal two-level system consists N noninteracting elements which each can occupy only two states.  For example, a collection of weakly interacting spin-(1/2) atoms or nuclei subject to an external magnetic field can be treated as an ideal two-level system if mutual interactions and other degrees of freedom, such as kinetic energies, are neglected.  It is convenient to define an alignment variable x, or fractional spin excess, such that \(TraditionalForm\`\(N\_+\) = \(N\/2\) \((1 + x)\)\) is the number of spins aligned with the external field and \(TraditionalForm\`\(N\_-\) = \(N\/2\) \((1 - x)\)\) is the number of spins aligned against the field.  Also, let μ be the magnetic moment of a single spin and ϵ = μ B be the associated unit of magnetic energy.  The energy of the system of N spins is then \(TraditionalForm\`U = \(\(-M\)\ B = \(\(-x\)\ N\ μ\ B = \(-x\)\ U\_max\)\)\) where (Subscript[U, max]) = N ϵ is the maximum possible energy.  It will also be useful to compare the alignment and thermal energies by means of a reduced energy variable, y = μ B/(Subscript[k, B])  T, and to define a reduced temperature τ = (Subscript[k, B]) T/μ B = (y^(-1)).  The statistical mechanics of any two-level system can be expressed in terms of these dimensionless quantities without reference to the specific origin of the energy gap, Δ = 2  ϵ, between the single-particle energy levels.  These definitions are summarized below.

Glossary:
	𝒩	= number of spins
	μ	= magnetic moment for each spin
	B	= external magnetic field
	ϵ	= μ B = magnetic energy scale
	(Subscript[k, B])	= Boltzmann constant
	T	= temperature
	β	= 1/(Subscript[k, B]) T 
	x	= relative alignment
	y	=  μ B / (Subscript[k, B])  T = magnetic/thermal energies
	τ	= 1/y = reduced temperature
	S	= entropy
	U	= internal energy =-x N μ B
	F	= Helmholtz free energy

To express the thermodynamic functions in terms of different choices of independent variables with minimal symbolic changes, we employ different  arguments.  For example, S[x] and S[y] express the entropy in terms of either the spin alignment, x, or the reduced energy, y, respectively.  Similarly, we use S[τ] to express entropy in terms of temperature, where τ is the reduced temperature expressed in dimensionless form as 1/y.

Some effort is expended to portray the functions in simple and familiar algebraic forms, but the plots could have been made without those manipulations.  Later we will often find that aesthetic manipulations are not worth the effort required, but for now it will probably appear comforting to display more elegant formulations.

Initialization

Defaults, packages, symbols

ClearAll["Global`*"];
Off[General::spell, General::spell1];

$DefaultFont = {"Times", 12};
$TextStyle = {FontFamily -> "Times", FontSize -> 12, 
          FontSlant -> "Italic"};

Needs["Utilities`Notation`"]

Symbolize[(Subscript[k, B])]; Symbolize[(Subscript[C, V])];Symbolize[(Subscript[N, m])_];Symbolize[(Subscript[Z, m])_]

Transformation rules

Stirling's formula

StirlingApprox = {Log[x_!] -> x Log[x] - x};

Rules for manipulating hyperbolic trig functions

tanhRules = {
1 - Tanh[y_] -> 
            Exp[-y] Sech[y], 
          1 + Tanh[y_] -> 
            Exp[y] Sech[y], -1 + 
              Tanh[y_] -> -Exp[-y] Sech[y]};

Rules for changing variables

yToT = {y -> ((μ B)/((Subscript[k, B]) T))};
TtoY = {T -> ((μ B)/((Subscript[k, B]) y)), 
          B β μ -> 
            y, μ -> (ϵ/B)};

dydT = -(y/T);
dydB = (y/B);

Plot labels

label[U]  =   StyleForm["U/Nε"];
label[F]  =   StyleForm["F/Nε"];
\(\(label[S]\  = \ \ StyleForm[\*""S/\!\(Nk\_B\)""];\)\)
\(\(label[C\_V]\  = \ 
        StyleForm[\*""\!\(C\_V\)/\!\(Nk\_B\)""];\)\)
label[M]  =  StyleForm["M/NμB"];
label[χ]  =  StyleForm["χ/Nμ"];

Microcanonical Ensemble

Multiplicity and entropy for large N

The macrostate of a spin-(1/2) system can be specified in terms of the total number of spins, N, and the number, \(TraditionalForm\`\(N\_+\)\), parallel to the applied magnetic field.  It is useful to define x as the fractional alignment of the spin system, so that \(TraditionalForm\`\(N\_+\)\  = \ 1\/2\ N\ \((1 + x)\)\) is the total number of spins aligned with the field and \(TraditionalForm\`\(N\_-\)\  = 1\/2\ N\ \((1 - x)\)\) is the total number aligned against the external field.  Because permutations among the \(TraditionalForm\`\(\(N\_+\)\(\ \)\)\) positive spins or the \(TraditionalForm\`\(\(N\_-\)\(\ \)\)\)negative spins do not produce a different microstate, the multiplicity of the macrostate is obtained by dividing the total number of microstates, N!, by the number of indistinguishable permutations of the two spin states; namely, by the binomial coefficient (({{N}, {\(N\_+\)}})).  Furthermore, we are interested in the thermodynamic limit where the number of atoms in either orientation is large and, hence, employ Stirling's  approximation to simplify the algebra.

\(multiplicity = \(𝒩!\)\/\(\(\)\(\(\(N\_+\)!\)\ \ \(\(N\_-\)!\)\)\)\  /. {\(N\_+\) -> 
            1\/2\ 𝒩\ \((1 + x)\), \ \(N\_-\) -> 
            1\/2\ 𝒩\ \((1 - x)\)}\)

The entropy, S[x], is proportional to the logarithm of the multiplicity which, with the aid  of Stirling's formula, becomes:

logMultiplicity = (Log[multiplicity] // PowerExpand) /. 
            StirlingApprox // PowerExpand // Simplify

S[x] = (Subscript[k, B]) logMultiplicity

plotSvsX = 
        Plot[Evaluate[S[x]/(𝒩 (Subscript[k, B]))], {x, -1, 1}, 
          PlotLabel -> "Entropy", 
          PlotRange -> {{-1, 1}, {0, 0.7}}, GridLines -> None, 
          Frame -> True, 
          FrameLabel -> {"x", label[S]}];

The maximum entropy occurs when the alignment vanishes (x = 0), corresponding to maximum disorder.  The entropy decreases as the alignment increases, with positive alignment representing the normal positive-temperature situation.  Negative alignment represents a population inversion, which is possible as a quasi-equilibrium state for isolated  systems.  The physical meaning of the negative-temperature regime is discussed in a later section, after we have derived the thermodynamic relationships that pertain to binary systems.

Entropy using disorder

Instead of using multiplicity, entropy can also be defined as

S = -(Subscript[k, B]) (∑_i) (Subscript[P, i]) Log[(Subscript[P, i])]

where (Subscript[P, i]) is the probability for microstate i.  If the spins are noninteracting, we can define our system to be one of the spins and the environment to consist of all other spins in the sample (ensemble).  The entropy for 𝒩 independent spins is simply 𝒩 times the entropy for a single one.  The probabilities that a particular spin is found either up (+) or down (-) are

(Subscript[P, ±]) = ((1 ± x)/2)

where x is the spin alignment.  Therefore, the entropy for a system of 𝒩 independent spins with alignment x can be written directly as

S = -𝒩 (Subscript[k, B]) (((1 + x)/2) 
              Log[((1 + x)/2)] + ((1 - x)/2) 
              Log[((1 - x)/2)])

without need of Stirling's formula or tedious algebraic simplification.  Note, however, we implicitly used the large 𝒩 approximation when stating probabilities that depended upon the x attributed to the other 𝒩 - 1 spins without regard to the contribution of the spin under consideration to the value of x.

Determine relationship between temperature and energy

The temperature of the system is determined using the standard thermodynamic relationship between entropy and energy, where the energy is related to the magnetic alignment.  Inverting that relationship, we find the dependence of the alignment on temperature, where it is useful to employ the inverse temperature variable y.

eq1 = β == -(∂_x) S[
                    x]/(𝒩 (Subscript[k, B]) μ B) // 
        Simplify

xsol = {x -> (x /. Solve[eq1, 
                        x][[1]]  // 
                  ExpToTrig // TrigFactor)} //. TtoY

U[y] = -x 𝒩 μ B /. xsol  /. 
        TtoY

plotUvsY = 
        Plot[Evaluate[U[y]/(𝒩 ϵ)], {y, -3, 
            3}, PlotLabel -> "Energy", 
          PlotRange -> {{-3, 3}, {-1, 1}}, 
          GridLines -> None, Frame -> True, 
          FrameLabel -> {"y",  label[U]}, 
          DisplayFunction -> $DisplayFunction];

Notice that the internal energy for this system is bounded both below and above; the minimum energy corresponds to complete alignment with the external field while the maximum energy corresponds to complete alignment against the external field.  However, we must remember that our model includes only the magnetic energy and excludes the kinetic energy of the atoms themselves, which can increase without an upper bound.

Heat capacity

The heat capacity is defined as the derivative of the internal energy with respect to temperature.  Here that derivative is obtained by means of the chain rule.

(Subscript[C, V])[y] = (∂_y) U[y] dydT //. TtoY

plotCVvsY = 
        Plot[Evaluate[(Subscript[C, V])[y]/(𝒩 (Subscript[k, B]))], {y, -3, 3}, 
          PlotLabel -> "Heat Capacity", 
          PlotRange -> {{-3, 3}, {0, 0.5}}, GridLines -> None, 
          Frame -> True, FrameLabel -> {"y",  label[(Subscript[C, V])]}, 
          DisplayFunction -> $DisplayFunction];

The fact that the entropy and internal energy for the magnetic system are bounded leads to characteristic maxima in the heat capacity.  This phenomenon is named the Schottky effect and is discussed in more detail in the notebook thermo2.nb.  At low temperature the internal energy approaches its minimum value, such that \(TraditionalForm\`C\_V\  = \ \((∂U\/∂T)\)\  → \ 0\).  At high temperature, the entropy asymptotically approaches its maximum value, such that (Subscript[C, V])  =  
        T(∂(S/∂)T)  →  0.  Therefore, at some intermediate temperature there exists a maximum in the heat capacity.  Because the thermodynamic functions for this system are  either symmetric or antisymmetric with respect to T →  -T, there will actually be maxima for either sign of the temperature.  The location of these maxima can be determined by differentiation, but the resulting transcendental equation must be solved numerically.

eq2 = 
      Simplify[(∂_y) (Subscript[C, V])[y]/(𝒩 (Subscript[k, B])) == 
          0]

ycvMax = FindRoot[eq2, {y, 1}]

(Subscript[C, V])[y] /. ycvMax  /. TtoY

Magnetic susceptibility

The magnetic susceptibility is defined as the derivative of the magnetization with respect to the applied field.  The magnetization itself is simply obtained by dividing the internal energy by the magnetic field.

M[y] = -U[y]/B  /. {ϵ -> μ B}

Plot[
        Evaluate[M[y]/(𝒩 μ)], {y, -3, 
          3}];

χ[y] = (∂_y) M[y] dydB

\(\(plotCHIvsY = 
        Plot[Evaluate[\(χ[y] B\)\/\(𝒩\ μ\)], {y, \(-3\), 3}, PlotLabel -> "Magnetic Susceptibility", 
          PlotRange -> {{\(-3\), 3}, {\(-0.5\), 0.5}}, 
          GridLines -> None, Frame -> True, 
          FrameLabel -> {"y", \ label[χ]}, 
          DisplayFunction -> $DisplayFunction];\)\)

Because the magnetization is bounded, the magnetic susceptibility has extrema which can easily be determined.

eq3 = 
      Simplify[((B (∂_y) χ[y])/(𝒩 μ)) == 0]

ychiMax = FindRoot[eq3, {y, 1}]

χ[y] /. ychiMax

Entropy and free energy as a functions of inverse temperature

S[y]  = ((S[x] /. xsol  //. tanhRules) // 
                  PowerExpand // ExpToTrig // Simplify) /. 
          Log[4] -> 2  Log[2]  // Simplify

plotSvsY = 
        Plot[Evaluate[S[y]/(𝒩 (Subscript[k, B]))], {y, -3, 3}, 
          PlotLabel -> "Entropy", 
          PlotRange -> {{-3, 3}, {0, 0.75}}, GridLines -> None, 
          Frame -> True, FrameLabel -> {"y", label[S]}, 
          DisplayFunction -> Identity];

F[y] = Simplify[U[y] - T S[y] //. TtoY]

plotFvsY = 
        Plot[Evaluate[F[y]/(𝒩 ϵ)], {y, -3, 
            3}, PlotLabel -> "Free Energy", 
          PlotRange -> {{-3, 3}, {-5, 5}}, 
          GridLines -> None, Frame -> True, 
          FrameLabel -> {"y", label[F]}, 
          DisplayFunction -> Identity];

Display thermodynamic functions versus inverse temperature

Show[
        GraphicsArray[{{plotUvsY, plotCVvsY}, {plotFvsY, plotCHIvsY}}, 
          GraphicsSpacing -> {-0.1, 0.05}, 
          DisplayFunction -> $DisplayFunction]];

Examine thermodynamic functions of temperature

Here the thermodynamic functions are expressed in terms of reduced temperature using y -> (1/τ).

U[τ] = U[y] /. {y -> (1/τ)};
S[τ] = S[y] /. {y -> (1/τ)};
F[τ] = F[y] /. {y -> (1/τ)};
(Subscript[C, V])[τ] = (Subscript[C, V])[y] /. {y -> (1/τ)};
χ[τ] = χ[y] /. {y -> (1/τ)};

\(\(plotUandFvsT = 
        Plot[Evaluate[{U[τ]\/\(𝒩\ ϵ\), 
              F[τ]\/\(𝒩\ ϵ\)}], {τ, \(-5\), 5}, PlotLabel -> "U and F", 
          PlotRange -> {{\(-5\), 5}, {\(-4\), 4}}, 
          PlotStyle -> {{}, Dashing[{0.02, 0.02}], 
              Dashing[{0.04, 0.01, 0.02, 0.01}]}, GridLines -> None, 
          Frame -> True, 
          FrameLabel -> {"reduced temperature", label[U]}, 
          DisplayFunction -> Identity];\)\)

plotCVvsT = 
        Plot[Evaluate[
            (Subscript[C, V])[τ]/(𝒩 (Subscript[k, B]))], {τ, -5, 5}, 
          PlotLabel -> "Heat Capacity", 
          PlotRange -> {{-5, 5}, {0, 0.5}}, GridLines -> None, 
          Frame -> True, 
          FrameLabel -> {"reduced temperature", label[(Subscript[C, V])]}, 
          DisplayFunction -> Identity];

plotSvsT = 
        Plot[Evaluate[
            S[τ]/(𝒩 (Subscript[k, B]))], {τ, -5, 5}, 
          PlotLabel -> "Entropy", 
          PlotRange -> {{-5, 5}, {0, 0.75}}, GridLines -> None, 
          Frame -> True, 
          FrameLabel -> {"reduced temperature", label[S]}, 
          DisplayFunction -> Identity];

\(\(plotCHIvsT = 
        Plot[Evaluate[\(χ[τ]\ B\)\/\(𝒩\ μ\)], {τ, \(-5\), 5}, PlotLabel -> "Magnetic Susceptibility", 
          PlotRange -> {{\(-5\), 5}, {\(-0.5\), 0.5}}, 
          GridLines -> None, Frame -> True, 
          FrameLabel -> {"reduced temperature", label[χ]}, 
          DisplayFunction -> Identity];\)\)

Show[
        GraphicsArray[{{plotUandFvsT, plotCVvsT}, {plotSvsT, plotCHIvsT}}, 
          GraphicsSpacing -> {-0.1, 0.05}, 
          DisplayFunction -> $DisplayFunction]];

Limiting Behaviors

Considerable insight into the behavior of various systems is often obtained from symbolic expressions for their limiting behavior.  In this section we examine the low and high temperature limits.

High Temperature

The high temperature limit can be obtained easily using Taylor series expansion with respect to the inverse temperature, y, about zero.  We can easily transform between y and T, if desired.

Series[U[y], {y, 0, 2}]

Series[S[y], {y, 0, 2}]  // Simplify  // 
      Collect[#1, {B, μ, 𝒩, (Subscript[k, B])}] &

Series[F[y], {y, 0, 2}]  // Simplify  // 
      Collect[#1, {B, μ, 𝒩, (Subscript[k, B])}] &

Series[(Subscript[C, V])[y], {y, 0, 2}]

Series[χ[y], {y, 0, 2}]

Thus, at high temperature or small field we find that the entropy is near its maximum possible value, (Subscript[S, max]) = N (Subscript[k, B]) Log[2], where each spin is nearly equally likely to be against as along the applied field and where the net magnetization is small.  Under these circumstances we recover Curie's law of paramagnetism, χ ∝ (T^(-1)), and obtain the proportionality constant also.  The heat capacity is small, (Subscript[C, V]) ∝ (T^(-2)), because the state of maximum disorder cannot increase its entropy further by absorbing heat.

Low Temperature

The low temperature limit is more difficult because the Boltzmann factor, \(TraditionalForm\`Exp[\(±\(ϵ\/\(k\_B\ T\)\)\)]\), has an essential singularity for T -> 0.  Nevertheless, the limiting behavior can be obtained by using explicit rules for isolating the singularity in the Boltzmann factor as manifested by various exponential and hyperbolic functions.

\(\(lowTrules = {
Cosh[1\/τ] -> 
            1\/2\ Exp[1\/τ]\ \((1 + Exp[\(-\(2\/τ\)\)])\), 
	
          Sinh[1\/τ] -> 
            1\/2\ Exp[1\/τ]\ \((1 - Exp[\(-\(2\/τ\)\)])\), 
	
          Sech[1\/τ] -> 
            2\ Exp[\(-\(1\/τ\)\)]\ \((1 - 
                  Exp[\(-\(2\/τ\)\)])\), 
	
          Csch[1\/τ] -> 
            2\ Exp[\(-\(1\/τ\)\)]\ \((1 + 
                  Exp[\(-\(2\/τ\)\)])\), 
	
          Tanh[1\/τ] -> 1 - 2\ Exp[\(-\(2\/τ\)\)], 
	
          Coth[1\/τ] -> 1 + 2\ Exp[\(-\(2\/τ\)\)], 
	
          Log[1 + x_] -> x
};\)\)

U[τ] /. lowTrules

(F[τ] /. lowTrules  // PowerExpand // Simplify) /. 
        lowTrules  // Simplify

(S[τ] /. lowTrules  // PowerExpand // Simplify) /. 
        lowTrules  // Simplify

(Subscript[C, V])[τ] //. lowTrules // Expand  // 
      Collect[#1, {(Subscript[k, B]), 𝒩, (1/(τ^2))}] &

χ[τ]  //. lowTrules // Expand // 
      Collect[#1, {(Subscript[k, B]), 𝒩, μ, B, 
            (1/( τ))}] &

Thus, at low temperature or high field we find that the entropy of the system becomes small because the magnetization is near its maximum possible value with most of the spins aligned with the external field.  Similarly, the magnetic susceptibility and heat capacity are quite small for a completely ordered system.  When the thermal energy is small compared with the magnetic energy, most spins are found in their lowest energy state and it becomes very difficult to populate the upper level.

Canonical Ensemble

Here we demonstrate that the same thermodynamic functions can be obtained more efficiently using the canonical ensemble.  The single-particle partition function is denoted Z1.

Z1 = Exp[-y] + Exp[y] // ExpToTrig

Fcanonical = -𝒩 (Subscript[k, B]) T Log[Z1] //. 
        TtoY

Scanonical = -(∂_y) Fcanonical dydT /. 
            TtoY  /. ϵ -> μ B // Simplify

Ucanonical = (∂_y)(y Fcanonical)

These results reproduce those obtained above from the microcanonical ensemble.

Negative spin temperature

The classic example of negative temperature is provided by nuclear spin systems which interact so weakly with the surrounding crystal lattice that macrostates with nuclear magnetization opposed to the external magnetic field can be maintained in constrained or partial equilibrium for a long time.  This phenomenon was first demonstrated by Purcell and Pound.  The nuclear spins were aligned parallel to a strong magnetic field.  The field was then reversed so rapidly that the spins remained in their original orientation and found themselves aligned antiparallel with the magnetic field.  Hence, the nuclear spin system is characterized by negative temperature.  The spin system then gradually gives up its excess internal energy and returns to a state aligned with the external field with a relaxation time of the order of 5 minutes.  Although the macrostate changes and is not truly in equilibrium at negative temperature, the relaxation time is so long compared with atomic time scales that it can be considered to be a quasistatic process that is always sufficiently near equilibrium to apply the concepts and methods of equilibrium statistical mechanics.

For a system whose energy is limited to a finite range, the entropy will generally be small at the extreme values of the internal energy and maximal somewhere in between, as seen above for the two-level system.  The temperature, \(TraditionalForm\`T = \((∂\ S\/∂\ U)\)\^\(-1\)\), will then be positive for U below the entropy peak, negative above, and infinite at the peak where ∂ (S/∂) U = 0.  The figure below illustrates the dependence of temperature upon internal energy and shows that there is a singularity at U = 0.  The difference in energy between states with very large negative temperature and states with very large positive temperature is actually very small.  Therefore, the heat capacity must vanish at the entropy peak because an infinitesimal change in energy produces an infinite change in temperature.

\(\(ParametricPlot[
        Evaluate[{U[τ]\/\(𝒩\ ϵ\), τ}], {τ, \(-20\), 20}, PlotLabel -> "Reduced Temperature vs. Energy", 
        Frame -> True, 
        FrameLabel -> {"U/𝒩ϵ", "τ"}];\)\)

States with negative temperature have more internal energy than states with positive temperature and hence should be regarded as hotter.  In fact, one can easily show that if a system with negative spin temperature is brought into thermal contact with a system at any positive temperature, then heat will flow from the negative temperature toward the positive temperature.  The system initially with negative temperature is thereby "cooled" as its temperature becomes increasingly negative until it jumps between negative infinity to positive infinity and is then reduced to some final positive value at which thermal equilibrium can be attained with a normal system that exhibits only positive temperatures.  In the case of nuclear spins, the constrained system is an abstract system consisting of just the nuclear spin degrees of freedom, which are nearly isolated dynamically, whereas the normal system consists of all other degrees of freedom, such as atomic spins or lattice vibrations, for the same physical system.

Systems whose entropy as a function of energy exhibits a maximum are not statistically normal and occur only as an idealization for which the energy is considered bounded.  Nevertheless, if the dynamics of the system result in characteristic equilibration times that are vastly different for two subsystems or for two different degrees of freedom, it may be possible to analyze partial  equilibrium conditions in terms of negative temperatures for a subsystem whose contribution to the total energy is bounded.  In that case it is useful to associate two different temperatures with the two subsystems that interact only weakly with each other.  In the present situation we associate a spin temperature with the nuclear spins and a conventional (positive) temperature with the lattice.

References

E.M. Purcell and R.V. Pound, A Nuclear Spin System at Negative Temperature, Phys. Rev. 81, 279 (1951).

Problems