Question
1)Write a function that finds the period of the fundamental model of oscillation for a shear building where the masses of each floor and the
1)Write a function that finds the period of the fundamental model of oscillation for a shear building where the masses of each floor and the stiffnesses of each story are all the same.( using the function below in Matlab)
function fm = sb(m, k, n)
% Find the period of fundamental mode of oscillation for % an n-story shear building model with all masses % equal to m and all stiffnesses equal to k. % %Example: if m = 1000, k = 10000, n = 3, then fm = 4.46
2)Write a function that uses the power method to converge to an eigenvector of a given matrix (using the following function in matlab)
function v = power_method(A, n, v0)
% Given a matrix A and a starting guess v0, % apply n iterations of the power method % to estimate the eigenvector of A with largest eigenvalue. % Use the 2-norm [norm(v)] to scale the estimated eigenvector at each step. % % For example, if A = [1 2; 1 1] and v0 = [1; 1], % n = 1 should return v = [0.832; 0.555] % n = 2 should return v = [0.814; 0.581] % n = 3 should return v = [0.817; 0.577]
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started