MATLAB_MODULE_1_updated.pptx
MATLAB_MODULE_1_updated.pptx
By
Sunita Shirahatti
Assistant Professor, Dept. ECE, JSSATEB
What is MATLAB?
• MATLAB® is a programming platform designed specifically for
engineers and scientists to analyze and design systems and
products that transform our world.
• MATLAB has since been expanded and now has built-in functions for solving
problems requiring data analysis, signal processing, optimization, and several
other types of scientific computations.
• It also contains functions for 2-D and 3-D graphics and animation.
What is the importance of MATLAB?
• Data Analysis and Visualization: MATLAB provides powerful
tools for data analysis, manipulation, and visualization.
MATLAB logo
What is MATLAB and its types?
• MATLAB allows
- matrix manipulations
- plotting of functions and data
- implementation of algorithms
- creation of user interfaces
-interfacing with programs written in other languages.
2. Utilize the built-in function, saving and loading data, and create plots
3. develop program using symbolic computations, Importing and exporting data and files
4. develop program using character strings, Command line functions and Built-in functions.
Module -1
• Introduction
• Basics of MATLAB
• Simple arithmetic calculations
• creating and working with arrays and numbers.
What is MATLAB?
• MATLABTM is a software package for high-performance numerical
computation and visualization.
• It provides an interactive environment with hundreds of built-in
functions for technical computation, graphics, and animation.
• It also provides easy extensibility with its own high-level programming
language
Features and capabilities of MATLAB
• MATLAB’s built-in functions provide excellent tools for linear algebra
computations, data analysis, signal processing, optimization, numerical
solution of ordinary differential equations (ODEs), quadrature, and many
other types of scientific computations.
• There are also several optional ‘Toolboxes’ available from the developers
of MATLAB.
Current Directory:
• This is where all your files from the current directory are listed. You
can do file navigation
Launch Pad:
This subwindow lists all MATLAB related applications and toolboxes that
are installed on your machine.
You can launch any of the listed applications by double clicking on them.
Workspace:
This subwindow lists all variables that you have generated so far and
shows their type and size.
You can do various things with these variables, such as plotting, by
clicking on a variable and then using
Command History:
All commands typed on the MATLAB prompt in the command window
get recorded, even across multiple sessions.
2. Graphics window:
The output of all graphics commands typed in the command window are
flushed to the graphics or Figure window, a separate gray window with
(default) white background color.
The user can create as many figure windows as the system memory will
allow.
3. Edit window:
This is where you write, edit, create, and save your own programs in files
called ‘M-files’. Y
you can use any text editor to carry out these tasks.
MATLAB provides its own built-in editor.
On-line help : On-line documentation: MATLAB provides on-line help
for all its built-in functions and programming language constructs.
The commands lookfor, help, helpwin, and helpdesk provide on-line
help.
•Dimensioning: Here, dimension statements are not required for vectors or arrays. Instead the commands are size and
length are used to know the dimension of a vector.
2. Mat-files:
• These are binary data-files created by MATLAB when we save data with the save command.
• The data is written in a special format where MATLAB only can read it
• These files can be loaded into MATLAB with the load command
3. Fig-files:
• These are binary figure files with a .fig extension
4. P-files
• These are compiled M-files with a .p extension that can be executed in MATLAB directly. **
5. Mex-files
• These are MATLAB-callable Fortran and C programs with a .mex extension to the filename
General commands you should remember
session 1: A Minimum MATLAB Session
• Goal: To learn how to log on, invoke MATLAB, do a few trivial calculations, quit MATLAB, and
log off