Font size
WorksheetsMATLAB
Total questions: 101
Worksheet time: 51mins
34 25 35;
94 51 75;
40 52 55]
What is the dimension of A ?
34 25 35;
94 51 75;
40 52 55]
How many elements greater than 14 ?
34 25 35;
94 51 75;
40 52 55]
How many elements less than 14 ?
5 < 9
How to plot a graph in MATLAB
x : [value ofarray]
y : [value ofarray] plot(x, y)
x : [value ofarray];
y : [value ofarray]; plot(x, y)
x=[value ofarray];
y=[value ofarray]; plot(x, y)
x : [value ofarray]
y : [value ofarray] plot(x, y);
WHAT ARE THE SPECIAL MATRIX IN MATLAB
HILBERT MATRIX
HILBERT INVERSE MATRIX
PASCAL MATRIX
SQUARE MAGIC
TOEPLITZ MATRIX
VANDERMONDE MATRIX
EIGEN VALUE TEST MATRIX
SQUARE MATRIX
SOLVE('4-t^2=0')
(a)
A= 1 2 3
4 5 6
7 8 9
>>A(:,2)=[]
1 3
4 6
7 0
2 3
5 6
8 9
1 3
4 6
7 9
2 3
5 6
8 0
Command is used to save command window text to file
a) saveas
texttofile
diary
todiary
a = 1; sin(a) a = 2;
0.4815
0.8516
0.8415
0.4916
OUTPUT OF A = [0 1; 1 0] ; B=2 ; C = A + B
1 2
4 5
1 4
2 5
ERROR
1 2
5 4
What happens if we don’t assign a variable to an expression which evaluates a numerical value?
MATLAB shows error
values are assigned to a variable ans automatically
Depends on the numerical value
Nothing happens
What is the disadvantage of the whos function in MATLAB?
It does not show the name of the variable
It does not show the class of the variable
It does not show the size of the variable
It does not show the values of the variable
Vectors depend upon brackets while scalars don’t
TRUE
FALSE
OUTPUT OF A=[1 2 3..
];
1 2 3
A row vector concatenated with a null matrix
Error
The output is suppressed
Variables need to have same name while being passed from the primary function to the sub-function
TRUE
FALSE
FIND THE ERROR x=-10:1:10; y=-10:2:10; plot(x,y)
Length of x and y should be same
No error
Plot is not available in MATLAB
Plot x,y has no semicolon
What does the echo command do?
It shows the comments present in Script files
It shows the commands and comments in MAT-files
It echoes
It shows the commands and the comments in M-files
What is the full form for MATLAB
Matrix laboratory
Math laboratory
Matrices lab
Material Lab
Which of the following is not a tool in MATLAB
Command Window
Current Directory
Terminal
Workspace
MATLAB does numerical calculations in double precision, which is
4 & 15 digits
15digits
15 e+001
4 digits
Which of the following ,an expression shouldn't have in MATLAB
manual entry
built entry
built-in functions
user-defined function
Which of the following is not a part of MATLAB
Computation
Object Orientation
Visualization
Programming
Is MATLAB a high performing language for technical computing?
True
False
Find the output :
>>1/(2+3^4 )+4/5*6/7*7/8
0.5506
0.7680
0.8706
0.6680
The two types of prompts in MATLAB
>>> for full version
EDU>>> for educational version
>> for full version
EDU>> for educational version
<<< start>>> for full version
EDU<<<stop>>> for educational version
>> for full version
EDU> for educational version
What will print?
4 5 6
6 4 5
nothing
4 6
What will print?
nothing
4 5 6
6 5 4
4 6
What will print?
4 5 6
6 5 4
nothing
4 4 4
How many number will print?
5
3
4
0
How many numbers will print?
1
none
3
5
How many numbers will print?
3
5
0
4
How many numbers will print?
5
3
0
11
How many numbers will print?
0
5
11
15
How many letters will print?
2
1
6
5
How many numbers will print?
5
10
500
400
The common data type for numeric value(s) in MATLAB?
int
array
char
double
What is the size of an array if Arr = [9 3 5 7 10 0 16]?
7x1
7x7
1x7
7
What is the correct MATLAB command for y = 3(x+2) when x = 2?
>> y = 3*(x+2);
>> x =2;
>> y = 3(x+2);
>> x = 2;
>> x = 2;
>> y = 3*(x+2);
>> x = 2;
>> y = 3(x+2);
Rules for naming variable: All variable name must contain letters, numbers and '_'s only.
True
False
What command clears all variables in workspace browser?
clc
delete
clf
clear
MATLAB format (a) display a numeric output with fifteen significant numbers after the decimal point.
What pre-defined constant in MATLAB that represents square root of -1?
i,j
eps
NaN
ans
What is the size of the array myArr = [ 2,45,30;10,20,30]?
(a)
Inf is a pre-defined constant that is an output of an undefined mathematical operation, such as the division of 0 by 0?
True
False
What MATLAB operator that is denoted by an apostrophe, swaps the row and the column of an array?
(a)
(a) are treated as arrays with only one row and one column.
True or False: The type of data assigned to a variable determines its type when it is created
True
False
What pre-defined constant in MATLAB that is usually generated as a result of a division by zero?
NaN
eps
Inf
i,j
All the statements listed below are the advantages of MATLAB programming except for:
Interpreted Language
Ease of use
Platform independence
Graphical User Interface
The (a) command searches for an exact function name match.
True of False: The command window appears in the center of the desktop. Users enter command and see responses here.
True
False
Maybe
True or False: An array is a collection of data values organized into rows and colums.
True
False
Maybe
What is the correct MATLAB command for "Plot
y = x2−10x +15 from 0 to 10.">> x = 0:10;
>> y = x^2 - 10*x + 15;
>> plot(x,y)
>> x = [0:10];
>> y = x^2 - 10*x + 15;
>> plot(x,y)
>> y = x^2 - 10*x + 15;
>> x = 0:10;
>> plot(x,y)
>> y = x^2 - 10*x + 15;
>> x = [0:10];
>> plot(x,y)
Returns the determinant of a square matrix A using…. (a)
What will print?
4 5 6
6 4 5
nothing
4 6
What is the result of this command
3 ^ 2 * 3 ^ 2
81
36
216
6
What is the result of this command
12 < 14
1
0
12
14
Find the result of division and gives the remainder for divided 2x3+9x2+7x-6 by x+3?
ghhh
nnmmm
nnnmnm
ccvvbb
How to plot a graph in MATLAB
x : [value ofarray]
y : [value ofarray] plot(x, y)
x : [value ofarray];
y : [value ofarray]; plot(x, y)
x=[value ofarray];
y=[value ofarray]; plot(x, y)
x : [value ofarray]
y : [value ofarray] plot(x, y);
WHAT ARE THE SPECIAL MATRIX IN MATLAB
HILBERT MATRIX
HILBERT INVERSE MATRIX
PASCAL MATRIX
SQUARE MAGIC
TOEPLITZ MATRIX
VANDERMONDE MATRIX
EIGEN VALUE TEST MATRIX
SQUARE MATRIX
SOLVE('4-t^2=0')
(a)
A= 1 2 3
4 5 6
7 8 9
>>A(:,2)=[]
1 3
4 6
7 0
2 3
5 6
8 9
1 3
4 6
7 9
2 3
5 6
8 0
Command is used to save command window text to file
a) saveas
texttofile
diary
todiary
a = 1; sin(a) a = 2;
0.4815
0.8516
0.8415
0.4916
OUTPUT OF A = [0 1; 1 0] ; B=2 ; C = A + B
1 2
4 5
1 4
2 5
ERROR
1 2
5 4
What happens if we don’t assign a variable to an expression which evaluates a numerical value?
MATLAB shows error
values are assigned to a variable ans automatically
Depends on the numerical value
Nothing happens
What is the disadvantage of the whos function in MATLAB?
It does not show the name of the variable
It does not show the class of the variable
It does not show the size of the variable
It does not show the values of the variable
Vectors depend upon brackets while scalars don’t
TRUE
FALSE
OUTPUT OF A=[1 2 3..
];
1 2 3
A row vector concatenated with a null matrix
Error
The output is suppressed
Variables need to have same name while being passed from the primary function to the sub-function
TRUE
FALSE
FIND THE ERROR x=-10:1:10; y=-10:2:10; plot(x,y)
Length of x and y should be same
No error
Plot is not available in MATLAB
Plot x,y has no semicolon
What does the echo command do?
It shows the comments present in Script files
It shows the commands and comments in MAT-files
It echoes
It shows the commands and the comments in M-files
If poles of system are lying on the imaginary axis in s-plane, the system will be
Unstable
Marginally stable
Conditionally stable
Unstable
With feedback _______ increases
system stability
sensitivity
gain
effects of disturbing signals
In open loop system____
the control action depends on the size of the system
the control action depends on system variables
the control action depends on the input signal
the control action is independent of the output
Which system is also known as automatic control system?
open loop control system
Closed loop control system
both 1 & 2
None of these
Reference input minus the primary feedback is called ________ signal
Manipulated variable
Error signal
Zero signal
Primary feedback
The roots of the denominator polynomial of the transfer function are called:
ZEROS
POLES
SINGULARS
PLURALS
Transfer function is the ratio of
Laplace transform of output to input
Laplace transform of output to Laplace transform of input.
Laplace transform of output to Laplace transform of input assuming all initial condition zero.
Output to Laplace transform of input.
