Science 2 Assignment 1 Solved

34.99 $

Description

5/5 - (1 vote)

Instruction: For questions: 1, 3 and 4, also submit the code used to plot/solve.
1) Find the coefficients of the polynomial p(t) = a1t2 + a2t + a3 = y. A set of 5 data points for the same are given below. You need to write code (in Matlab or Python) to do the same.

Also plot the least-squares curve for the data.
2) Consider the system of springs and masses shown in the figure below with three masses m1, m2, and m3 at vertical displacements y1, y2, and y3, connected by three springs having spring constants k1, k2, and k3.

Write the equation of motion of this system.
3) Construct a matrix M, where the elements are drawn from a normal distribution: N(0,1).
Assuming the size of M is fixed at N=500, and the diagonal elements are constant and
fixed at -D (where D>0), plot all the eigen values (λ) in the complex plane (Real(λ) vs imag (λ)) for four sets of D: 0, 1, 5, and 10. a) What shape do you see in the plot?
b) Explain the effect of D on the plot.
c) What will happen if the matrix is real and symmetric?
Reference papers for this question: https://www.nature.com/articles/238413a0, https://www.nature.com/articles/nature10832
4) A common problem in surveying is to determine the altitudes of a series of points with respect to some reference point. The measurements are subject to error, so more observations are taken than are strictly necessary to determine the altitudes, and the resulting overdetermined system is solved in the least squares sense to smooth out errors. Suppose that there are four points whose altitudes x1, x2, x3, x4 are to be determined. In addition to direct measurements of each xi with respect to the reference point, measurements are also taken of each point with respect to all of the others. The resulting measurements are:

Set up the corresponding least squares system, Ax = b and write code to solve it for the best values of the altitudes. How do your computed values compare with the direct measurements?

  • Assignment1-bfpqhz.zip