University of Kurdistan logoNanoelectronics · Week 11 Study ToolkitProf. Mohammad Razaghi
University of Kurdistan logo
WEEK 11 · THE SECOND LAW AND INFORMATION

The second law, Fock space and the fuel value of information

Study toolkit for students · based on S. Datta, Lessons from Nanoelectronics, Part A, Chapters 15–16
Prof. Mohammad Razaghi · University of Kurdistan

1This week's plan

Read
Datta Part A, Chapters 15–16 (pp. 195–226): the second law and the fuel value of information.
Run
Colab notebook week11_second_law.ipynb: both widgets, Einstein-solid counting, Fock-space averages, the info-battery and the exercises.
Practise
Quiz (aim for 8/10), the practice problems and one mini-investigation. These ideas return in C6 next week.

By the end of the week you should be able to

  1. State the second law for a channel with several reservoirs and show the elastic resistor obeys it.
  2. Explain P(−ε)/P(+ε) = eε/kT from the reservoir's number of states and 1/T = dS/dE.
  3. Apply pi ∝ e−(Ei−µNi)/kT to Fock-space states: Fermi, Bose and interacting levels.
  4. Derive S = −Nk Σ p ln p and the Boltzmann distribution from minimum free energy.
  5. Explain the info-battery, NkT ln 2, Landauer's principle and Maxwell's demon.

Optional video: Datta's nanoHUB-U course, Unit 4: L4.5–L4.9.

2Key ideas in five sentences

  1. The second law for transport. The total entropy of all reservoirs increases: Σ (Ei − µiNi)/Ti ≤ 0; at one temperature a battery can only lose energy.
  2. Entropic asymmetry. Emitting ε into a reservoir multiplies its states by eε/kT, so emission beats absorption by that factor. Every model with energy exchange must build this in.
  3. One law of equilibrium. States of the whole system (Fock space) are occupied with e−(E−µN)/kT/Z; for one level it is the Fermi function, for one mode the Bose function, with interactions something new.
  4. Entropy and free energy. S = −Nk Σ p ln p; the Boltzmann distribution minimises F = E − TS, and any other distribution carries extra free energy.
  5. Information is fuel. A known state (S = 0) of N spins can drive an info-battery with up to NkT ln 2; erasing costs at least that (Landauer).

3Equation sheet

N₁ + N₂ = 0,   E₁ + E₂ + E₀ = 0Eqs. 15.1–15.2
Particle and energy conservation for a channel.
(E₁ − µ₁N₁)/T₁ + (E₂ − µ₂N₂)/T₂ + E₀/T₀ ≤ 0Eq. 15.3
Second law; one temperature ⇒ µ₁N₁ + µ₂N₂ ≥ 0 (15.5).
P(+E, +N)/P(−E, −N) = e−(E−µN)/kTEqs. 15.6–15.7
Asymmetry of absorption and emission.
D₂←₁/D₁←₂ = e(E₁−E₂)/kT₀Eq. 15.9
Inelastic rates; I ∼ D₂←₁f₁(1 − f₂) − D₁←₂f₂(1 − f₁) (15.10).
S = k ln W,   1/T = dS/dEEqs. 15.11, 15.13
Boltzmann entropy and temperature.
ΔS₁ + ΔS₂ + ΔS₀ ≥ 0;   ΔF = ΔE − TΔS ≤ 0Eqs. 15.14–15.17
Entropy increases; free energy decreases.
pi = e−(Ei−µNi)/kT/ZEq. 15.18
Law of equilibrium for Fock-space states.
n = 2/(1 + eˣ) (U₀ → 0);   n = 1/(1 + eˣ/g) (U₀ → ∞)Eqs. 15.21–15.23
Interacting levels, x = (ε − µ)/kT.
S = −Nk Σ p̃i ln p̃iEqs. 15.24–15.25
From W = N!/ΠNi! with Stirling.
F = Σ p̃i(Ei + kT ln p̃i)Eqs. 15.26–15.27
Minimum at the Boltzmann distribution.
Eavailable = F − Feq = (E − Eeq) + T(Seq − S)Eqs. 16.1, 16.6
Energy + info-energy.
Δµ = kT ln(PU/PD),   E = TΔS = NkT ln 2Eqs. 16.10–16.12
Info-battery.
H = −Σ pi ln pi;   Eerase ≥ NkT ln 2Eq. 16.13, Sec. 16.4
Shannon entropy; Landauer's principle.

