File I/O Exercises in MATLAB


1) Create a MATLAB script that produces a matrix.  The top row of the matrix contains the values of x, from 0 to 10  in .1 increments.  The bottom row of the matrix contains the function y = sin(5x)e-x




Write this data into a file that shows 2 columns, one for x and one for y.

2) Open the data file in EXCEL.  Produce a chart.  Print it out.
 

3) Create a table in EXCEL that contains the following numbers:
 
2 1 -3 5
7 -4 8 0
11 -4 6 5

4) Save this data into a text file.

5) Open the new text file in MATLAB.  Get this data into a single variable named A.