CE 506 Homework 1 Matlab Practice
given:
B=[1 1;2 1;3 1];
f=[1;3;2];
Q=[2 1 0;1 2 1;0 1 3];
A=[1 2;2 4;3 6];
A2=[1 2;2 4;3 6.0001];
C1=[1 2 1;3 4 1;1 2 2];
d1=[[2;1;1];
C2=[1 2 1;2 4 2;1 2 2];
d2=[3;6;7];
find:
W=inverse of Q;
N=B-transpose * W * B;
t=B-transpose * W * f;
solve N*x = t;
condition numbers of B & N;
determinant of N;
eigenvalues of Q & N;
singular values of N;
the solution of C1*z=d1;
a solution of C2*w=d2;
rank & condition number of A-transpose * A;
rank & condition number of of A * A-transpose;
rank & condition number of A2-transpose * A2;
rank & condition number of A2 * A2-transpose;
a 20 element vector v1 with normal distribution
(mean 0, variance 1)
a 20 element vector v2 with uniform distribution
(between 0 and 1)
a 1000 element vector v3 with normal distribution
(mean 0, variance 1)
a 1000 element vector v4 with uniform distribution
(between 0 and 1)
make:
plots of v1 and v2, do they look as you expect?
histograms of v3 and v4, do they look as you expect?
notes:
command "diary filename" and "diary off" will capture
screen dialogue
"format compact" saves paper etc.
do not print out huge vectors or matrices
include headings, explanations, annotations, comments, etc.
please avoid just handing in raw, computer generated
output. it is not the grader's job to figure out what your
results mean.