1. Using MATLAB
To run MATLAB from ATHENA: At the ATHENA prompt athena% enter: athena% add matlabThis will bring up the MATLAB command window with its own MATLAB prompt >>. You can also obtain a windows-like desktopwindow by typing desktop in the command window. To run MATLAB from a WINDOWS PC: MATLAB may be started from a shortcut or from the WINDOWS Start button. This will bring up the MATLAB command/desktop window with the MATLAB prompt >>. You can specify the path name that MATLAB uses to search for program or data files in the current directory text box near the top of the command window. You can also save a set of path names that are routinely searched by selecting the Set Path... and then Add Folder ... from the File pulldown menu. Entering MATLAB commands: Interactive mode -- Run individual MATLAB commands directly from the command window.To create or modify program files for batch mode use the MATLAB editor. To start the MATLAB editor window from the main MATLAB window select New and then M-file from the File pulldown menu in the desktop window or enter the command edit from the command line. To edit an existing file select open and select the approriate file or enter edit followed by the file name. A batch mode MATLAB program can take the form of a script or a function: A script runs much as if you were typing the program statements in the command window. In particular, the values of all variables are retained in memory and are accessible even after the program has run.You can run a script or function by typing the name of its file (without the .m suffix) in the MATLAB command window. For example, if your program is stored in the file myprogram.m then you run it by entering: >> myprogramDepending on the display options you chose the results of the computations will be shown in the main MATLAB window, plotted in a separate plot window, or written to another file. |
2. MATLAB Resources
The MATLAB resources available to you both on-line and as hard copy are plentiful and easily accessible. The following links represent a brief summary of available MATLAB documentation to get you started. In addition to the links here, many MATLAB reference books are available at the Coop and in the MIT libraries. Help within MATLAB:
Typing help [command] at the MATLAB prompt will give you a brief explanation of [command]. If you DON'T know what command you
are confused about, typing help at the MATLAB prompt will give you
a list of categories. Then typing help [category] will produce a list
of commands in [category]. For example, one of the categories is graphics.
Typing help graphics produces a list of the MATLAB graphics commands.
MATLAB Stock Answers: FAQs from Athena On-Line Consulting. Inessential MATLAB: SIPB document of basic MATLAB usage. MATLAB at MIT Homepage: Information about MATLAB from the Athena people. Contains a lot of logistical information as well as many useful links. Mathworks Homepage: The makers of MATLAB. Information on acquiring Mathworks products plus links to documentation, etc. MATLAB Manuals: Available in Barker and Hayden libraries as well as in the Athena Consulting Office. On Line Consulting: OLC supports MATLAB questions. To access On-Line Consulting, type olc at the Athena prompt and choose matlab as your topic. Type in your question and an OLC consultant will email the answer to your question, usually within a few hours. Mathworks support: This is a useful site that has technical information, web version of Helpdesk, and a downloadable user-library of scripts. Everything you ever dreamed of knowing about MATLAB, plus you can always email Mathworks. Athena Minicourses: Offered throughout the semester by the Athena Training
Group. Basically a one hour short-course to get you started. |
Copyright 2003 Massachusetts Institute of Technology
Last modified Sept.. 3, 2003 |