Matlab Commands

Matlab Commands for Test 1

Here is a list of what you need to be able to do with Matlab for the first test:

For help with a command enter "help" followed by the name of the command, for example "help int" will give you information on the int command.

When plotting functions with the ezplot command, you may find the commands "hold on" and "hold off" useful. If you enter "hold on" at the command prompt, all future graphs that you plot will appear in the same figure as the current graph (until you enter "hold off"). If you enter "hold off" at the command prompt, each graph will replace the previous graphs. For example, if you wish to plot the graph y = x sin(x) and the constant function y = 0 on the interval from -pi to pi, you would enter:

>> hold on
>> ezplot('x*sin(x)',[-pi,pi])
>> ezplot('0',[-pi,pi])