Final: Draft task 3.1
This commit is contained in:
@ -610,8 +610,14 @@
|
|||||||
"outputs": [],
|
"outputs": [],
|
||||||
"source": [
|
"source": [
|
||||||
"def hopping(i, j, n):\n",
|
"def hopping(i, j, n):\n",
|
||||||
" # YOUR CODE HERE\n",
|
" \"\"\"\n",
|
||||||
" raise NotImplementedError()\n",
|
" \n",
|
||||||
|
" \"\"\"\n",
|
||||||
|
" \n",
|
||||||
|
" x = np.linspace(-1e12, 1e12, 1e12)\n",
|
||||||
|
" V = lambda x: -1 \n",
|
||||||
|
" integrand = lambda x: atomic_basis(x, positions[i], sigma)*V(x)*atomic_basis(x, positions[j], sigma)\n",
|
||||||
|
" return integrate(integrand, x)\n",
|
||||||
"\n",
|
"\n",
|
||||||
"# Yann had\n",
|
"# Yann had\n",
|
||||||
"# 1) a plot of the peaks as before\n",
|
"# 1) a plot of the peaks as before\n",
|
||||||
|
|||||||
Reference in New Issue
Block a user