Question

By Using Matlab

Matcal (A, B) returns matrix A and B products, while printing
the matrix computation formula in outmat. txt file as follows. (The
sizes of A and B are very variable. In other words, it shall be
possible to perform operation for matrix operation of 2 x 2 size,
and it shall also be possible to calculate and output for 100 X 100
matrix models. )

>> A = [1 23;4 56 ; 79]

>> B = [0 0 ; 0 1 0 ; 0 1]

>> Matcal (A, B)

Ans = 1 2 3

4 5 6

79

In outmat.txt.

[1 2]x[ 0]=[123]

[4 5 6] [0 0] = [4 5 6]

[7 8 9] [0 1] = [7 8 9]

10 points if calculation results for five-to-five metrics can be
printed

5 points if only 3 x 3 is possible

Answer #1

code:

result:

result:

Write a MATLAB function that outputs number of values in a
matrix that’s greater than a compare value. The function must able
to take in an arbitrary size matrix.
Name your script/program as “Quiz 2”.
Examples :
Matrix = [1 2 3; 4 5 6]
Compare_Value
= 2
Output = 4
Matrix = [1 2 3 1; 4 5 6
8]
Compare_Value = 2
Output = 5

Using for loop and if statement, write a MATLAB code to plot a
graph for x(t) as a function of time t in the range 0 to 12 in
increment of 0.01
?(?) =
1: 0 ≤ ? ≤ 1
2? − 1 1 ≤ ? ≤ 2
3 2 ≤ ? ≤ 3
−2.5? + 10.5 3 ≤ ? ≤ 5
−2 5 ≤ ? ≤ 6
4/3 ? − 10 6 ≤ ? ≤ 9
2 9 ≤...

MATLAB:
Write a function called matrix_problem1 that
takes a matrix A of positive integers as its sole input. If the
assumption is wrong, the function returns an empty matrix.
Otherwise, the function doubles every odd element of A and returns
the resulting matrix. Notice that the output matrix will have all
even elements. For example, the call B = matrix_problem([1 4; 5 2;
3 1], will make B equal to [2 4; 10 2; 6 2]. The function should
work...

CHAPTER 2 MATLAB EXERCISES QUESTION 1:
Enter the matrices A=[0 -4 5] and B= [-5 6 7]
3 1 -2 0 -1 2
2 1 4 4 0 -3
USE MATLAB to find a) A + B
b) B - 3A
c) AB
d) BA
QUESTION 6:
ENTER THE THREE MATRICES A= [1 2 3 4] B= [4 -6 3 5]
2 3 4 5 0 -3 -6 8
3 4 5 6 3 5 0 7
4 5 6 7...

1. Complex algebra problems. You can check your answer with
Matlab: real, imag, abs, angle phase, conj. You are given:
A = 1+2j ; B = 2+1j
a. Find A*B, A/B, A^2 abs(A) and abs(B). Answers should
be simplified in (a+bj) form.
b. B in polar form (i.e. magnitude and angle in
degree)
c. Find exp(A) in polar and rectangular form. Hint use
Euler formula.
2. Matrix operation problems. Use Matlab: A = [1 2 3; 4 5 6; 7...

Apply the row operation R1 + 2R3 → R1 on the following
matrix:
2 −3 1 4
2 0 6 −5
1 −1 1 0
−→
(h) True or False: The point (2, 1) is in the following feasible
region:
x + 2y ≤ 5, 5x − 6y < 7, and x ≥ 0, y ≥ 0.
(i) True or False: (x = −1, y = 2, z = 3) is a solution to the
following...

I) Use MATLAB to compute the determinants of the following two
matrices. (Use format rat)
P
Q
5
0
0
0
-1
-1
1
1
13
2
0
0
2
0
1
3
-6
4
-1
0
2
-1
1
2
10
0
3
-2
1
0
3
3
II) The determinant of P could be computed without MATLAB. What
general fact could have been used to do this?
III) Use MATLAB to compute the matrix R= PQ and also...

Consider the matrix A=
−2−2 6]
[−2−3 5]
[3 4−8]
[−7−9 18
(all one matrix)
(a) How many rows ofAcontain a pivot position?
(b) Do the columns ofAspanR4?
(c) Does the equationA ~x=~b have a solution for
every~b∈R^4?
(d) Would the equation A~x=~0 have a nontrivial solution?
(e) Are the columns of A linearly independent?
(~x is vector x)

LINEAR ALGEBRA
For the matrix B=
1 -4 7 -5
0 1 -4 3
2 -6 6 -4
Find all x in R^4 that are mapped into the zero vector by the
transformation Bx.
Does the vector:
1
0
2
belong to the range of T? If it does, what is the pre-image of
this vector?

2. For each
3*3 matrix and each eigenvalue below construct a basis for the
eigenspace Eλ.
A= (9 42 -30 -4 -25 20
-4 -28 23),λ = 1,3
A= (2 -27 18 0 -7 6 0 -9 8) , λ = −1,2
3. Construct a 2×2
matrix with eigenvectors(4 3) and (−3 −2) with eigen-values 2 and
−3, respectively.
4. Let A be the 6*6
diagonal matrix below. For each eigenvalue, compute the
multiplicity of λ as a root of the...

ADVERTISEMENT

Get Answers For Free

Most questions answered within 1 hours.

ADVERTISEMENT

asked 3 minutes ago

asked 8 minutes ago

asked 17 minutes ago

asked 41 minutes ago

asked 48 minutes ago

asked 50 minutes ago

asked 50 minutes ago

asked 53 minutes ago

asked 1 hour ago

asked 1 hour ago

asked 1 hour ago

asked 1 hour ago