MATLAB The first steps. Edited by Péter Vass

Size: px
Start display at page:

Download "MATLAB The first steps. Edited by Péter Vass"

Transcription

1 MATLAB The first steps Edited by Péter Vass

2 MATLAB The name MATLAB is derived from the expression MATrix LABoratory. It is used for the identification of a software and a programming language. As a software, it provides an interactive computational and program development environment which supports its own programming language. It is a commercial software (not free and not cheap) and developed by the MathWorks Inc.

3 The basic features of MATLAB programming language It is a 4GL programming language, an interpreted programming language (the interpreter is built in the software), a domain-specific programming language (it is aimed at solving scientific and engineering problems). It supports the imperative, the structural, the procedural and the object-oriented programming. It has sophisticated data structures. It provides vast number of built-in functions for linear algebra, statistics, Fourier analysis, filtering, optimization, numerical integration and solving ordinary differential equations.

4 The basic features of MATLAB programming language These functions are collected in packages referred to as toolboxes. It provides built-in graphics for visualizing data, enables the user to create applications with graphical user interface (GUI), and also provides interfaces for programs or functions written in other languages such as C, C++, Java, and FORTRAN.

5 Matlab Integrated Development Environment (IDE) Launching the MATLAB IDE double-clicking the MATLAB shortcut on the desktop, or find the MATLAB item and click it in the start menu Panels of the MATLAB desktop (in the default layout) Current Folder Command Window Workspace Command History

6 Matlab Integrated Development Environment (IDE) Current Folder Workspace Command Window Command History

7 Matlab Integrated Development Environment (IDE) Current Folder allows us to view, open, search for folders and files, and make changes to them. Command Window provides the command prompt (>>) which indicates the position of the command line. The command to be executed must be entered here. The entered command is sent to the interpreter which tries to execute it. If the command is incorrect or some condition is not fulfilled, the interpreter sends an error message which is also displayed in this window.

8 Matlab Integrated Development Environment (IDE) Command Window Otherwise, it executes the command and the result appears in the window. The commands previously entered and the results are listed in sequence above the command line. Workspace shows some information about the variables previously created and/or read from files. Command History lists the commands previously entered in the Command Window. Any command may be recall from here and rerun in the command line by double-clicking it.

9 Matlab Integrated Development Environment (IDE) Customizing the environment Home tab Environment section Preferences

10 Matlab Integrated Development Environment (IDE) Invoking the MATLAB help browser Home tab Resources section Help icon

11 Matlab Integrated Development Environment (IDE) From the command line Type doc in the command line and press the enter key ( ). >> doc Getting information about a valid function >> help funtion_name >> doc function_name Example: >> help exit >> help quit >> doc clc >> clc Watch the content of the Command History window. >> exit

12 Matlab Integrated Development Environment (IDE) Searching help entries for all MATLAB commands linked up with a keyword >> lookfor keyword Example: >> lookfor spectrum There are different levels of working with the MATLAB environment: using it as a high-performance, complex calculator by typing and running commands one after another, writing a script which contains a series of commands arranged in suitable control structures, and is stored in a script file, then running it as a single command, writing user-defined functions for specific tasks and calling them in the command line.

13 Using MATLAB as a calculator In the simplest case, we use only numerical constants in our computation. The symbols used for the notation of basic mathematical operations (operators): + * / ^ To modify the order of operations, use ( ) Example: >> (4 + 2) / 3 The result of an executed command is stored in a special variable named ans (answer). See the content of the Workspace panel. Example: >> ans^2 Note that the value of ans has changed in the Workspace panel.

14 Using MATLAB as a calculator Other special variables for mathematical symbols: pi Inf i and j 1 (imaginary unit) Nan not a number Examples: >> pi >> -2.5/0 >> (-3) ^ 0.5 >> 2+3j * -(5+6j) >> 0/0

15 Using MATLAB as a calculator Setting the output format The default output format is the short format which displays numbers with four decimal place values. By means of the format command, the output format may be changed. Some other output format: long format displays 15 digits after the decimal point, bank format rounds numbers to two decimal places (for finantial computation), format short e displays numbers in exponential form with a base of four decimal places and the exponent, format long e displays numbers in exponential form with a base of 15 decimal places and the exponent

16 Using MATLAB as a calculator Example: >> 3 + 4/3 6^2.3 >> format long >> ans >> format bank >> ans >> format short e >> ans >> format long e >> ans >> format short >> ans

17 Using MATLAB as a calculator Editing the command line There are some useful keyboard shortcut for editing the command line such as: Esc Ctrl Ctrl recalls the previous command recalls the next command clears the command line moves the cursor one character backward moves the cursor one character forward moves the cursor one word to the left moves the cursor one word to the right

18 Using MATLAB as a calculator Editing the command line Home, End, Del and Backspace keys may also be used with their well-known functions. Variables In order to perform more complex computations, we must apply variables in our commands. A variable is a storage location in the memory which serves for keeping the value of some data, and it has an individual name. We can assign a value to it, and use its value in expressions. A variable has three main properties: its name, its type, and its value.

19 Using MATLAB as a calculator Variable assignment variable_name = value or expression Expression is a combination of different elements. It may contain: constants, variables, operators (symbols for the operations), and function calls. Examples >>x = 5 See the content of the Workspace panel. >>x = x + 2 >>y = 2*x sin(pi/4) sin() is a built-in function for implementing the mathematical sine function in MATLAB >>help sin

20 Using MATLAB as a calculator An important rule The variable assignment always has to precede the first use of the variable in a computation. So, a variable without any value cannot be used in an expression. Example >>x = 3 >>x = x + z Since the variable z has not a definite value, the expression in the last command is wrong. MATLAB cannot execute it and we get an error message.

