functionx=shoot_method(A,f)%LU分解思路的追赶法求解三对角阵%输入:Ax=f中A,f%输出:xlen_f=length(f);%矩阵尺寸a=[0;diag(A,-1)];b=diag(A,0);c=diag(A,1);%获取对角元素l=zeros(1,len_f-1);uu=zeros(1,len_f);uu(1)=b(1);forii=2:len_f%紧凑格式Doolittle分解l(ii)=a(ii)/u...
was shown that the explicit method of numerically solving the heat equation lead to an extremely restrictive time step. This motivates another scheme which allows for larger time steps, but with the trade off of more computational work per step. This method is known as the Crank-Nicolson scheme...