CPS125 - Term Project – Winter 2020 This project is a team project. It must be done in teams of two, three, or four people (preferably three). Teammates must be from the same professor's class (not...

1 answer below »
I need to do question 3 and 4 and table of outputs and discussion (Some sentences to scientifically explain/interpret the results we got while referencing the Tables/figures in “Results” don’t explain the code and how you wrote it)


CPS125 - Term Project – Winter 2020 This project is a team project. It must be done in teams of two, three, or four people (preferably three). Teammates must be from the same professor's class (not necessarily the same lab section). Students working alone and teams that have members from different professors will have their submissions refused. UPDATE >> Students working alone now accepted On this project you will make calculations and conclusions based on real data collected by the NOAA (The National Oceanic and Atmospheric Administration, an agency of the United States government) on the “Daily Lake Average Surface Water Temperature” of six lakes (Ontario, Erie, Huron, Michigan, Superior, and St. Clair) during the 2019 calendar year. You can find the actual data file here that contain the average temperatures for each day of the year for each of the six lakes. Data were collected between January and December 2019 and are in degrees Celsius. https://coastwatch.glerl.noaa.gov/ftp/glsea/avgtemps/2019/glsea-temps2019_1024.dat Days are numbered 1 to 365, 1 being January 1st and December 31st being 365. You must use the C program to read the file and put the data into arrays. Download the file and clean it up to make it compatible – simply remove all lines above 2019 001 3.29 4.19 3.50 4.06 4.59 2.92 Do not enter data by hand! HINT > Have a loop that goes from 1 to 365 and fill one array per lake (one cell per iteration). The cell number will act as the day of the year (just leave cell 0 unused). Required elements: Each required element should have its own program (.c) file although one program with separate helper functions is also an excellent implementation. All computations to be done in C using the imported data file. 1. Calculate the yearly average temperature for each of the lakes, and the yearly average for all six lakes put together. 2. Indicate which lake is the coldest and which one is the warmest, based on the average yearly temperatures calculated in step #1. Also indicate which lakes have average temperatures above the average of all the lakes and which ones are below that same average. 3. Indicate the day and the temperature for the warmest water temperatures for each of the lakes. Do the same for the coldest temperatures. You must convert the day of the year value into a date/month format. 4. Indicate the day, lake and temperature of the warmest water temperature overall (all lakes combined). You must convert the day of the year value into a date/month format and indicate which lake. Do the same for the coldest temperature. 5. Calculate the summer average (day 172 to day 265) for all 6 lakes (one average per lake). Display the names of the lakes in order from warmest to coldest. Is the order from warmest to coldest the same as with the yearly average calculated in step #2? 6. Calculate the winter average (days 1 to 79 and days 355 to 365) for all 6 lakes (one average per lake). Display the names of the lakes in order from warmest to coldest. Is the order from warmest to coldest the same as with the yearly average calculated in step #2? 7. Assuming that you can swim comfortably in the lake if the temperature is above 20 degrees. Calculate the number of days in the year you can swim for each of the 6 lakes. https://coastwatch.glerl.noaa.gov/ftp/glsea/avgtemps/2019/glsea-temps2019_1024.dat 8. Assuming that lakes freeze when the water falls below 0 degrees. Calculate the number of days in the year that the lake is frozen. 9. Re-do question 1 (the 7 yearly averages) but with data from 2018 instead. Make a table of the averages side by side to illustrate the two yearly results. Any notable changes between 2018 and 2019? The data file for 2018 is here: https://coastwatch.glerl.noaa.gov/ftp/glsea/avgtemps/2018/glsea- temps2018_1024.dat Important Notes: I. All computations are to be done with C only. No hand computations are permitted. II. You are to write a report. Your report must have an introduction about the purpose of the report and its presentation. Present also all team members and specify who did what if applicable. III. The report must be detailed, well presented and attractive. Don't be afraid to use colors to emphasize parts of the report. Be creative in the use of tables and images. Points will be awarded to the exactness of the computations, appearance, ease of reading (use font sizes that are easy to read and use adequate line spacing and margins), and the quality of the English language. Length of the report should be approximately between 3 and 7 pages (excluding C codes in the appendix). The report consists of the answers provided by each of the program requirements and a short sentence explaining why the results make sense. Be original! Plagiarism will be dealt with severely to the full extent of Ryerson academic integrity regulations. The report and programs will be submitted to a plagiarism detection system and non-original submissions will incur an extra 5% penalty on the final grade (in addition to the 0/10 mark which will be assigned for a non-original assignment) as per CMF and Ryerson policy #60. IV. Your report must have a conclusion about your experience doing this project and how you would do things differently if you had to do this again. VI. Finally, as an appendix (a few pages at the end of the report), print out the codes of all your C programs (.c files). Your report must be submitted in PDF format (you can write it using Microsoft Word or OpenOffice/LibreOffice/NeoOffice Writer and export to PDF at the end). Submission: 1. Project reports are to be submitted in PDF format on D2L/Brightspace. Only one submission per team. Do not submit duplicates! Teammates must be clearly identified as per point II in the important notes above. 2. Project must be submitted on or before April 3, 2020 @ 20:00 EDT. Late assignments will not be accepted for marking. If you are concerned about getting the assignment in on time, submit it early. Technical excuses will not be accepted. Las updated on March 5, 2020 – 11:35 EST https://coastwatch.glerl.noaa.gov/ftp/glsea/avgtemps/2018/glsea-temps2018_1024.dat https://coastwatch.glerl.noaa.gov/ftp/glsea/avgtemps/2018/glsea-temps2018_1024.dat 2019 001 3.29 4.19 3.50 4.06 4.59 2.92 2019 002 3.22 4.15 3.43 4.06 4.62 2.87 2019 003 3.21 4.17 3.43 4.07 4.70 2.85 2019 004 3.28 4.23 3.46 4.06 4.71 2.89 2019 005 3.26 4.31 3.45 4.00 4.67 2.87 2019 006 3.27 4.32 3.37 3.97 4.58 2.87 2019 007 3.29 4.28 3.30 3.92 4.50 2.88 2019 008 3.29 4.23 3.21 3.82 4.42 2.87 2019 009 3.18 4.15 3.09 3.65 4.28 2.79 2019 010 3.09 4.07 2.98 3.42 4.12 2.62 2019 011 2.99 3.94 2.83 3.22 3.98 1.95 2019 012 2.90 3.82 2.66 3.05 3.79 1.89 2019 013 2.81 3.69 2.65 3.12 3.76 1.52 2019 014 2.81 3.59 2.51 3.01 3.66 0.87 2019 015 2.79 3.56 2.47 2.81 3.57 0.80 2019 016 2.79 3.41 2.43 2.59 3.57 0.76 2019 017 2.74 3.37 2.37 2.22 3.40 0.72 2019 018 2.62 3.24 2.28 2.13 3.45 0.46 2019 019 2.39 3.10 2.11 1.76 3.16 0.20 2019 020 2.25 2.86 1.96 1.50 2.93 0.20 2019 021 2.06 2.80 1.84 1.32 2.72 0.20 2019 022 2.02 2.76 1.68 1.16 2.67 0.20 2019 023 2.02 2.76 1.75 1.17 2.74 0.20 2019 024 2.06 2.72 1.70 1.34 2.76 0.20 2019 025 1.98 2
Answered Same DayApr 09, 2021

