第 2 楼
Key Concepts: file output, formattingOne model of population growth gives the current population,
P, in terms of an initial population
P0, a constant
k, and a time
t in years (measured from
t = 0, when
P0 was measured). The equation for this model is as follows:
P =
P0ektThis model reasonably estimated the U.S. population from 1790 to 1860 with
k = 0.0298. The 1790 population was 3.9 million.Your task is to write a program to generate a .csv file that has a line for each year the above model can reasonably estimate. Each line should have the year, a comma, and the estimated population in that year formatted with three decimal places. The first few lines should look like this: 1790, 3.900
1791, 4.018
1792, 4.140
1793, 4.265
1794, 4.394
1795, 4.527Once you've successfully generated this file, wirte fortran code to generate a graph of the data. The graph should be properly labeled.Then change the program to generate a second CSV file and generate a new graph. This time, change the 1790 population to a value of your choosing and change the growth constant to -0.03.
ReportPrepare a report with the following sections (use the headings provided and add more sections in the same style as necessary):· Code· Original output file· Graph from the original file· Second output file· Graph for the second file 先帮忙看看这个,星期一要交,跪求各位大侠