# Finding the fit $A\ T^a+B\ T^{-b}\ \rightarrow\ C\ T^c\exp{(\small{-\frac d T})}$ for an interval? (specifically in Mathematica)

I'm given an expression

$$A\ T^a+B\ T^{-b},$$ $$\text{with} \ \ \ \ A,B>0,\ \ \ \ a,b\in(0,1),$$

but the plus sign "$+$" is a problem for my purposes. I want to make a fit of the following form:

$$C\ T^c\exp{(\small{-\frac d T})}.$$

The approximation should take the closest values to the original function in an interval from $T_1$ to $T_2$, both positive. The term $A\ T^a$ clearly dominates the original expression for big $T$, as well as $C\ T^c$ when the exponential gets turned off. Regardless of that, the point is that I'd have an idea to do this in a neighborhood around a point, but here I'm convened with a whole interval, especially the values after $T_1$.

What is the general theory for this?

And specifically, I'd like to know how to do this in Mathematica.

-

As for Mathematica here is a variant with NonlinearModelFit[]. It uses several points (n=50) to approximate the required parameters in a given model:

A = 2; B = 3; a = 1/2; b = 1/3; T1 = 1; T2 = 20;
f[t_] = A t^a + B t^b;
n = 50; tb = Table[{k, f[k]}, {k, T1, T2, (T2 - T1)/n}];
model = C t^c Exp[-d/t];
g[t_] = model /. NonlinearModelFit[tb, model, {C, c, d}, t][[1, 2]]


gives for $g(t)$

4.8569 e^{0.0326438/t} t^{0.419195}.

-
Please note it's not necessary to dig into the structure of the FittedModel object. It's cleaner and safer to do g = NonlinearModelFit[tb, model, {C, c, d}, t] to get an evaluatable function (try g[2]), or Normal[g] to get the expression itself. – Szabolcs Jan 9 '12 at 14:03
This is really great, thank you. Do you maybe know or have some hint how one theoretically gets to this? – NikolajK Jan 10 '12 at 9:16
@Nick Kidman I don't know how it is done in Mathematica, but probably it is some variant of the non-linear least squares method en.wikipedia.org/wiki/Non-linear_least_squares – Andrew Jan 10 '12 at 10:42