Computational Physics, Python, Math, Physics.
+ (CFL_2 - 1)/(CFL_2 + 1)*(u_np1[:,j-1] - u_n[:,j]) u_nm1 = u_n.copy() u_n = u_np1.copy() U[:,:,1] = u_n.copy() #Process loop (on time mesh) for n in range(2, N_t): #calculation at step j+1 #without boundary cond u_np1[1:N_x,1:N_y] = 2*u_n[1:N_x,1:N_y] - u_nm1[1:N_x,1:N_y] + Cx2*(