{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

quiz1 - CMPE 8 NAME Fall 2008 Quiz 1 Quiz Time 12:0512:35...

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

View Full Document Right Arrow Icon
CMPE 8 NAME: Fall 2008 Quiz 1 Quiz Time: 12:05–12:35 PM 1. (5 points) Write the Matlab commands to generate a time vector t that starts with 0.002, ends with 2, and has a sample period of 0.002. t = [0 . 002 : 0 . 002 : 2]; 2. (6 points) For the time vector t defined above, what are: a) t (3), and b) t (5)? You can just write the numeric answer. a) 0.006 b) 0.01 c) (Bonus - 2 points) What is t(end-2) ? 1.996 3. (6 points) For the time vector T , defined in Matlab as T = [ - 0 . 1 , 0 . 1 , 0 . 3 , 0 . 5 , 0 . 7 , 0 . 9 , 1 . 1]; what are: a) the end time, and b) the sample period? You can just write the numeric answer. a) 1.1 b) 0.2 c) (Bonus - 2 points) What is a short-hand way of writing T using “ : ”? T = [ - 0 . 1 : 0 . 2 : 1 . 1]; 4. (8 points) Define what a vector is, and define the dimension of a vector. A vector is a finite and ordered sequence of numbers, called elements. The dimension of a vector is the number of elements in the vector. The dimension is also known as the length of the vector. 1
Image of page 1

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

View Full Document Right Arrow Icon
5. Let the two vectors w and v be defined in Matlab as w = [ - 1 , 3 , 1 , pi ]; v = [1 , 0 , 2 , 1]; For each of the Matlab commands below, write in the output that Matlab would generate. You can leave numbers in fraction form if necessary. For a vector answer,
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern