Questions 17-21 are based on the assignemt in MATLAB: x-2.6 17) What does MATLAB
ID: 3730949 • Letter: Q
Question
Questions 17-21 are based on the assignemt in MATLAB: x-2.6 17) What does MATLAB compute with the command round(x)? c) 0 18) What does MATLAB compute with the command fix(x)? b) 1 d) -3 e) -2 a) -1 b) 1 d) -3 e) -2 19) What does MATLAB compute with the command ceil(x)? -1 -3 20) What does MATLAB compute with the command floor(x)? a) -1 b) 1 d) -3 e) -2 21) What does MATLAB compute with the command sign(x)? a) -1 b) 1 c) 0 d) -3 e) -2 22) What is the value of G for the following assignment in MATLAB: G-Izeros(3), eye(3,3)] 1 0 0 a) 0 1 0 0 0 1 1 0 0 0 1 0 0 0 1 0 00 1 0 C d) o o o 0 1 o 0 0 0 0 0 1 b) 0 0 0) e) none of the aboveExplanation / Answer
17)round rounds to nearest integer
ans d)-3
18)fix rounds to 0
ans e)-2
19)ceil rounds to nearest integer towards positive infinity
ans e)-2
20)floor rounds to the nearest integer towards negative infinity
ans d)-3
21)sign returns -1 if negative, +1 if positive,0 if 0
ans a)-1
22)zeros(3) returns a square matrix of zeros, concantenated on the right to it is an identity matrix
answer d)
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.