Matrix P
is given by P = [1 2 3 4; 5 6 7 8; 9 10 11 12]
, write matlab
code to calculate the following:
P
and store them in A
and
B
, respectively.
A
and B
.A
and B
.Px=b
, where x is a vector of variables we want to
solve, and b = [1 0 -1]
. Compute x
to solve this linear equation.
Consider the vector A = [12, 7, 15, 22, 17, 2, 27, 30, 9, 44]
.
A
if it is an even number. A
. In an experimental physics lab, students are studying the relationship between temperature and the resistance of two types of materials, Material X and Material Y. The data they collected is as follows:
Temperature = [20, 50, 100, 150, 200, 250, 300]; % in degrees Celsius
Resistance_of_Material_X = [15, 30, 45, 60, 75, 90, 105]; % in ohms
Resistance_of_Material_Y = [10, 20, 40, 70, 110, 160, 220]; % in ohms
Resistance of Material X
and Resistance of Material Y
in terms of Temperature
. And also add proper labels, legend and title to the graph.
Requirements:
Linearising a nonlinear function To obtain a linear model of a nonlinear system, we assume the variables deviate slightly from an operating condition. Taylor Series: a series expansion of a function about a point Taylor Series: linear approximation The linear approximation of the system (function) can be obtained using the tangent line.
f(x) ≈ f(x0) + f'(x0)(x - x0)
f(x) = x3
Linearise it at x0 = 2 and x0 = -2
Plot the nonlinear function and the linearised functions.
Example:
The definition of function f(x,y) with two variables is as follows:
f
when (x,y)
is given as follows: (-1, -2)
, (-1, 2)
, (1, -2)
and (1, 2)
.