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

and another plot goes (doping)

parent c78ce08a
Branches
Tags
No related merge requests found
......@@ -11,21 +11,23 @@ from scipy.integrate import quad
import common
from common import draw_classic_axes
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
def plot_dos():
E = np.linspace(-3, 3, 1000)
fig, ax = pyplot.subplots()
E_V, E_C, E_F = -.5, 1, 0.3
m_h, m_e = 1, .5
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)
sqrt_plus = lambda x: np.sqrt(x * (x >= 0))
ax.plot(E, g_h, label="$g_e$")
ax.plot(E, g_e, label="$g_h$")
ax.plot(E, g_h * (1-n_F), label="$n_h$")
ax.plot(E, g_e * n_F, label="$n_e$")
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)
......@@ -37,9 +39,33 @@ def plot_dos():
draw_classic_axes(ax, xlabeloffset=.2)
fig.savefig('intrinsic_DOS.svg')
def plot_doping():
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)
sqrt_plus = lambda x: np.sqrt(x * (x >= 0))
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)
fig.savefig('doping.svg')
def main():
os.chdir('docs/figures')
plot_dos()
plot_doping()
if __name__ == "__main__":
main()
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment