Write a MATLAB function to estimate circle centre and radius

Assignment Help MATLAB Programming
Reference no: EM132385029

Assignment

Topic- Numerical Linear Algebra (MATLAB)

It aims to develop your skills in programming in MATLAB, to deepen your understanding of numerical linear algebra and to explore applications of numerical linear algebra. Your solutions to this assignment will be MATLAB program listings and relevant output, together with any other mathematical derivations, notes or explanations that aids understanding.

In marking the assignment, the following criteria will be applied:

- correctness of the programs and mathemetical calculations

- clear and concise documentation, in the form of comments in the code, as to the approach being used, and

- relevance of the output in verifying the correctness of the program and in illustrating the solution.

- Some consideration will also be given to the ef?ciency of the solution.

Question 1

There is a signal b collected at M sampling points(b(1), b(2), ...b(m), ...,b(M)), and you are asked to strategically place N components x (x(1), x(2), ...,x(n),...x(N)) into the system to modify the signal profile. The modified signal profile B=Ax+b will satisfy the following condition (|??#????|) / ???? ≤∈, where B0 is the mean value of signal B. And ∈ (??) = 0.0001, ??=1,2,...M. In addition, b, B are both positive vectors. The range of components x: 0≤x(n) ≤0.006, n=1,2,...,N.

You are asked to implement the following tasks:

- Write a matlab code to minimise the 1-norm of vector x.

Note: please consider the function linprog() in matlab; The matrix A and vector b are stored in files: A.mat and b.mat, and in matlab, you can access the data as follows: Load A; load b.

- Convert the vector b to be a two-dimensional (2D) matrix data, b2d, whose size is 24X24. If you treat b2d as an image, please use low rank approximation (r=4) to implement image compression. Please plot the original image (b2d) and compressed image, and calculate the compression rate.

Note: in matlab, you can use the following code to implement data conversion:

b2d=reshape(b, [24,24]); and for image plotting, please consider function imagesc().

Question 2: Circle Centre Estimation

The accurate fitting of a circle to noisy measurements of points on its circumference is an important and much-studied problem in statistics. It has applications in many areas of research including archeology, geodesy, microwave engineering, computer vision and metrology. In this question, you will implement a least-squares algorithm for the estimation of circle centre and radius.

2388_Circle.jpg

Figure 2: Noisy measurements of points on the circumference of a circular arc for Question 2.

Figure 2 illustrates the model for the data. The data are assumed to consist of N points, (xi, yi), i = 1 N, each slightly displaced from the circumference of a circle by noise so that

xi = a + r cosθi + ξi,

yi= b + r sinθii.

Here, (a ,b) is the centre of the circle, r is its radius, the θi are the angles along the arc on which the points lie and the ξi and ηi are noise.

Given the (xi, yi), it is possible to formulate the problem of estimating (a, b) as a linear least squares problem. First of all, define the function

ri(a,b) = √(xi - a)2 + (yi - b)2,

i.e., the distance from the centre to the ith noisy point on the circumference. If the centre and radius has been estimated well then ri(a, b) should be approximately equal to r for all i = 1 ..... N. Hence, one approach to estimating a, I) and r would be to choose those values that minimise the mean square error between the ri(a,b) and r, i.e., minimise the expression

(1/N) i=1ΣN[ri(a,b) - r]2 .

However, this expression is difficult to work with because of the square-root terms in each of the ri(a, b). It's much easier to minimise the expression

(1/N) i=1ΣN[ri(a,b)2 - r2]2 .

with respect to a, b and r because the square-root terms disappear. In fact, as we will see, this transforms the problem into a linear least squares problem. Now, substitute r with c where

c = r2 - a2 - b2.

The expression we seek to minimise can then be written as an objective function f in three variables, a, b and c, such that

ƒ (a, b,c) = i=1ΣN[xi2 - 2axi + yi- 2byi -c)

(Notice that we have discarded the constant 1/N term.) If we write the parameters to be estimated in a vector
v= (abc)

then we can rewrite the objective function as

ƒ (v) = ||Mv -w||2                 (1)

for constant matrix M and vector w. This is a linear least squares problem and we know from Lecture LA09 that ƒ(v) is minimised when

v = M+w