4Physics refresher: counting, temperature, Boltzmann

Counting

N spins with n up: W = N!/(n!(N − n)!). The half-up macrostate has W ≈ 2N; for N = 10²³ every other macrostate is negligible. S = k ln W adds for independent systems.

Boltzmann factor

A small system in contact with a big reservoir: p(E) ∝ WR(Etot − E) ∝ e−E/kT, because ln WR decreases by E/kT (1/T = dS/dE).

Stirling in one lineln n! = Σ ln k ≈ ∫₁ⁿ ln x dx = n ln n − n + 1 ≈ n ln n − n for large n.
Why the Fermi function has E − µ but the Bose function only ħωElectrons are conserved: an electron entering a contact at E dissipates E − µ, the rest is the energy µ of the added particle. Photons and phonons are created and absorbed, so the full ħω is exchanged.

5Glossary

TermMeaning
ReservoirA system so large that exchanges do not change its T and µ.
Entropy Sk times the log of the number of accessible states.
Free energy FE − TS; decreases in any spontaneous process at fixed T.
Fock spaceStates of the whole system labelled by occupation numbers (00, 01, 10, 11, …).
Law of equilibriumpi ∝ e−(Ei−µNi)/kT for Fock-space states.
Info-energyT(Seq − S): extractable because the state is known.
Landauer's principleErasing N bits costs at least NkT ln 2.
Maxwell's demonA sorter that uses information to create a temperature difference.

6Calculators

Boltzmann, Fermi and Bose

Boltzmann e−E/kT
Fermi 1/(eE/kT + 1)
Bose 1/(eE/kT − 1)
kT

Entropy and information

S/Nk = −Σ p ln p
H in bits
S for N systems
T(Seq − S) per system at 300 K

Info-battery and Landauer

Δµ/q = (kT/q) ln(PU/PD)
Energy still available per spin
Landauer minimum for those bits
kT ln 2

7Self-check quiz

Click an answer: you get instant feedback. Score: 0 / 0

8Practice problems

k = 1.381 × 10⁻²³ J/K = 86.17 µeV/K; kT = 25.85 meV and kT ln 2 = 17.92 meV at 300 K.

P1. A small reservoirEASY

An Einstein solid with N = 100 oscillators holds Q = 100 quanta. Find W(Q)/W(Q − 1) and kT/ε. Compare with the large-N formula.

HintW = C(Q + N − 1, Q).
SolutionW(Q)/W(Q − 1) = (Q + N − 1)/Q = 1.99 ⇒ kT/ε = 1/ln 1.99 = 1.453; large-N 1/ln 2 = 1.443.
P2. No free lunchEASY

Show from Eqs. 15.2–15.3 with T₁ = T₂ = T₀ that µ₁N₁ + µ₂N₂ ≥ 0, and interpret.

SolutionMultiply 15.3 by T: E₁ + E₂ + E₀ − (µ₁N₁ + µ₂N₂) ≤ 0, and E₁ + E₂ + E₀ = 0 ⇒ µ₁N₁ + µ₂N₂ ≥ 0: the battery can only deliver energy, never be charged by surroundings at the same temperature.
P3. Why atoms stay excited only brieflyEASY

Hydrogen 2p–1s: ε = 10.2 eV. Ratio of upward to downward rates at 300 K?