21 Using MATLAB as a calculator Semicolon in MATLAB It may used at the end of the commands. If we use it, MATLAB will not display the output of the executed command. Example >>x = 3; >>y = x + 5 Multiple variable assignments It is possible to perform more than one variable assignment in the same command line in the following way: >> x = 3.4; y = 7.2; z = x * y

22 Using MATLAB as a calculator Naming rules of variables a variable name may contain only letters, numbers and underscore characters, the first character must be a letter, since MATLAB is case-sensitive, the capital and small forms of a letter are differentiated, although there is no limit for the length of a variable name, still only a limited number of characters from the beginning are taken into account (run the function namelengthmax). Example >>varname=5; >>VarName=8; >>varname+varname >>namelengthmax

23 Using MATLAB as a calculator Variable types MATLAB automatically determines the type of a variable whenever we assign a value or expression to it. So, we need not declare the type of any variable unlike other programming languages such as C, Pascal, Fortran, Java etc. Clear command The variables we have created during a MATLAB session are stored in the memory of the computer. It may be necessary to free some memory by erasing useless variables. Erasing variable x from the memory. >>clear x Erasing all the variable from the memory >>clear

24 MATLAB clones MATLAB is an excellent software but it is not free and not cheap. This is the reason why someone may consider trying out a free alternative of MATLAB. There are some free MATLAB clones or MATLAB-like applications such as: GNU Octave, SciLab and Rlab. The home page of Octave: The home page of Scilab: The home page of Rlab: Octave is the most compatible with MATLAB of all the clones.

25 Octave MATLAB is an excellent software but it is not free and not cheap. This is the reason why someone may consider trying out a free alternative of MATLAB. There are some free MATLAB clones or MATLAB-like software such as: GNU Octave, SciLab and Rlab. The home page of Octave: The home page of Scilab: The home page of Rlab: Octave is the most compatible with MATLAB of all the clones.

26 Graphical User Interface (GUI) of Octave Launching Octave double-click the Octave (GUI) shortcut on the desktop, or find the Octave item and click it in the start menu Panels of the Octave desktop (in the default layout) File Browser Command Window Workspace Command History

27 Graphical User Interface (GUI) of Octave File Browser Workspace Command Window Command History

28 Graphical User Interface (GUI) of Octave Setting the current directory (or folder) The selection of the current directory is important when we want to read data from files or save data into files or run our own scripts or call our own functions. The path of the current directory is displayed on the right side of the toolbar. We can take a step upwards in the directory system by clicking the green upwards arrow (One directory up). We can directly select any path by clicking the rightmost blue open folder icon. This action invokes a common dialog window "Browse directories". If the current directory has been changed, the content of the selected directory will be displayed in the "File Browser" window.

29 References

General Information. There are certain MATLAB features you should be aware of before you begin working with MATLAB.

General Information. There are certain MATLAB features you should be aware of before you begin working with MATLAB. Introduction to MATLAB 1 General Information Once you initiate the MATLAB software, you will see the MATLAB logo appear and then the MATLAB prompt >>. The prompt >> indicates that MATLAB is awaiting a

More information

An Introduction to MATLAB See Chapter 1 of Gilat

An Introduction to MATLAB See Chapter 1 of Gilat 1 An Introduction to MATLAB See Chapter 1 of Gilat Kipp Martin University of Chicago Booth School of Business January 25, 2012 Outline The MATLAB IDE MATLAB is an acronym for Matrix Laboratory. It was

More information

Starting MATLAB To logon onto a Temple workstation at the Tech Center, follow the directions below.

Starting MATLAB To logon onto a Temple workstation at the Tech Center, follow the directions below. What is MATLAB? MATLAB (short for MATrix LABoratory) is a language for technical computing, developed by The Mathworks, Inc. (A matrix is a rectangular array or table of usually numerical values.) MATLAB

More information

2.0 MATLAB Fundamentals

2.0 MATLAB Fundamentals 2.0 MATLAB Fundamentals 2.1 INTRODUCTION MATLAB is a computer program for computing scientific and engineering problems that can be expressed in mathematical form. The name MATLAB stands for MATrix LABoratory,

More information

Chapter 1: An Overview of MATLAB

Chapter 1: An Overview of MATLAB Chapter 1: An Overview of MATLAB MATLAB is: A high-level language and interactive environment for numerical computation, visualization, and programming MATLAB can: Be used as a calculator, easily create

More information

PROGRAMMING WITH MATLAB DR. AHMET AKBULUT

PROGRAMMING WITH MATLAB DR. AHMET AKBULUT PROGRAMMING WITH MATLAB DR. AHMET AKBULUT OVERVIEW WEEK 1 What is MATLAB? A powerful software tool: Scientific and engineering computations Signal processing Data analysis and visualization Physical system

More information

Dr Richard Greenaway

Dr Richard Greenaway SCHOOL OF PHYSICS, ASTRONOMY & MATHEMATICS 4PAM1008 MATLAB 2 Basic MATLAB Operation Dr Richard Greenaway 2 Basic MATLAB Operation 2.1 Overview 2.1.1 The Command Line In this Workshop you will learn how

More information

Outline. CSE 1570 Interacting with MATLAB. Outline. Starting MATLAB. MATLAB Windows. MATLAB Desktop Window. Instructor: Aijun An.

Outline. CSE 1570 Interacting with MATLAB. Outline. Starting MATLAB. MATLAB Windows. MATLAB Desktop Window. Instructor: Aijun An. CSE 10 Interacting with MATLAB Instructor: Aijun An Department of Computer Science and Engineering York University aan@cse.yorku.ca Outline Starting MATLAB MATLAB Windows Using the Command Window Some

More information

Outline. CSE 1570 Interacting with MATLAB. Starting MATLAB. Outline (Cont d) MATLAB Windows. MATLAB Desktop Window. Instructor: Aijun An

