MAT-16 Modeling and Simulation HW Background We will construct a simple model of
ID: 3569221 • Letter: M
Question
MAT-16 Modeling and Simulation HW
Background
We will construct a simple model of population growth in MATLAB. The model should produce an output table showing population by year as well as a graph summarizing the growth. Use the model to project the population of metropolitan Atlanta, Georgia (in the census this is called the Metropolitan Statistical Area or MSA). The population in that area has been growing exponentially since 1960. Between 1960 and 1990 the Atlanta MSA grew at an approximate rate of 2.7% per year. The base
population in 1960 was 1,312,474, as shown in the table below. Your equation will be
where n is the number of years after 1960, i.e. for 1970, n=10.
The values from Wikipedia for decades up until 1990 are:
Atlanta Population
Year
Decade
City
MSA
1850
1
2,572
1860
2
9,554
1870
3
21,789
1880
4
37,409
1890
5
65,533
1900
6
89,872
419,375
1910
7
154,839
522,442
1920
8
200,616
622,283
1930
9
270,366
715,391
1940
10
302,288
820,579
1950
11
331,314
997,666
1960
12
487,455
1,312,474
1970
13
496,973
1,763,626
1980
14
425,022
2,233,324
1990
15
394,017
2,959,950
For your information MATLAB also has a function to create a polynomial fit. To use MATLAB to create a polynomial curve fit, you can use the command polyfit().
The command:
C = polyfit(x_data,y_data, N)
Will fit the data to an Nth order polynomial with coefficients in the vector C.
To create a quadratic equation fit you would use polyfit with N=2.
Therefore the equation for the curve fit would be: C(1)x^2 + C(2)x + C(3).
MAT-16 Modeling and Simulation HW
Instructions
Write a MATLAB program to calculate and output to the command window and a figure window the answers to the following questions.
Using the exponential model, create and output to the command window a table showing the projected population for every year from 2000 to 2010. You can find the year 2000 and 2010 populations for the Atlanta MSA from Wikipedia
at: Atlanta Demographics
Plot the Wikipedia data using a * symbol for 2000 and 2010, and exponential fit on the same figure. Title and label appropriately.
Questions to be answered in command window based on program calculations:
What does the model predict the year 2000 population to be? What is predicted for 2010? How close do these come to the correct answer? If the Atlanta MSA continues to grow at the same rate, when will the metropolitan population reach 6 million? Discuss the limitations of this type of model for population growth. What types of events can cause drastic changes (up or down) in the rate of growth?
Year
Decade
City
MSA
1850
1
2,572
1860
2
9,554
1870
3
21,789
1880
4
37,409
1890
5
65,533
1900
6
89,872
419,375
1910
7
154,839
522,442
1920
8
200,616
622,283
1930
9
270,366
715,391
1940
10
302,288
820,579
1950
11
331,314
997,666
1960
12
487,455
1,312,474
1970
13
496,973
1,763,626
1980
14
425,022
2,233,324
1990
15
394,017
2,959,950
Explanation / Answer
t=-110:10:30;
city=[2572,9554,21789,37409,65533,89872,154839,200616,270366,302288,331314,487455,496973,425022,394017];
t1=-60:10:30;
MSA=[419375,522442,622283,715391,820579,997666,1312474,1763626,2233324,2959950];
C1=polyfit(t,city,2);
city_new=C1(1)*t.^2+C1(2)*t+C1(3);
C2=polyfit(t1,MSA,2);
MSA_new=C2(1)*t1.^2+C2(2)*t1+C2(3);
figure
plot(t,city,t,city_new,'r')
grid on
legend('actual','interpolated')
figure
plot(t1,MSA,t1,MSA_new,'r')
grid on
legend('actual','interpolated')
t3=40:50;
city_estimated=C1(1)*t3.^2+C1(2)*t3+C1(3);
MSA_estimated=C2(1)*t3.^2+C2(2)*t3+C2(3);
table(:,1)=1960+t3;
table(:,2)=city_estimated;
table(:,3)=MSA_estimated;
disp(table)
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.