Solutione−10.2/0.02585 = e−394.6 ≈ 10−171: absorption from the thermal field essentially never happens.
P4. Fermi and Bose from Fock spaceMEDIUM

(a) Level 0.1 eV above µ at 300 K: occupation? (b) Phonon mode ħω = 10 meV at 300 K: average number?

Solution(a) 1/(e3.868 + 1) = 0.0205. (b) 1/(e0.3868 − 1) = 2.12.
P5. Strongly interacting levelsMEDIUM

g levels, U₀ → ∞, ε = µ. Average n for g = 2 and g = 6? What would non-interacting levels give?

Solutionn = 1/(1 + 1/g): 2/3 and 6/7 = 0.857. Non-interacting: g/2 = 1 and 3.
P6. Entropy of a partially polarised sampleMEDIUM

N = 10²⁰ spins with p = ¼, ¾. Find S.

SolutionS/Nk = 0.5623 ⇒ S = 10²⁰ × 1.381 × 10⁻²³ × 0.5623 = 7.76 × 10⁻⁴ J/K.
P7. Info-battery voltageMEDIUM

PU = 0.9 at 300 K: open-circuit voltage, and energy still available per spin?

SolutionΔµ/q = 25.85 mV × ln 9 = 56.8 mV. Available T(Seq − S) = (0.693 − 0.325)kT = 9.5 meV per spin.
P8. Erasing a gigabyteHARDER

Landauer minimum to erase 1 GB (8 × 10⁹ bits) at 300 K?

Solution8 × 10⁹ × 2.871 × 10⁻²¹ J = 2.3 × 10⁻¹¹ J, many orders of magnitude below what real memories spend.
P9. Minimum free energyHARDER

Show that F = Σ p̃i(Ei + kT ln p̃i) with Σ p̃i = 1 is minimised by the Boltzmann distribution, and that Fmin = −kT ln Z.

HintLagrange multiplier.
Solution∂/∂p̃i: Ei + kT ln p̃i + kT − λ = 0 ⇒ p̃i ∝ e−Ei/kT. Then Ei + kT ln p̃i = −kT ln Z for all i ⇒ F = −kT ln Z.

9Common mistakes

MISTAKE"Electrons go down in energy because of a force."
CORRECTThe mechanical coupling is symmetric; the surroundings make emission eε/kT times more likely (entropic).
MISTAKE"The Fermi function describes each electron."
CORRECTIt is the probability that a one-electron level is full, from Fock-space states of that level; with interactions it fails (Eq. 15.22).
MISTAKE"Ordered states store energy."
CORRECTThe all-up spins have the same energy as random spins; they store free energy through low entropy, and any known state works.
MISTAKE"Erasing a bit must dissipate kT ln 2."
CORRECTIt must cost at least kT ln 2 of work, which an info-battery could in principle recover.
MISTAKE"The second law is about a single system."
CORRECTIt concerns the total entropy of all reservoirs involved (Eq. 15.14).
MISTAKE"Temperature is defined for any system."
CORRECTOnly in equilibrium; a metastable spin collection has entropy but no temperature.

10Explore

Files are in the course folder (course_materials).

Mini-investigations (15 min each)

  1. In the reservoir widget, use NR = 20 and Q/NR = 0.2. Is the histogram still Boltzmann? Why not?
  2. In the info-battery, find the load at which half of NkT ln 2 is delivered. How long did it take compared with the largest load?
  3. Erase with η = 0.1 and η = 2: how much extra work did the fast erasure cost?

11Can I…?

Tick what you can do without notes. Your ticks are saved in this browser.

12Looking ahead: Week 12 and circular session C6

Part B begins: Contact-ing Schrödinger (Datta Part B, Ch. 17), then C6: a Colab lab on tight-binding chains and on this week's statistics.

  1. How can a differential equation become a matrix?
  2. Why does a chain of atoms give a band E(k) = ε + 2t cos ka?
  3. How do we connect a matrix Hamiltonian to two contacts?