Outline. CSE 1570 Interacting with MATLAB. Starting MATLAB. Outline (Cont d) MATLAB Windows. MATLAB Desktop Window. Instructor: Aijun An CSE 170 Interacting with MATLAB Instructor: Aijun An Department of Computer Science and Engineering York University aan@cse.yorku.ca Outline Starting MATLAB MATLAB Windows Using the Command Window Some

More information

Introduction to MATLAB

Introduction to MATLAB to MATLAB Spring 2019 to MATLAB Spring 2019 1 / 39 The Basics What is MATLAB? MATLAB Short for Matrix Laboratory matrix data structures are at the heart of programming in MATLAB We will consider arrays

More information

Introduction to Engineering gii

Introduction to Engineering gii 25.108 Introduction to Engineering gii Dr. Jay Weitzen Lecture Notes I: Introduction to Matlab from Gilat Book MATLAB - Lecture # 1 Starting with MATLAB / Chapter 1 Topics Covered: 1. Introduction. 2.

More information

General MATLAB Information 1

General MATLAB Information 1 Introduction to MATLAB General MATLAB Information 1 Once you initiate the MATLAB software, you will see the MATLAB logo appear and then the MATLAB prompt >>. The prompt >> indicates that MATLAB is awaiting

More information

Computer Programming in MATLAB

Computer Programming in MATLAB Computer Programming in MATLAB Prof. Dr. İrfan KAYMAZ Atatürk University Engineering Faculty Department of Mechanical Engineering What is a computer??? Computer is a device that computes, especially a

More information

Outline. CSE 1570 Interacting with MATLAB. Starting MATLAB. Outline. MATLAB Windows. MATLAB Desktop Window. Instructor: Aijun An.

Outline. CSE 1570 Interacting with MATLAB. Starting MATLAB. Outline. MATLAB Windows. MATLAB Desktop Window. Instructor: Aijun An. CSE 170 Interacting with MATLAB Instructor: Aijun An Department of Computer Science and Engineering York University aan@cse.yorku.ca Outline Starting MATLAB MATLAB Windows Using the Command Window Some

More information

Variables are used to store data (numbers, letters, etc) in MATLAB. There are a few rules that must be followed when creating variables in MATLAB:

Variables are used to store data (numbers, letters, etc) in MATLAB. There are a few rules that must be followed when creating variables in MATLAB: Contents VARIABLES... 1 Storing Numerical Data... 2 Limits on Numerical Data... 6 Storing Character Strings... 8 Logical Variables... 9 MATLAB S BUILT-IN VARIABLES AND FUNCTIONS... 9 GETTING HELP IN MATLAB...

More information

MATLAB. Miran H. S. Mohammed. Lecture 1

MATLAB. Miran H. S. Mohammed. Lecture 1 MATLAB Miran H. S. Mohammed 1 Lecture 1 OUTLINES Introduction Why using MATLAB Installing MATLAB Activate your installation Getting started Some useful command Using MATLAB as a calculator 2 INTRODUCTION

More information

MATLAB Project: Getting Started with MATLAB

MATLAB Project: Getting Started with MATLAB Name Purpose: To learn to create matrices and use various MATLAB commands for reference later MATLAB built-in functions used: [ ] : ; + - * ^, size, help, format, eye, zeros, ones, diag, rand, round, cos,

More information

ENGR 1181 MATLAB 05: Input and Output

ENGR 1181 MATLAB 05: Input and Output ENGR 1181 MATLAB 05: Input and Output Learning Objectives 1. Create a basic program that can be used over and over or given to another person to use 2. Demonstrate proper use of the input command, which

More information

Chapter 1 Introduction to MATLAB

Chapter 1 Introduction to MATLAB Chapter 1 Introduction to MATLAB 1.1 What is MATLAB? MATLAB = MATrix LABoratory, the language of technical computing, modeling and simulation, data analysis and processing, visualization and graphics,

More information

SECTION 1: INTRODUCTION. ENGR 112 Introduction to Engineering Computing

SECTION 1: INTRODUCTION. ENGR 112 Introduction to Engineering Computing SECTION 1: INTRODUCTION ENGR 112 Introduction to Engineering Computing 2 Course Overview What is Programming? 3 Programming The implementation of algorithms in a particular computer programming language

More information

the Enter or Return key. To perform a simple computations type a command and next press the

the Enter or Return key. To perform a simple computations type a command and next press the Edward Neuman Department of Mathematics Southern Illinois University at Carbondale edneuman@siu.edu The purpose of this tutorial is to present basics of MATLAB. We do not assume any prior knowledge of

More information

Edward Neuman Department of Mathematics Southern Illinois University at Carbondale

Edward Neuman Department of Mathematics Southern Illinois University at Carbondale Edward Neuman Department of Mathematics Southern Illinois University at Carbondale edneuman@siu.edu The purpose of this tutorial is to present basics of MATLAB. We do not assume any prior knowledge of

More information

Welcome to EGR 106 Foundations of Engineering II

Welcome to EGR 106 Foundations of Engineering II Welcome to EGR 106 Foundations of Engineering II Course information Today s specific topics: Computation and algorithms MATLAB Basics Demonstrations Material in textbook chapter 1 Computation What is computation?

More information

VARIABLES Storing numbers:

VARIABLES Storing numbers: VARIABLES Storing numbers: You may create and use variables in Matlab to store data. There are a few rules on naming variables though: (1) Variables must begin with a letter and can be followed with any

More information

MATLAB Programming for Numerical Computation Dr. Niket Kaisare Department Of Chemical Engineering Indian Institute of Technology, Madras

