ENG EK 127 Midterm: EK127 Exam 1 Ref Sheet

150 views1 pages

Document Summary

For scalars, xor 1 only if one is true]. Loose/compact(>>format loose): controls line spacing arg is true(any non-0 #), all true only if everything is true, find finds els for which an expression is true and returns their indeces, isequal(v1,v2) compares 2 arrays. Int8, int16, int32, int64 store that many bits(8 bits=1byte) & sign. Type int32 when integer is required, type char is used to store either single characters or strings, logical is used to store true(1)/false(0) values [and && or|| inf, ~=, nan(not a #) In order to multiply matrices, must have same inner dims. Scalar multiplication >>[4 0 11]*3 = 12 0 33. (same w addition) Logical vec/mat returns values where corresponding els were true. False creates mat of false(log 0) vals, true(creates mat of true(log 1) vals, any returns true if anything in input. Rand uniformly distributed real #s in interval (0,1), randn real number in interval (0,n), rand*10 a result in the open interval (0,10)

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