Answer To: CPS125 - Term Project – Winter 2020 This project is a team project. It must be done in teams of two,...

Aditya answered on Apr 10 2021
157 Votes
#include
#include
#include
int max_index(float *a, int n)
{
if(n <= 0)
return -1
;
int i, max_i = 0;
float max = a[0];
for(i = 1; i < n; ++i)
{
if(a[i] > max)
{
max = a[i];
max_i = i;
}
}
return max_i;
}
int min_index(float *a,int n)
{
if(n <= 0)
return -1;
int i, min_i = 0;
float min = a[0];
for(i = 1; i < n; ++i)
{
if(a[i] < min)
{
min = a[i];
min_i = i;
}
}
return min_i;
}
void getdate(int i)
{
int a = i ;
if(i<=31)
{
printf(" %d/1 \n",i);
}
else if((i>31) && (i<=59) )
{
i = i-31;
printf(" %d/2 \n",i);
}
else if((i>59) && (i<=90) )
{
i = i-59;
printf(" %d/3 \n",i);
}
else if((i>90) && (i<=120) )
{
i = i-90;
printf(" %d/4 \n",i);
}
else if((i>120) && (i<=151) )
{
i = i-120;
printf(" %d/5 \n",i);
}
else if((i>151) && (i<=181) )
{
i = i-151;
printf(" %d/6 \n",i);
}
else if((i>181) && (i<=212) )
{
i = i-181;
printf(" %d/7 \n",i);
}
...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here