MATLAB Programming for Numerical Computation Dr. Niket Kaisare Department Of Chemical Engineering Indian Institute of Technology, Madras MATLAB Programming for Numerical Computation Dr. Niket Kaisare Department Of Chemical Engineering Indian Institute of Technology, Madras Module No. #01 Lecture No. #1.1 Introduction to MATLAB programming

More information

Introduction to MATLAB

Introduction to MATLAB Chapter 1 Introduction to MATLAB 1.1 Software Philosophy Matrix-based numeric computation MATrix LABoratory built-in support for standard matrix and vector operations High-level programming language Programming

More information

Starting Matlab. MATLAB Laboratory 09/09/10 Lecture. Command Window. Drives/Directories. Go to.

Starting Matlab. MATLAB Laboratory 09/09/10 Lecture. Command Window. Drives/Directories. Go to. Starting Matlab Go to MATLAB Laboratory 09/09/10 Lecture Lisa A. Oberbroeckling Loyola University Maryland loberbroeckling@loyola.edu http://ctx.loyola.edu and login with your Loyola name and password...

More information

Getting Started. Chapter 1. How to Get Matlab. 1.1 Before We Begin Matlab to Accompany Lay s Linear Algebra Text

Getting Started. Chapter 1. How to Get Matlab. 1.1 Before We Begin Matlab to Accompany Lay s Linear Algebra Text Chapter 1 Getting Started How to Get Matlab Matlab physically resides on each of the computers in the Olin Hall labs. See your instructor if you need an account on these machines. If you are going to go

More information

Matlab = Matrix Laboratory. It is designed to be great at handling matrices.

Matlab = Matrix Laboratory. It is designed to be great at handling matrices. INTRODUCTION: Matlab = Matrix Laboratory. It is designed to be great at handling matrices. Matlab is a high-level language and interactive environment. You write simple ASCII text that is translated into

More information

Part #1. A0B17MTB Matlab. Miloslav Čapek Filip Kozák, Viktor Adler, Pavel Valtr

Part #1. A0B17MTB Matlab. Miloslav Čapek Filip Kozák, Viktor Adler, Pavel Valtr A0B17MTB Matlab Part #1 Miloslav Čapek miloslav.capek@fel.cvut.cz Filip Kozák, Viktor Adler, Pavel Valtr Department of Electromagnetic Field B2-626, Prague You will learn Scalars, vectors, matrices (class

More information

Lecture 1: What is MATLAB?

Lecture 1: What is MATLAB? Lecture 1: What is MATLAB? Dr. Mohammed Hawa Electrical Engineering Department University of Jordan EE201: Computer Applications. See Textbook Chapter 1. MATLAB MATLAB (MATrix LABoratory) is a numerical

More information

Introduction to MATLAB

Introduction to MATLAB ELG 3125 - Lab 1 Introduction to MATLAB TA: Chao Wang (cwang103@site.uottawa.ca) 2008 Fall ELG 3125 Signal and System Analysis P. 1 Do You Speak MATLAB? MATLAB - The Language of Technical Computing ELG

More information

MATLAB Project: Getting Started with MATLAB

MATLAB Project: Getting Started with MATLAB Name Purpose: To learn to create matrices and use various MATLAB commands for reference later MATLAB functions used: [ ] : ; + - * ^, size, help, format, eye, zeros, ones, diag, rand, round, cos, sin,

More information

AMS 27L LAB #1 Winter 2009

AMS 27L LAB #1 Winter 2009 AMS 27L LAB #1 Winter 2009 Introduction to MATLAB Objectives: 1. To introduce the use of the MATLAB software package 2. To learn elementary mathematics in MATLAB Getting Started: Log onto your machine

More information

Introduction to Matlab. By: Dr. Maher O. EL-Ghossain

Introduction to Matlab. By: Dr. Maher O. EL-Ghossain Introduction to Matlab By: Dr. Maher O. EL-Ghossain Outline: q What is Matlab? Matlab Screen Variables, array, matrix, indexing Operators (Arithmetic, relational, logical ) Display Facilities Flow Control

More information

Introduction to MATLAB

Introduction to MATLAB Introduction to MATLAB The Desktop When you start MATLAB, the desktop appears, containing tools (graphical user interfaces) for managing files, variables, and applications associated with MATLAB. The following

More information

MAT 275 Laboratory 1 Introduction to MATLAB

MAT 275 Laboratory 1 Introduction to MATLAB MATLAB sessions: Laboratory 1 1 MAT 275 Laboratory 1 Introduction to MATLAB MATLAB is a computer software commonly used in both education and industry to solve a wide range of problems. This Laboratory

More information

Introduction to Matlab to Accompany Linear Algebra. Douglas Hundley Department of Mathematics and Statistics Whitman College

Introduction to Matlab to Accompany Linear Algebra. Douglas Hundley Department of Mathematics and Statistics Whitman College Introduction to Matlab to Accompany Linear Algebra Douglas Hundley Department of Mathematics and Statistics Whitman College August 27, 2018 2 Contents 1 Getting Started 5 1.1 Before We Begin........................................

More information

MATLAB Basics EE107: COMMUNICATION SYSTEMS HUSSAIN ELKOTBY

