|
100 | 100 | "outputs": [], |
101 | 101 | "source": [ |
102 | 102 | "xy = tbt.geometry.xyz[:, :]\n", |
103 | | - "J12 = # fill in the corresponding code here ()\n", |
104 | | - "plt.quiver(xy[:, 0], xy[:, 1], J12[:, 0], J12[:, 1]);" |
| 103 | + "J1 = # fill in the corresponding code here ()\n", |
| 104 | + "plt.quiver(xy[:, 0], xy[:, 1], J1[:, 0], J1[:, 1]);" |
105 | 105 | ] |
106 | 106 | }, |
107 | 107 | { |
|
160 | 160 | "outputs": [], |
161 | 161 | "source": [ |
162 | 162 | "# Read in the two different grids:\n", |
163 | | - "grid0 = sisl.get_sile('siesta.VH').read_grid()\n", |
| 163 | + "grid0 = sisl.get_sile('siesta.VH').read_grid()" |
| 164 | + ] |
| 165 | + }, |
| 166 | + { |
| 167 | + "cell_type": "code", |
| 168 | + "execution_count": null, |
| 169 | + "metadata": {}, |
| 170 | + "outputs": [], |
| 171 | + "source": [ |
164 | 172 | "no_guess = sisl.get_sile('no_guess_0.5.VH').read_grid()\n", |
165 | 173 | "# Specify the geometry so we can add the atoms to the plot\n", |
166 | 174 | "no_guess.set_geometry(device)\n", |
|
240 | 248 | "# the sparse matrix may be *VERY* big).\n", |
241 | 249 | "# small trick to not have the solution array twice.\n", |
242 | 250 | "del grid.grid\n", |
243 | | - "grid.grid = solve(A, b).reshape(shape[0])\n", |
| 251 | + "grid.grid = solve(A, b).reshape(shape.ravel())\n", |
244 | 252 | "grid.write('V.TSV.nc')" |
245 | 253 | ] |
246 | 254 | }, |
|
0 commit comments