Unit 13 Test 02 - UNIT13/REVIEW3TEST

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
UNIT 13/ REVIEW 3 TEST 1. Briefly answer each of the following questions. a. What is the main difference between MATLAB and C++? b. What is the function of '.'(dot) operator in MATLAB? c. What are the differences between script m-files and function m-files? a) MATLAB is an interpreted language, whereas C++ is compiled language. MATLAB will run your code  until it hits a line with error, but C++ will only run if you have an error free code. b)'.' forces the math function (like power, multiplication) to happen element by element. c) The biggest difference between scripts and functions is that functions have input and output  parameters. Script files can only operate on the variables that are hard-coded into their m-file. 2. Create a 5x5 matrix with random integers between 1 and 100. Output a  vector of the remainder of the ratio between the maximum and the minimum 
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 10/02/2011 for the course ME 205 taught by Professor Koen during the Spring '07 term at University of Texas at Austin.

Page1 / 2

Unit 13 Test 02 - UNIT13/REVIEW3TEST

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online