MATLAB Basics EE107: COMMUNICATION SYSTEMS HUSSAIN ELKOTBY MATLAB Basics EE107: COMMUNICATION SYSTEMS HUSSAIN ELKOTBY What is MATLAB? MATLAB (MATrix LABoratory) developed by The Mathworks, Inc. (http://www.mathworks.com) Key Features: High-level language for numerical

More information

Why use MATLAB? Mathematcal computations. Used a lot for problem solving. Statistical Analysis (e.g., mean, min) Visualisation (1D-3D)

Why use MATLAB? Mathematcal computations. Used a lot for problem solving. Statistical Analysis (e.g., mean, min) Visualisation (1D-3D) MATLAB(motivation) Why use MATLAB? Mathematcal computations Used a lot for problem solving Statistical Analysis (e.g., mean, min) Visualisation (1D-3D) Signal processing (Fourier transform, etc.) Image

More information

Introduction to MATLAB

Introduction to MATLAB Introduction to MATLAB 1 Introduction to MATLAB A Tutorial for the Course Computational Intelligence http://www.igi.tugraz.at/lehre/ci Stefan Häusler Institute for Theoretical Computer Science Inffeldgasse

More information

Desktop Command window

Desktop Command window Chapter 1 Matlab Overview EGR1302 Desktop Command window Current Directory window Tb Tabs to toggle between Current Directory & Workspace Windows Command History window 1 Desktop Default appearance Command

More information

INTRODUCTION TO MATLAB, SIMULINK, AND THE COMMUNICATION TOOLBOX

INTRODUCTION TO MATLAB, SIMULINK, AND THE COMMUNICATION TOOLBOX INTRODUCTION TO MATLAB, SIMULINK, AND THE COMMUNICATION TOOLBOX 1) Objective The objective of this lab is to review how to access Matlab, Simulink, and the Communications Toolbox, and to become familiar

More information

Computer Programming ECIV 2303 Chapter 1 Starting with MATLAB Instructor: Dr. Talal Skaik Islamic University of Gaza Faculty of Engineering

Computer Programming ECIV 2303 Chapter 1 Starting with MATLAB Instructor: Dr. Talal Skaik Islamic University of Gaza Faculty of Engineering Computer Programming ECIV 2303 Chapter 1 Starting with MATLAB Instructor: Dr. Talal Skaik Islamic University of Gaza Faculty of Engineering 1 Introduction 2 Chapter l Starting with MATLAB This chapter

More information

Variable Definition and Statement Suppression You can create your own variables, and assign them values using = >> a = a = 3.

Variable Definition and Statement Suppression You can create your own variables, and assign them values using = >> a = a = 3. MATLAB Introduction Accessing Matlab... Matlab Interface... The Basics... 2 Variable Definition and Statement Suppression... 2 Keyboard Shortcuts... More Common Functions... 4 Vectors and Matrices... 4

More information

MATLAB BASICS. M Files. Objectives

MATLAB BASICS. M Files. Objectives Objectives MATLAB BASICS 1. What is MATLAB and why has it been selected to be the tool of choice for DIP? 2. What programming environment does MATLAB offer? 3. What are M-files? 4. What is the difference

More information

Introduction to Scientific Computing with Matlab

Introduction to Scientific Computing with Matlab UNIVERSITY OF WATERLOO Introduction to Scientific Computing with Matlab SAW Training Course R. William Lewis Computing Consultant Client Services Information Systems & Technology 2007 Table of Contents

More information

MATLAB Introduction to MATLAB Programming

MATLAB Introduction to MATLAB Programming MATLAB Introduction to MATLAB Programming MATLAB Scripts So far we have typed all the commands in the Command Window which were executed when we hit Enter. Although every MATLAB command can be executed

More information

YOGYAKARTA STATE UNIVERSITY MATHEMATICS AND NATURAL SCIENCES FACULTY MATHEMATICS EDUCATION STUDY PROGRAM

YOGYAKARTA STATE UNIVERSITY MATHEMATICS AND NATURAL SCIENCES FACULTY MATHEMATICS EDUCATION STUDY PROGRAM YOGYAKARTA STATE UNIVERSITY MATHEMATICS AND NATURAL SCIENCES FACULTY MATHEMATICS EDUCATION STUDY PROGRAM TOPIC 1 INTRODUCING SOME MATHEMATICS SOFTWARE (Matlab, Maple and Mathematica) This topic provides

More information

EGR 111 Introduction to MATLAB

EGR 111 Introduction to MATLAB EGR 111 Introduction to MATLAB This lab introduces the MATLAB help facility, shows how MATLAB TM, which stands for MATrix LABoratory, can be used as an advanced calculator. This lab also introduces assignment

More information

Matlab Programming MET 164 1/24

Matlab Programming MET 164 1/24 Matlab Programming 1/24 2/24 What does MATLAB mean? Contraction of Matrix Laboratory Matrices are rectangular arrays of numerical values 7 3 6 2 1 9 4 4 8 4 1 5 7 2 1 3 What are the fundamental components

More information

What is MATLAB? It is a high-level programming language. for numerical computations for symbolic computations for scientific visualizations

