4. Use MATLAB to sum the number 0.0001 ten thousand times. You may do this in the command window since it takes only a f
Posted: Fri May 20, 2022 4:58 pm
4. Use MATLAB to sum the number 0.0001 ten thousand times. You may do this in the command window since it takes only a few lines of code, but be sure to state in your solution what lines of code you used. (a) Do this using double precision (MATLAB default). Note: be sure to view your results in format long. Compare with the exact solution. (b) Do the same exercise as above but using single precision. You can convert MATLAB variables to single precision as shown in the following example: sum = 0.; sum1 = single (sum);