• Non ci sono risultati.

EXERCISE 1

N/A
N/A
Protected

Academic year: 2021

Condividi "EXERCISE 1"

Copied!
1
0
0

Testo completo

(1)

EXERCISE 1

Write a Matlab function [x,mu]=power(A,maxit,tol) that implements the power method to approximate the dominant eigenvalue of a matrix (use a random vector as initial guess). Test it on the matrix

A = Q*diag(1:10)*inv(Q), with Q = orth(randn(10,10))

Note that the spectrum of A is {1, . . . , 10}. Modify the function to be able to plot the relative error |λ1− µk| / |λ1| and also (|λ21|)k, k = 1, 2 . . .. What do you observe?

Same as above, but test on the nonsymmetric matrix obtained using Q = randn(10,10). Compare the results with the previous case.

Write another function, inverse power, that implements the inverse power method (use “backslash” to solve the linear system), and test it on the matrix used in the previous point to approximate λ9= 2 using

µ = 1.55, 1.65, 1.75, 1.85, 1.95.

Plot the number of iterations required to converge vs. the value

9− µ| / |λ10− µ| and comment.

1 / 1

Riferimenti

Documenti correlati

Pur considerando il nesso tra etica e tecnologia come interno alla dimensione tecnologica considerata, infatti, le teorie critiche finiscono per produrre uno

La configurazione assoluta di molti prodotti naturali e' spesso associata alla loro attivita' biologica, questo aspetto ha indotto un grande sforzo sintetico volto alla

The new book of the Catalan sociologist Manuel Castells takes up again, after several years, some of the issues he tackled in some of his most famous works: the internet,

To receive full credit, show all of your work.. Neither calculators nor computers

When revising strategy after the game round t, the updated neighborhood classification (last column in Table 1 ) allows the agent to compute her expected future payoffs, should

We study the optimality condition in the viscosity sense, we identify the regular and singular part of the topological boundary and then we reduce ourselves to a problem with only

Therefore, the task of operational forecasting is considered in terms of filing applications on a balancing market for the next hour, as well as for obtaining reference data on

Such a selection is now based on the maximum check interval value present in