What is MATLAB? It is a high-level programming language. for numerical computations for symbolic computations for scientific visualizations What is MATLAB? It stands for MATrix LABoratory It is developed by The Mathworks, Inc (http://www.mathworks.com) It is an interactive, integrated, environment for numerical computations for symbolic computations

More information

Introduction to MATLAB

Introduction to MATLAB Introduction to MATLAB Contents 1.1 Objectives... 1 1.2 Lab Requirement... 1 1.3 Background of MATLAB... 1 1.4 The MATLAB System... 1 1.5 Start of MATLAB... 3 1.6 Working Modes of MATLAB... 4 1.7 Basic

More information

MATLAB Introductory Course Computer Exercise Session

MATLAB Introductory Course Computer Exercise Session MATLAB Introductory Course Computer Exercise Session This course is a basic introduction for students that did not use MATLAB before. The solutions will not be collected. Work through the course within

More information

Finding, Starting and Using Matlab

Finding, Starting and Using Matlab Variables and Arrays Finding, Starting and Using Matlab CSC March 6 &, 9 Array: A collection of data values organized into rows and columns, and known by a single name. arr(,) Row Row Row Row 4 Col Col

More information

WHAT IS MATLAB?... 1 STARTING MATLAB & USING THE COMMAND LINE... 1 BASIC ARITHMETIC OPERATIONS... 5 ORDER OF OPERATIONS... 7

WHAT IS MATLAB?... 1 STARTING MATLAB & USING THE COMMAND LINE... 1 BASIC ARITHMETIC OPERATIONS... 5 ORDER OF OPERATIONS... 7 Contents WHAT IS MATLAB?... 1 STARTING MATLAB & USING THE COMMAND LINE... 1 BASIC ARITHMETIC OPERATIONS... 5 ORDER OF OPERATIONS... 7 WHAT IS MATLAB? MATLAB stands for MATrix LABoratory. It is designed

More information

CSCI 6906: Fundamentals of Computational Neuroimaging. Thomas P. Trappenberg Dalhousie University

CSCI 6906: Fundamentals of Computational Neuroimaging. Thomas P. Trappenberg Dalhousie University CSCI 6906: Fundamentals of Computational Neuroimaging Thomas P. Trappenberg Dalhousie University 1 Programming with Matlab This chapter is a brief introduction to programming with the Matlab programming

More information

MATLAB Lesson I. Chiara Lelli. October 2, Politecnico di Milano

MATLAB Lesson I. Chiara Lelli. October 2, Politecnico di Milano MATLAB Lesson I Chiara Lelli Politecnico di Milano October 2, 2012 MATLAB MATLAB (MATrix LABoratory) is an interactive software system for: scientific computing statistical analysis vector and matrix computations

More information

Matlab Programming Introduction 1 2

Matlab Programming Introduction 1 2 Matlab Programming Introduction 1 2 Mili I. Shah August 10, 2009 1 Matlab, An Introduction with Applications, 2 nd ed. by Amos Gilat 2 Matlab Guide, 2 nd ed. by D. J. Higham and N. J. Higham Starting Matlab

More information

Introduction to Scientific and Engineering Computing, BIL108E. Karaman

Introduction to Scientific and Engineering Computing, BIL108E. Karaman USING MATLAB INTRODUCTION TO SCIENTIFIC & ENGINEERING COMPUTING BIL 108E, CRN24023 To start from Windows, Double click the Matlab icon. To start from UNIX, Dr. S. Gökhan type matlab at the shell prompt.

More information

MAT 343 Laboratory 1 Matrix and Vector Computations in MATLAB

MAT 343 Laboratory 1 Matrix and Vector Computations in MATLAB MAT 343 Laboratory 1 Matrix and Vector Computations in MATLAB MATLAB is a computer software commonly used in both education and industry to solve a wide range of problems. This Laboratory provides a brief

More information

MAT 343 Laboratory 1 Matrix and Vector Computations in MATLAB

MAT 343 Laboratory 1 Matrix and Vector Computations in MATLAB MAT 343 Laboratory 1 Matrix and Vector Computations in MATLAB In this laboratory session we will learn how to 1. Create matrices and vectors. 2. Manipulate matrices and create matrices of special types

More information

Introduction to Scientific Computing with Matlab

Introduction to Scientific Computing with Matlab Introduction to Scientific Computing with Matlab Matlab is an interactive system for numerical computations. It is widely used in universities and industry, and has many advantages over languages such

More information

Lab of COMP 406. MATLAB: Quick Start. Lab tutor : Gene Yu Zhao Mailbox: or Lab 1: 11th Sep, 2013

Lab of COMP 406. MATLAB: Quick Start. Lab tutor : Gene Yu Zhao Mailbox: or Lab 1: 11th Sep, 2013 Lab of COMP 406 MATLAB: Quick Start Lab tutor : Gene Yu Zhao Mailbox: csyuzhao@comp.polyu.edu.hk or genexinvivian@gmail.com Lab 1: 11th Sep, 2013 1 Where is Matlab? Find the Matlab under the folder 1.

More information

ECE Lesson Plan - Class 1 Fall, 2001

ECE Lesson Plan - Class 1 Fall, 2001 ECE 201 - Lesson Plan - Class 1 Fall, 2001 Software Development Philosophy Matrix-based numeric computation - MATrix LABoratory High-level programming language - Programming data type specification not

More information

Introduction to Matlab. Summer School CEA-EDF-INRIA 2011 of Numerical Analysis

Introduction to Matlab. Summer School CEA-EDF-INRIA 2011 of Numerical Analysis Introduction to Matlab 1 Outline What is Matlab? Matlab desktop & interface Scalar variables Vectors and matrices Exercise 1 Booleans Control structures File organization User defined functions Exercise

More information

UNIVERSITI TEKNIKAL MALAYSIA MELAKA FAKULTI KEJURUTERAAN ELEKTRONIK DAN KEJURUTERAAN KOMPUTER

UNIVERSITI TEKNIKAL MALAYSIA MELAKA FAKULTI KEJURUTERAAN ELEKTRONIK DAN KEJURUTERAAN KOMPUTER UNIVERSITI TEKNIKAL MALAYSIA MELAKA FAKULTI KEJURUTERAAN ELEKTRONIK DAN KEJURUTERAAN KOMPUTER FAKULTI KEJURUTERAAN ELEKTRONIK DAN KEJURUTERAAN KOMPUTER BENC 2113 DENC ECADD 2532 ECADD LAB SESSION 6/7 LAB

More information

QUICKBOOKS PRO 2008 AN INTRODUCTION TO QUICKBOOKS PRO

QUICKBOOKS PRO 2008 AN INTRODUCTION TO QUICKBOOKS PRO QUICKBOOKS PRO 2008 AN INTRODUCTION TO QUICKBOOKS PRO Opening a Company Database 1. To change the open company in QuickBooks, click File on the main menu and select Open or Restore Company. When the next

More information

1 Ctrl + X Cut the selected item. 2 Ctrl + C (or Ctrl + Insert) Copy the selected item. 3 Ctrl + V (or Shift + Insert) Paste the selected item

1 Ctrl + X Cut the selected item. 2 Ctrl + C (or Ctrl + Insert) Copy the selected item. 3 Ctrl + V (or Shift + Insert) Paste the selected item Tips and Tricks Recorder Actions Library XPath Syntax Hotkeys Windows Hotkeys General Keyboard Shortcuts Windows Explorer Shortcuts Command Prompt Shortcuts Dialog Box Keyboard Shortcuts Excel Hotkeys

More information

Introduction to MATLAB. Simon O Keefe Non-Standard Computation Group

Introduction to MATLAB. Simon O Keefe Non-Standard Computation Group Introduction to MATLAB Simon O Keefe Non-Standard Computation Group sok@cs.york.ac.uk Content n An introduction to MATLAB n The MATLAB interfaces n Variables, vectors and matrices n Using operators n Using

More information

4 VISUAL FOXPRO - AN INTRODUCTION

4 VISUAL FOXPRO - AN INTRODUCTION Visual FoxPro - An Introduction:: 33 4 VISUAL FOXPRO - AN INTRODUCTION 4.1 INTRODUCTION Visual FoxPro is a Relational Database Management System (RDBMS), which allows you to work with several logically

More information

Matlab as a calculator

Matlab as a calculator Why Matlab? Matlab is an interactive, high-level, user-friendly programming and visualization environment. It allows much faster programs development in comparison with the traditional low-level compiled

More information

An Introduction to Matlab5

An Introduction to Matlab5 An Introduction to Matlab5 Phil Spector Statistical Computing Facility University of California, Berkeley August 21, 2006 1 Background Matlab was originally developed as a simple interface to the LINPACK

More information

Numerical Analysis First Term Dr. Selcuk CANKURT

Numerical Analysis First Term Dr. Selcuk CANKURT ISHIK UNIVERSITY FACULTY OF ENGINEERING and DEPARTMENT OF COMPUTER ENGINEERING Numerical Analysis 2017-2018 First Term Dr. Selcuk CANKURT selcuk.cankurt@ishik.edu.iq Textbook Main Textbook MATLAB for Engineers,

More information

Dr Richard Greenaway

Dr Richard Greenaway SCHOOL OF PHYSICS, ASTRONOMY & MATHEMATICS 4PAM1008 MATLAB 1 Introduction to MATLAB Dr Richard Greenaway 1 Introduction to MATLAB 1.1 What is MATLAB? MATLAB is a high-level technical computing language

More information

Computer Project: Getting Started with MATLAB

Computer Project: Getting Started with MATLAB Computer Project: Getting Started with MATLAB Name Purpose: To learn to create matrices and use various MATLAB commands. Examples here can be useful for reference later. MATLAB functions: [ ] : ; + - *

More information

Laboratory 1 Octave Tutorial

Laboratory 1 Octave Tutorial Signals, Spectra and Signal Processing Laboratory 1 Octave Tutorial 1.1 Introduction The purpose of this lab 1 is to become familiar with the GNU Octave 2 software environment. 1.2 Octave Review All laboratory

More information

An Introduction to MATLAB. Lab tutor : Dennis Yang LIU Lab 1: Sept. 11, 2014

An Introduction to MATLAB. Lab tutor : Dennis Yang LIU   Lab 1: Sept. 11, 2014 Lab 1 of COMP 319 An Introduction to MATLAB Lab tutor : Dennis Yang LIU Email: csygliu@comp.polyu.edu.hk Lab 1: Sept. 11, 2014 1 Outline of Lab 1 Introduction to the Lab Matlab overview Basic manipulation

More information

MATLAB Part 1. Introduction

MATLAB Part 1. Introduction MATLAB Part 1 Introduction MATLAB is problem solving environment which provides engineers and scientists an easy-to-use platform for a wide range of computational problems. In general, it is useful for

More information

Getting Started with MATLAB

Getting Started with MATLAB Getting Started with MATLAB Math 315, Fall 2003 Matlab is an interactive system for numerical computations. It is widely used in universities and industry, and has many advantages over languages such as

More information

ECON 502 INTRODUCTION TO MATLAB Nov 9, 2007 TA: Murat Koyuncu

ECON 502 INTRODUCTION TO MATLAB Nov 9, 2007 TA: Murat Koyuncu ECON 502 INTRODUCTION TO MATLAB Nov 9, 2007 TA: Murat Koyuncu 0. What is MATLAB? 1 MATLAB stands for matrix laboratory and is one of the most popular software for numerical computation. MATLAB s basic

More information

ELEMENTARY MATLAB PROGRAMMING

ELEMENTARY MATLAB PROGRAMMING 1 ELEMENTARY MATLAB PROGRAMMING (Version R2013a used here so some differences may be encountered) COPYRIGHT Irving K. Robbins 1992, 1998, 2014, 2015 All rights reserved INTRODUCTION % It is assumed the

More information

SMS 3515: Scientific Computing Lecture 1: Introduction to Matlab 2014

SMS 3515: Scientific Computing Lecture 1: Introduction to Matlab 2014 SMS 3515: Scientific Computing Lecture 1: Introduction to Matlab 2014 Instructor: Nurul Farahain Mohammad 1 It s all about MATLAB What is MATLAB? MATLAB is a mathematical and graphical software package

More information

PEACHTREE COMPLETE 2008 AN INTRODUCTION TO PEACHTREE COMPLETE ACCOUNTING

PEACHTREE COMPLETE 2008 AN INTRODUCTION TO PEACHTREE COMPLETE ACCOUNTING PEACHTREE COMPLETE 2008 AN INTRODUCTION TO PEACHTREE COMPLETE ACCOUNTING Opening a Company Database To change the open company in Peachtree, click File on the main menu and select Open Company. If the

More information

Chapter 1 Introduction to MATLAB

Chapter 1 Introduction to MATLAB EGR115 Introduction to Computing for Engineers Introduction to MATLAB from: S.J. Chapman, MATLAB Programming for Engineers, 5 th Ed. 2016 Cengage Learning Topics Introduction: Computing for Engineers 1.1

More information

Standardized Tests: Best Practices for the TI-Nspire CX

Standardized Tests: Best Practices for the TI-Nspire CX The role of TI technology in the classroom is intended to enhance student learning and deepen understanding. However, efficient and effective use of graphing calculator technology on high stakes tests

More information

McTutorial: A MATLAB Tutorial

McTutorial: A MATLAB Tutorial McGill University School of Computer Science Sable Research Group McTutorial: A MATLAB Tutorial Lei Lopez Last updated: August 2014 w w w. s a b l e. m c g i l l. c a Contents 1 MATLAB BASICS 3 1.1 MATLAB

More information

LAB 1 General MATLAB Information 1

LAB 1 General MATLAB Information 1 LAB 1 General MATLAB Information 1 General: To enter a matrix: > type the entries between square brackets, [...] > enter it by rows with elements separated by a space or comma > rows are terminated by

More information

Windows Computer A to Z Shortcut Key list with PDF

Windows Computer A to Z Shortcut Key list with PDF Windows Computer A to Z Shortcut Key list with PDF In the Computer world, a keyboard shortcut is a combination of one or more command to execute a particular action. These shortcuts are really helpful

More information

Python Programming Exercises 1

Python Programming Exercises 1 Python Programming Exercises 1 Notes: throughout these exercises >>> preceeds code that should be typed directly into the Python interpreter. To get the most out of these exercises, don t just follow them

More information

A Brief Introduction to MATLAB

A Brief Introduction to MATLAB A Brief Introduction to MATLAB MATLAB (Matrix Laboratory) is an interactive software system for numerical computations and graphics. As the name suggests, MATLAB was first designed for matrix computations:

More information

MATLAB Basics. Configure a MATLAB Package 6/7/2017. Stanley Liang, PhD York University. Get a MATLAB Student License on Matworks

MATLAB Basics. Configure a MATLAB Package 6/7/2017. Stanley Liang, PhD York University. Get a MATLAB Student License on Matworks MATLAB Basics Stanley Liang, PhD York University Configure a MATLAB Package Get a MATLAB Student License on Matworks Visit MathWorks at https://www.mathworks.com/ It is recommended signing up with a student

More information

Introduction to MATLAB Programming

Introduction to MATLAB Programming Introduction to MATLAB Programming Arun A. Balakrishnan Asst. Professor Dept. of AE&I, RSET Overview 1 Overview 2 Introduction 3 Getting Started 4 Basics of Programming Overview 1 Overview 2 Introduction

More information

ME 1020 Engineering Programming with MATLAB. Chapter 1 In-Class Assignment: 1.1, 1.3, 1.13, Topics Covered:

ME 1020 Engineering Programming with MATLAB. Chapter 1 In-Class Assignment: 1.1, 1.3, 1.13, Topics Covered: ME 1020 Engineering Programming with MATLAB Chapter 1 In-Class Assignment: 1.1, 1.3, 1.13, 1.16 Topics Covered: Use MATLAB as a calculator Save files to folders and open files from folders Create row vector

More information

The QuickCalc BASIC User Interface

The QuickCalc BASIC User Interface The QuickCalc BASIC User Interface Running programs in the Windows Graphic User Interface (GUI) mode. The GUI mode is far superior to running in the CONSOLE mode. The most-used functions are on buttons,

More information

VISUAL FOXPRO AN INTRODUCTION

VISUAL FOXPRO AN INTRODUCTION 4.1 INTRODUCTION VISUAL FOXPRO AN INTRODUCTION Visual FoxPro is a Relational Database Management System (RDBMS), which allows you to work with several logically related tables of data simultaneously. A

More information

MATLAB Tutorial. Primary Author: Shoumik Chatterjee Secondary Author: Dr. Chuan Li

MATLAB Tutorial. Primary Author: Shoumik Chatterjee Secondary Author: Dr. Chuan Li MATLAB Tutorial Primary Author: Shoumik Chatterjee Secondary Author: Dr. Chuan Li 1 Table of Contents Section 1: Accessing MATLAB using RamCloud server...3 Section 2: MATLAB GUI Basics. 6 Section 3: MATLAB

More information

Computer Shortcuts. Files menu options in current program. Edits options in current program Universal Help in almost every Windows program.

Computer Shortcuts. Files menu options in current program. Edits options in current program Universal Help in almost every Windows program. www.bankjobszone.com Computer Shortcuts Shortcut keys Concept: Shortcuts keys help provide an easier and usually quicker method of navigating and using computer software programs. Shortcut keys are commonly

More information

Introduction to Matlab

Introduction to Matlab Introduction to Matlab Weichung Wang 2003 NCTS-NSF Workshop on Differential Equations, Surface Theory, and Mathematical Visualization NCTS, Hsinchu, February 13, 2003 DE, ST, MV Workshop Matlab 1 Main

More information

INTRODUCTION... 1 UNDERSTANDING CELLS... 2 CELL CONTENT... 4

INTRODUCTION... 1 UNDERSTANDING CELLS... 2 CELL CONTENT... 4 Introduction to Microsoft Excel 2016 INTRODUCTION... 1 The Excel 2016 Environment... 1 Worksheet Views... 2 UNDERSTANDING CELLS... 2 Select a Cell Range... 3 CELL CONTENT... 4 Enter and Edit Data... 4

More information