1. Write MATLAB codes that verify the following formulae.
a. (a + b) + c = a + (b + c)
b. (a * b) * c = a * (b * c)
c. (x+y)^2= x^2+y^2+2xy
2. What do the following MATLAB functions do? Hint: You could use MATLAB help
to find out.
a. Floor (Apply floor to
SAWAR KHAN
LAB TASK#04
CU1362011C
Q1.Plot the two curves y1= x and y2= 2x on the same graph using different plot styles. Label the plot properly
Code:
x = 0:1:10;
y1 = x.^2;
subplot (1,2,1)
plot(x,y1)
xlabel('y1');
ylabel('x^2');
y2 = 2*x;
subplot (1,2,
1. Create an mfile that finds the factorial of a number [Use your class ID] using for loop
(dont use the built in function factorial). [2]
n=28
f=1;
for i=1:n
f=f*i;
end
result in command window
n =
28
> f
f =
3.0489e+029
2.
Repeat the above question for
1. Creating vectors
(a) Generate the following vectors:
A = [1 0 4 5 3 9 0 2]
a = [4 5 0 2 0 0 7 1]
Be aware that MATLAB are case sensitive. Vector A and a have different values.
(b) Generate the following vectors:
B = [A a]
C = [a, A]
Concatenation is th
VIETNAM NATIONAL UNIVERSITY, HANOI
UNIVERSITY OF ENGINEERING AND TECHNOLOGY

SOCIALIST REPUBLIC OF VIETNAM
Independence Freedom Happiness
=
EXAMINATION QUESTIONS AND EXERCISES
1. Course Information

Course title: Signals and Systems
Course ID: ELT2035
N
Slide 1: classification of signals; energy, power of signals; elementary signals
Slide 2: systems and properties,
Slide 3: differential Equation, impulse responses, statevariable models, frequency response,
Use Laplace transform to solve differential e