ToolPythonIntermediate Band structure with plane waves in NumPy: an electron in a 1D crystal print(f"N = {N:2d} error of bands 1-{min(N, 7)}:", np.array2string(err[:7], precision=4, suppress_small=True))
ConceptPythonAdvanced The adjoint method: why 200 derivatives cost two solves, not 201 print(np.array2string(grad[::10], precision=0, separator=", ", max_line_width=90, floatmode="fixed"))