The NumPy code does not adhere to PEP8 and the class could easily be removed, so that `compute_gap` is just a function of the different parameters. Then we could get rid of all the separate functions in the code block that starts with ```python # ϕ_R def ϕ_R(mc, R_new): mc_new = equalizing_diff(R_new, mc.T, mc.γ_h, mc.γ_c, mc.w_h0, mc.D, mc.π) return mc_new.compute_gap() ϕ_R = np.vectorize(ϕ_R) ``` @thomassargent30 Would you be willing to let @HumphreyYang and I simplify the NumPy part of the code without changing what it does?