Numerical Methods, Mathematics, Engineering, Python, Chemical Engineering.
d2y, k): return d2y[0] + k * y[0] + 1 def bc_1(x, y, dy, d2y, k): return dy[0] - 1 After defining the functions, the process is almost done, and we will solve the problem it in just three more lines of code (could have been just two). I’m using k=1 here, but we could have tried different numbers.