drop befd Fri Feb1508:32:462002 号 Initia1 Ize some pa rhog=0.9: t Dens air at 3000m 钅Incr sub-iteration counter 9.8:tGravity 917*4*pi/3*a^3:8四s8 g check on convergence t st or ater us fprintf('Maxiaum number on sub-iterations occurred\n') t Initial conditions l1 initial velocity to avoid problems with Re=o and CD z0- 0: 8 Initial particle location 6 Set time length of integration, and number of steps g plot result linspace(0, at Tmax/N l0-4i t Finite difference step size for pf_pw calculation 2·V(,;); t Set Newton-Raphson convergence parameters title(Backward Euler integration with finite-c Iced pf/pw'I 6 Initialize vector for ODE integration 22121 8 start iterative loop for n =2: N+1 ures restol +1: t Doing this forces at least one sub-iteratio while((m Mmax)& (curres >restol ); curres norm(res) t Calculate linearization of f with respect to w using finite differences w(iiss w0+ eps; Perturb ii state by eps fp= drop rhs ( w,p》 w(ii)= w0-eps: Perturb ii state by -eps m=drop_rhs(w,p》; (ii)= wO: t Restore ii state to original value Ifp- fm)/(2*eps): g Finite differenc B Calculate linearization of residual with respect to w es_pw a eye(size(pf pw))-dt'pf_Pw