Skip to content
Snippets Groups Projects
Commit 2ef5f643 authored by Anton Akhmerov's avatar Anton Akhmerov
Browse files

use inline code execution

parent a9ea54e8
No related branches found
No related tags found
No related merge requests found
File moved
```python
from matplotlib import pyplot
import numpy as np
from scipy.optimize import curve_fit
from scipy.integrate import quad
from common import draw_classic_axes, configure_plotting
configure_plotting()
def sqrt_plus(x):
return np.sqrt(x * (x >= 0))
# Band structure parameters.
E_V, E_C, E_F = -1.2, 1.8, .4
E_D, E_A = E_C - .7, E_V + .5
m_h, m_e = 1, .5
```
# Semiconductor physics
## Review of band structure properties
......@@ -102,7 +122,27 @@ Observe that because we are describing particles in the valence band as holes, $
### Part 1: pristine semiconductor
![](figures/intrinsic_DOS.svg)
```python
E = np.linspace(-3, 3, 1000)
fig, ax = pyplot.subplots()
n_F = 1/(np.exp(2*(E - E_F)) + 1)
g_e = m_e * sqrt_plus(E - E_C)
g_h = m_h * sqrt_plus(E_V - E)
ax.plot(E, g_h, label="$g_e$")
ax.plot(E, g_e, label="$g_h$")
ax.plot(E, 10 * g_h * (1-n_F), label="$n_h$")
ax.plot(E, 10 * g_e * n_F, label="$n_e$")
ax.plot(E, n_F, label="$n_F$", linestyle='dashed')
ax.set_ylim(top=1.5)
ax.set_xlabel('$E$')
ax.set_ylabel('$g$')
ax.set_xticks([E_V, E_C, E_F])
ax.set_xticklabels(['$E_V$', '$E_C$', '$E_F$'])
ax.legend()
draw_classic_axes(ax, xlabeloffset=.2)
```
Electrons
$$ E = E_G + {p^2}/{2m_e}$$
......@@ -198,7 +238,26 @@ Likewise an acceptor adds an extra state at $E_A$ (close to the top of the valen
### Density of states with donors and acceptors
![](figures/doping.svg)
```python
E = np.linspace(-3, 3, 1000)
fig, ax = pyplot.subplots()
n_F = 1/(np.exp(2*(E - E_F)) + 1)
g_e = m_e * sqrt_plus(E - E_C)
g_h = m_h * sqrt_plus(E_V - E)
ax.plot(E, g_h, label="$g_e$")
ax.plot(E, g_e, label="$g_h$")
sigma = 0.01
g_D = np.exp(-(E_D - E)**2 / sigma**2)
g_A = .7 * np.exp(-(E_A - E)**2 / sigma**2)
ax.plot(E, g_D, label='$g_D$')
ax.plot(E, g_A, label='$g_A$')
ax.legend()
ax.set_xticks([E_V, E_C, E_A, E_D])
ax.set_xticklabels(['$E_V$', '$E_C$', '$E_A$', '$E_D$'])
draw_classic_axes(ax, xlabeloffset=.2)
```
All donor/acceptor states at the same energy:
$$g_A(E) = N_A \delta(E-E_A),\quad g_D(E) = N_D \delta(E- (E_G - E_D))$$
......@@ -336,7 +395,9 @@ See the book for details.
Density of states in a doped semiconductor:
![](figures/doping.svg)
```python
fig
```
Charge balance determins the number of electrons and holes as well as the position of the Fermi level.
......
```python
from matplotlib import pyplot
import numpy as np
from scipy.optimize import curve_fit
from scipy.integrate import quad
from common import draw_classic_axes, configure_plotting
configure_plotting()
```
# Lecture 8 – Magnetism
_Based on chapters 19 and 20 of the book_
......@@ -81,7 +93,18 @@ $$
with $C$ a constant. This is known as the _Curie law_, and it shows that at high temperature a paramagnetic material becomes less susceptible to magnetisation.
![](figures/curie.svg)
```python
B = np.linspace(-2, 2, 1000)
fig, ax = pyplot.subplots()
ax.plot(B, np.tanh(B * 3), label="low $T$")
ax.plot(B, np.tanh(B), label="high $T$")
ax.legend()
ax.set_ylabel("$M$")
ax.set_xlabel("$B$")
draw_classic_axes(ax, xlabeloffset=.2)
```
### Paramagnetism: free spin $J$
For an atom with magnetic moments $L$ and $S$ the Hamiltonian will become:
......@@ -193,4 +216,4 @@ $$
{\mathcal H}=\sum_i \left( -J \sigma_i \sigma_{i+1}+ g\mu_{\rm B}B\sigma_i\right)
$$
where $\sigma_i=\pm S$.
\ No newline at end of file
where $\sigma_i=\pm S$.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment