Problem 1- approx3

We are going to add a point (0,0) and picewise fit the data from T=0 to T=25K and from T=25 to T.

c03 = {{0, 0}, {10, 2.8}, {15, 7.}, {20, 10.8}, {25, 14.1}} ;

c13 = {{25, 14.1}, {30, 16.5}, {50, 21.4}, {70, 23.3}, {100, 24.5}, {150, 25.3}, {200, 25.8}, {250, 26.2}, {298, 26.6}} ;

<<Statistics`NonlinearFit`

First fit

hetC025 = NonlinearFit[c03, a1 * x/1 + a2 * x^2 + a3 * x^3, {x}, {{a1, 1}, {a2, .1}, {a3, .1}}, MaxIterations→1000, Method→Automatic]

-0.269951 x + 0.0708961 x^2 - 0.00150373 x^3

{a1→ -0.269951, a2→0.0708961, a3→ -0.00150373}

Second fit

hetC25up = NonlinearFit[c13, ao + a1 * x/1 + a2 * x^2 + am21/x^2, {x}, {{ao, 1}, {a1, 1}, {a2, .1}, {a3, .1}, {am2, 0}}, MaxIterations→1000, Method→Automatic]

22.8569 - 5997.67/x^2 + 0.0239328 x - 0.0000387671 x^2

{ao→22.8569, a1→0.0239328, a2→ -0.0000387671, a3→0, am2→ -5997.67}

Fig03 = ListPlot[c03, PlotRange-> {{0, 300}, {0, 35}}, Frame→True, Prolog→AbsolutePointSize[6]] ;

[Graphics:../HTMLFiles/MATH5_TUT_1_819.gif]

Heat capacity from 0 to 25K

cp03[x_] := -0.269951 x + 0.0708961 x^2 - 0.00150373 x^3

Fig03cp = Plot[{cp03[x]}, {x, 0, 300}, Frame→True, PlotRange-> {{0.1, 300}, {0, 35}}, PlotStyle→ {Thickness[0.01]}]

[Graphics:../HTMLFiles/MATH5_TUT_1_822.gif]

-Graphics -

Show[{Fig03, Fig03cp}, Prolog→AbsolutePointSize[6]]

[Graphics:../HTMLFiles/MATH5_TUT_1_825.gif]

-Graphics -

Fig13 = ListPlot[c13, PlotRange-> {{0, 300}, {0, 35}}, Frame→True, Prolog→AbsolutePointSize[6]] ;

[Graphics:../HTMLFiles/MATH5_TUT_1_828.gif]

Heat capacity from 25 to T

cp13[x_] := 22.8569 - 5997.67/x^2 + 0.0239328 x - 0.0000387671 x^2

Fig13cp = Plot[{cp13[x]}, {x, 0, 300}, Frame→True, PlotRange-> {{0.1, 300}, {0, 35}}, PlotStyle→ {Thickness[0.01]}] ;

[Graphics:../HTMLFiles/MATH5_TUT_1_831.gif]

-Graphics -

Show[{Fig13, Fig13cp}, Prolog→AbsolutePointSize[6]]

[Graphics:../HTMLFiles/MATH5_TUT_1_834.gif]

-Graphics -

Picewise integration from 0k to 25K

s025 = ∫_0^25cp03[x]/xx

7.57432

second integration from 25K to T

s25273 = ∫_25^273cp13[x]/xx

54.3866

s25298 = ∫_25^298cp13[x]/xx

56.7045

s0273 = s025 + s25273

61.9609

s0298 = s025 + s25298

64.2788

From Atkins, Sf at 298 K = 64.81 J K^(-1)mol^(-1)
Our result is only good to 2 sig figs therefore we get 64. J K^(-1)mol^(-1).

Comparison of the fitting and the data

c0 = {{0, 0}, {10, 2.8}, {15, 7.}, {20, 10.8}, {25, 14.1}, {30, 16.5}, {50, 21.4}, {70, 23.3}, {100, 24.5}, {150, 25.3}, {200, 25.8}, {250, 26.2}, {298, 26.6}} ;

figcom = Plot[{cp03[x], cp13[x]}, {x, 0, 300}, Frame→True, PlotRange-> {{0.1, 300}, {0, 35}}, PlotStyle→ {Thickness[0.01]}]

[Graphics:../HTMLFiles/MATH5_TUT_1_852.gif]

-Graphics -

Fig0 = ListPlot[c0, PlotRange-> {{0, 300}, {0, 35}}, Frame→True, Prolog→AbsolutePointSize[6]] ;

[Graphics:../HTMLFiles/MATH5_TUT_1_855.gif]

Comparing with the previous fittings, this is a better match.

Show[{Fig0, figcom}, Prolog→AbsolutePointSize[6]] ;

[Graphics:../HTMLFiles/MATH5_TUT_1_857.gif]


Created by Mathematica  (October 29, 2006) Valid XHTML 1.1!