Question: 1.8. Use the MATLAB Help Browser to find out how to create a new directory from within MATLAB. Then, create a new directory called mynewdir
1.8. Use the MATLAB Help Browser to find out how to create a new directory from within MATLAB. Then, create a new directory called mynewdir under the current directory. Add the new directory to the top of MATLABs path.
1.9. Change the current directory to mynewdir. Then open an Edit Window and add the following lines:
% Create an input array from -2*pi to 2*pi t = -2*pi:pi/10:2*pi;
% Calculate |sin(t)| x = abs(sin(t)); % Plot result plot(t, x);
Save the file with the name test2.m and execute it by typing test2 in the Command Window. What happens?
1.10. Close the Figure Window and change back to the original directory that MATLAB started up in. Next type test2 in the Command Window. What happens, and why?
I dont know how to go back to the original directory. I do cd .. and the program still opens up.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
