08 Jun Workshop 2 MATLAB
Question
Griffith School of Engineering Semester 2-2013 Gold Coast Campus
2006ENG Numerical and Data Analysis
Laboratory Workshop 2
Include all your programs and their input and output in ONE .doc or .pdf file. Also, include all your comments on the same file. Submit the file using turn-it-in to be found in the assessment menu on your L@G account. Please be reminded that turn-it-in allows submission only once. The marks for the two questions are 10 + 10.
1. Engineers often use thermodynamics extensively in their work. The following polynomial can be used in relating the zero-pressure specific heat of dry air cp kJ/(kg K) to temperature (K):
cp = 0.99403 + 1.671 * 10-4T + 9.7215 * 10-8T2– 9.5838* 10-11T3 + 1.9520 * 10-14T4.
Write a MATLAB program that does the following things.
a) Convert the equation into f(T) = 0 when cp of 1.1kJ/kgK. In our MATLAB program, develop a plot of f(T) versus a range of T = 0 to 1200 K. MATLAB. On the axes, put proper labelling.
b) Use your plot to graphically select two points that bracket a solution. In your program write a bisection algorithm to find the value of T such that f(T) = 0 using the two selected points as your initial values.
c) Your algorithm will find the value of T up to 10 decimal places. Determine the level of the absolute approximate relative error to be achieved in this case. Use the error level as the stopping condition in your program.
d) In each iteration, your program should display the current root and the current value of relative approximate error.
e) Show your selected points and the root in the plot as well with their x values.
2. Consider the following system of linear equation:
2×1 – 6×2 – x3 = -38 -3×1 -x2 + 7×3 = – 34 -8×1 + x2 – 2×3 = -20
a) Check whether system has no solution, infinite number of solutions or ill-conditions. Perform this checking from the coefficient and constant matrices.
b) Manually solve the system of linear equation using Gauss elimination method with partial pivoting. Consider 3 decimal places. Show all steps of your computation in detail.
c) Once you obtain the solution, go to MATLAB’s command window to compute the solutions by using Cramer’s Rule and verify the correctness of the solution.
d) Considering the values obtained from MATLAB as true value, compute the absolute relative errors for the values that you manually calculated for each of variables.
e) Include all your computation details, and MATLAB command window activities in your file to be submitted..
Prepared By: Newton M.A.Hakim
Our website has a team of professional writers who can help you write any of your homework. They will write your papers from scratch. We also have a team of editors just to make sure all papers are of HIGH QUALITY & PLAGIARISM FREE. To make an Order you only need to click Ask A Question and we will direct you to our Order Page at WriteDemy. Then fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Fill in all the assignment paper details that are required in the order form with the standard information being the page count, deadline, academic level and type of paper. It is advisable to have this information at hand so that you can quickly fill in the necessary information needed in the form for the essay writer to be immediately assigned to your writing project. Make payment for the custom essay order to enable us to assign a suitable writer to your order. Payments are made through Paypal on a secured billing page. Finally, sit back and relax.
About Writedemy
We are a professional paper writing website. If you have searched a question and bumped into our website just know you are in the right place to get help in your coursework. We offer HIGH QUALITY & PLAGIARISM FREE Papers.
How It Works
To make an Order you only need to click on “Order Now” and we will direct you to our Order Page. Fill Our Order Form with all your assignment instructions. Select your deadline and pay for your paper. You will get it few hours before your set deadline.
Are there Discounts?
All new clients are eligible for 20% off in their first Order. Our payment method is safe and secure.
