Write a function in matlab that takes as input the number n

Assignment Help Computer Engineering
Reference no: EM132199128

Question :

Write a function in Matlab that takes as input the number n, a sparse matrix given as r, c, v, m, an n-component column vector b, and a tolerance tol.

Directly use this coordinate list form to output the approximate solution of Jacobi method solving Ax = b using the zero vector for initial guess and iterated until the 2-norm (do not use Matlab's ‘norm' command) of the residual falls below tol (while loop); the number of iterations used; the number of flops used for calculating the approximation; and the 2-norm of the final residual vector.

(a) Write out or print out your function.

(b) Create the r, c, v, m for the 10×10 tridiagonal matrix with 2's down the main diagonal and -1's in the upper and lower diagonals. Take b the vector of 1's and tol = 10-4 and write down your results for the number of iterations, the 2-norm of the residual vector, and the number of flops used. What about for tol = 10-8.

Reference no: EM132199128

Questions Cloud

Write out or print out your function : Write a function in Matlab that takes as input s and a number x and outputs the floating point number of x using s-digit rounding.
Write a function in matlab that takes as input the number n : Write a function in Matlab that takes as input the number n, the size of matrices and vectors; m, the number of nonzero elements of a sparse matrix;
Calculate the gross pay for each employee : ACC508 Informatics and Financial Applications Assignment Task, University of the Sunshine Coast, Australia. Calculate the gross pay for each employee
Test your function with three different integer arrays : Write a function, named avg, that receives an array of integer values and returns the average of those values in that array.
Write a function in matlab that takes as input the number n : Write a function in Matlab that takes as input the number n, a sparse matrix given as r, c, v, m, an n-component column vector b, and a tolerance tol.
Write a function to remove duplicate entries in linked list : Write a function to remove duplicate entries in a linked list. For example, given the list (5,2,2,5,3,9,2) as input, your function should change the list.
How often the police should monitor the tickets : For the NJ Light Rail problem, assume the price of a ticket is $5.00, and that a passenger has to decide whether to buy a ticket or try to get a free ride.
Discuss the macroeconomic impacts of slow wage growth : Wage growth has slowed considerably in many advanced economies since the Global Financial Crisis. Compare and contrast, and explain, the likely causes.
What are some arguments for inflation targeting like given : Some observers argue that the mandate of the Federal Reserve Bank should be changed to prioritize the control of inflation over other goals.

Reviews

Write a Review

Computer Engineering Questions & Answers

  What is the average access time for combined read

It is also estimated that 80% of the memory accesses are for read and 20% for write operations. A cache write-through procedure is used.

  Display the total price of the hotel stay

You work for a local hotel chain and have been tasked with coding a program that calculates the cost of a user's hotel stay depending on room choices.

  What is an it risk assessments goal or objective

What is an IT risk assessment's goal or objective? Why is it difficult to conduct a quantitative risk assessment for an IT infrastructure?

  Algorithm for generating list of customers

Develop an algorithm in order to generate a list of customers from Glad Rags Clothing Company’s customer master file.

  In how many possible ways can a team of 5 happen

In a school project, a group consists of 8 boys and 5 girls. In how many possible ways can a team of 5 happen if there should be at most one girl.

  Define a dictionary attack and how it can he prevented

Define a dictionary attack and how it can he prevented. Distinguish between challenge-response and zero-knowledge entity authenticators.

  How the open call can be used to emulate the function

Specify how the open call can be used to emulate the function performed by the shell's > and >> symbols.

  Wave maker-editor software

Describe what wave maker-editor software can do and what are the sensor and wave can be use. With all details.

  Article on a biomedical application using a microcontroller

Find a recent article on a biomedical application using a microcontroller and how you would design this microcontroller-based string matching detector. Which peripherals would you be using? What considerations would you take into account

  You will create a page in the folder named index html

You will create a page in the folder named index.html that should be an HTML page containing a link to every JPEG file in the directory.

  What strategies does mpeg uses for compression

What strategy does MPEG uses for compression? List factor that contribute to image quality? Explain using an example how does MPEG codec apply these strategies.

  What is the asymptotic worst-case running time of quick-sort

Argue informally why this should be a good choice for pivot. What is the asymptotic worst-case running time of quick-sort in this case, in terms of n and d?

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd