CS 1371 Lecture Notes - Lecture 3: Row And Column Vectors, Matlab, Delimiter

36 views2 pages

Document Summary

Input your starting value, how large you want your step to be, then the stopping value. If you do not specify your step size, matlab will assign it a value of 1. To delete a vector, set it equal to empty brackets (vec = [ ]) To preform mathematical operations on vectors, both vectors must be the same length, or one must be a scalar ( this means one must have only one element: make sure to do . * and . / like you did previously so the operation is applied to each element of the vector. The index of a data type in a vector is its relative position within the vector: indexing is when you manipulate a specific element in a vector using its index. In matlab indices start at 1 (not 0 like in other languages) This means that vec(1) refers to the first element in a vector and vec(2) refers to the second.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents