MATLAB: How can i calculate the sum of the following geometric series N= 1000 and r =0.99 homework calculate the sum of the following geometric series N= 1000 and r =0.99 =1+r+r2+r3+…+rN Best Answer N=0:1000;r = 0.99;E = r.^N;sum(E) Related SolutionsMATLAB: Calculate the sum of the following geometric series when N = 1000 and r =1/2 I have searched here and in the “help” in Matlab, but i found nothing about the geometric series If your geometric series is a, a*r, a*r^2, ..., a*r^N, then its sum is:s = a*(1-r^(N+1))/(1-r) MATLAB: How to write a MATLAB program which calculates the exact values for the geometric series a=1; %first termr=1/7;n=5; %number of values in geometric seriess = a*r.^(0:n-1)If you want sum, then writegp_sum=sum(a*r.^(0:n-1)) Related QuestionFor loop in paralel and series resistorsBasic use of sum command help
Best Answer