(a) Derive expressions for the matrix M and the vector w in (1).

(b) Write a MATLAB function to estimate circle centre and radius from a matrix P containing the coordinates (xi, yi) as columns.

(c) Generate a plot similar to Figure 2. To do this, choose the true value of r to be around 20, set the Og to be equally spaced over an arc of around 90° and use MATLAB'S randn function to create the noise components (ξi , ηi) . Plot the noisy points, the true centre and the estimated centre, the true circle and the estimated one.

Reference no: EM132385029

Questions Cloud

What is the probability that sales will be less than : If the restaurant sales average $100,000 per month and the standard deviation is $10,000, what is the probability that sales will be less than $90,000.
What are we attempting to measure : For the following problem, put answers a - d in the box divided by commas. Also, the only answer that requires a calculation is d.
BUS-1168 Management Communication Assignment : BUS-1168 Management Communication - Journal Entries Assignment Help and Solution - Lethbridge College, Canada - Observe situations that relate to communication
Discuss how this question could create bias : Please rate your satisfaction with the institution." Discuss how this question could create bias.
Write a MATLAB function to estimate circle centre and radius : Write a MATLAB function to estimate circle centre and radius from a matrix P containing the coordinates (xi, yi) as columns. Write a matlab code to minimise.
Random employee commutes between 28 and 32 miles : Assuming normal distribution, what is the probability that a random employee commutes between 28 and 32 miles?
Believing that the amount of people : In two independent polls, 368 out of 430 drank coffee and 56 out of 154 did not drink coffee. Test the population proportion with a 90% confidence interval.
ITECH1100 Hat City Assignment Problem : ITECH1100 Hat City Assignment help and solution, Federation University, Assessment help - Apply business information software for data visualization.
Count of drawing a red ball is a binomial distribution : A ball is drawn from a bag of 26 red and 12 yellow balls. The process is repeated 50 times, replacing each ball that is drawn.

Reviews

Write a Review

MATLAB Programming Questions & Answers

  Design and computations - digital signal processing

Compute the time dependent Fourier transform of the complex digital signal. Plot it as a 2- dimensional function of true analog frequency (Hz) on the y-axis and time (sec) on the x-axis between 0 to 10 sec.

  Analyse and display the data as per the problem description

MatLab Programming - Using appropriate MatLab syntax, write the code required to analyse and display the data as per the problem description

  Construct a commutated dc motor to drive a load

Construct a commutated DC motor to drive a load, simulated by a generator placed on the output shaft of your motor. You may use any readily available materials - characteristic for the different field densities created by the different permanent ma..

  Design a matlab application that has transformer power ratin

Design a MATLAB application that has the following input data:Transformer power rating (VA), Transformer voltage ratings (VH and VL) Open-Circuit test results: VO, IO, and PO Short-Circuit test results: VSC, ISC, and PSC. Identify on which side each ..

  Determine the volume of the pyramid

Determine the volume of the pyramid. When the user enters every value, they will then be prompted also for either 'i' for inches, or 'c' for centimeters.

  Simulate an analog clock

simulate an analog clock as partly demonstrated in class for the case of the second hand - Create a program called plot

  Compute the value of each piece of clothing

You decide to write a script in MATLAB that will compute the value of each piece of clothing.

  Blood declines due to metabolic processes

Find an expression for the half-life in terms of k, and obtain a plot of the half-life versus k for the indicated range.

  Cholesky decomposition to find upper triangular matrix

Mech 3010: Numerical Methods and Programming - Use Cramer's Rule to solve for x Check answer using backslash operator and Cholesky decomposition to find upper triangular matrix U.

  Integration and random numbers

assemble 1,000 bolt + hole combinations. The bolts have a mean diameter of 1.000 cm, normally distributed with standard deviation of 0.010 cm. The holes have a mean diameter of 1.030 cm, normally distributed with standard deviation of 0.015 cm.

  Write a matlab program that enables you to specify

Write a Matlab program that enables you to specify and keep only a proportion of the Fourier Transforms of largest magnitude from an image representation.

  Write down a rotation matrix

MAT 343 Laboratory - Consider the original triangle T.Reflect the triangle about the line at 45o and plot the reflection together with the original triangle. Add a grid, a legend and title.

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