ENG1060 Assignment Page 1 of 9 ENG1060 ASSIGNMENT – S2 2018 Due: 11:00PM (Sharp), Friday 12th October 2018 (Week 11) Late submissions: A 10% penalty (-1 mark) per day (or there part of) will be...

Hey
herewith im attaching my assingment details and the m file which needs to be completed my deadline date is on 8 maximum on the 9th


ENG1060 Assignment Page 1 of 9 ENG1060 ASSIGNMENT – S2 2018 Due: 11:00PM (Sharp), Friday 12th October 2018 (Week 11) Late submissions: A 10% penalty (-1 mark) per day (or there part of) will be applied. No submissions will be accepted once the penalty has reached 50%. GUIDELINES This assignment is to be completed INDIVIDUALLY. All assignments will be checked using plagiarism-detecting software (similar to ENG1003). High-similarity cases will be reviewed. Plagiarism includes letting others copy your work and using code without citing the source (e.g. website). Collaborating with others to discuss algorithms and details of MATLAB syntax and structures is acceptable (indeed encouraged), however you MUST write your own MATLAB code. Cases of academic misconduct will be reported to the Chief Examiner, and results will be withheld until the student(s) has attended a discipline hearing with the Associate Dean of Education and the decision has been finalised. INSTRUCTIONS Download the assignment template files from Moodle and update the m-files named Q1a.m, Q1b.m, etc… with your assignment code. DO NOT rename the m-files in the template or modify run_all.m. Check your solutions to Q1 and Q2 by running run_all.m and ensuring all questions are answered as required. Do not use close all, clear all, clc in any individual mfiles. SUBMITTING YOUR ASSIGNMENT Submit your assignment online using Moodle. Read the “Assignment upload instructions.pdf” to prepare your ZIP file for submission. Your ZIP file (not .rar or any other format) must include the following attachments: a. Solution m-files for assignment tasks (e.g. run_all, Q1a.m, Q1b.m, etc.) b. Any additional function files required by your m-files (e.g. heun.m, falseposition.m, etc.) c. All data files needed to run the code including the input data provided to you (e.g. data1.txt, data2.csv, etc.) Your assignment will be marked in your usual computer lab session during Week 12. YOU MUST ATTEND TO HAVE IT MARKED. IF YOU DO NOT ATTEND, YOUR ASSIGNMENT MARK WILL BE ZERO. YOUR ZIP FILE WILL BE DOWNLOADED FROM MOODLE AT THE END OF WEEK 11 AND ONLY THESE FILES WILL BE MARKED. We will extract (unzip) your ZIP file and mark you based on the output of run_all.m on a Windows-based system. It is your responsibility to ensure that everything needed to run your solution is included in your ZIP file. It is also your responsibility to ensure that everything runs seamlessly on a Windows-based system (especially if you have used MATLAB on a Mac OS or Linux system). Windows OS computers are available in the computer labs on campus for testing. The assignment will not be downloaded to your individual laptops for marking. ENG1060 Assignment Page 2 of 9 MARKING SCHEME This assignment is worth 10% (1 Mark = 1%) of the unit mark. Your assignment will be graded using the following criteria: 1) run_all.m produces results automatically (additional user interaction only if asked explicitly) 2) Your code produces correct results (printed values, plots, etc…) and is well written. 3) Poor programming practice will result in a loss of up to 2 marks out of 10. 4) Your ability to answer the demonstrator's questions testing your understanding of the questions and the submitted code. ASSIGNMENT HELP 1) You can use function files you've written in your labs 2) You can ask questions in the Discussion Board on Moodle 3) Hints and additional instructions are provided as comments in the assignment template m-files 4) Hints may also be provided during lectures 5) The questions have been split into sub-questions. It is important to understand how each sub- question contributes to the whole, but each sub-question is effectively a stand-alone task that does part of the problem. Each can be tackled individually. 6) It is recommended that you break down each sub-question into smaller parts too, and figure out what needs to be done step-by-step. Then you can begin to put things together again to complete the whole. 7) The m-file templates contain comments and sections only as a guide. You do not need to follow its structure. 8) Bold text has been used to emphasize important aspects of each task. This does not mean that you should ignore all other text. ENG1060 Assignment Page 3 of 9 QUESTION 1 [3 MARKS] Background Accelerometers are small electronic devices that measure acceleration from moving objects. As a trainee engineer on a racing team, you have been given accelerometer data from a test run at the Watkins Glen International Racetrack. An image of the racetrack is shown in figure 1. Figure 1: Satellite view of the Watkins Glen International racetrack. The data you collected from the accelerometer during a test run is output to a csv file named “race_data.csv”, which contains: • Time, t (s) • Longitudinal acceleration, ALONG (ms-2) • Latitudinal acceleration, ALAT (ms-2) • G-force lateral acceleration, GLAT (g) • G-force acceleration/deceleration, GAD (g) Note that 1g = 9.81 ms-2. You have been asked to analyse the data and prepare a graphical presentation of the results by performing the following tasks: Q1a In the Q1a.m file, use the importdata() function to import values from the race_data.csv. Create variables for the time (t), longitudinal acceleration (ALONG), latitudinal acceleration (ALAT), G-force lateral acceleration (GLAT), and G-force due to total acceleration/deceleration (GAD). In a 2x2 subplot arrangement, plot the following: • ALONG against t [top left panel] • ALAT against t [top right panel] • GLAT against t [bottom left panel] • GAD against t [bottom right panel] *You should have one figure window by the end of this task. ENG1060 Assignment Page 4 of 9 Q1b In the cumultrap.m file, complete the function file to perform cumulative integration using the trapezoidal rule given two input vectors. The function should return the cumulative integrated values at the nominated independent values. You may only use the following built-in functions for your function file: zeros() and length(). Note: The integral of a set of data returns a scalar result. In contrast, the cumulative integral returns a vector, whose values represent the integral values from the start of the integration to its current point. Also, note that integral value of a single point is zero. Read the documentation for cumtrapz() for further details and use that function to verify your answers. *You should still have one figure window by the end of this task. Q1c In the Q1c.m file, integrate the following equations to obtain the longitudinal and latitudinal velocities V and displacements D of the race car: ????? = ∫ ????? ?? ???? = ∫ ???? ?? ????? = ∬ ????? ???? ???? = ∬ ???? ???? In a new figure with a 1x2 subplot arrangement, plot the following: • Satellite image (track_map.png) of the track using imshow(). [left panel] • Latitude displacements against longitude displacements with the grid on and set the axes to be equal (option for axis). [right panel] Also, determine the length of the track. You must use a for loop to complete this task. Use fprintf to print the length of the track: E.g. Track length: ???m *You should have two figure windows by the end of this task. Q1d A strong left turn is identified as when the race car experiences lateral G-forces greater than 0.4g. A strong right turn is identified as when the car experiences lateral G-forces less than -0.4g. In the Q1d.m file, determine the left and right-turning corners. In a new figure with a 1x2 arrangement, plot the following: • G-force lateral acceleration against time [left panel] • Latitude displacements against longitude displacements with the grid on [right panel] On both panels, mark the following: • Left-turning corners as blue dots • Right-turning corners as red dots Dots on the left panel are sized 5, and dots on the right panel are sized 15. Remember to include a legend. *You should have three figure windows by the end of this task. ENG1060 Assignment Page 5 of 9 Q1e Acceleration and deceleration zones are identified as follows: • Acceleration zones – where race car experiences G-forces less than -0.1g. • Deceleration zones – where the race car experiences G-forces greater than 0.1g. In the Q1e.m file, create a new figure with a 1x2 subplot arrangement containing 3 subplots and plot the following: • G-force due to total acceleration/deceleration against time [left panel] • Latitude displacements against longitude displacements with the grid on [right panel] On both panels, mark the following: • Accelerating zones as green dots • Decelerating zones as magenta dots Dots on the left panel are sized 5, and dots on the right panel are sized 15. Remember to include a legend. *You should have four figure windows by the end of this task. ENG1060 Assignment Page 6 of 9 QUESTION 2 [3 MARKS] Background Monte Carlo methods are a broad class of computational algorithms that rely on repeated random sampling to obtain numerical results. You have been asked to estimate the value of π using the Monte Carlo method. A number of randomised points is generated within the box of unit width, as shown in figure 2. Some of the points lie within the circle, while others lie outside the circle. The value of π is calculated using the following expression: ? ≈ 4?? ?? where NC represents
Oct 06, 2020
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here