cancel
Showing results for
Did you mean:
cancel
Showing results for
Did you mean:

4-Participant

## Multiple Function Fitting

I am somewhat new to fitting data using Mathcad (15), so I apologise if this is a stupid question.

I have experimental data on the temperature dependence of the molar volume (Vm) and isochoric specific heat (Cv) of a compound.The former is related to the internal energy, the latter to the first derivative of the internal energy. If I use Debye-based models, then the Debye temperature is a common variable for both functions, the molar volume includes two additional variables. The number of data points for the two independent data sets is different. I can fit each function separately, but I wish to fit them simultaneousy to determine the best estimate of the Debye temperature.

Is there a simple way of carrying out multiple function fitting in Mathcad?

Many thanks

Kevin

1 ACCEPTED SOLUTION

Accepted Solutions
24-Ruby IV
(To:kevinsknight)

So you are looking for a common fit value thetaD ?

maybe the attached file helps.

For convenience I embedded the data into the file.

I got rid of your ranges "i" and used vectorization instead of the indexed variables.

Instead of using a single value to fit (the result of the SSD function) I give Mathcad the full vector of difference values to play with. This may give better results sometimes but in your case there seems to be no difference.

The sorting of the data in Vm is not necessary but makes for a nicer plot.

8 REPLIES 8
23-Emerald I
(To:kevinsknight)

Don't worry, there's no such thing as a 'stupid question'.

Luc.

4-Participant
(To:LucMeekes)

I have uploaded the heat capacity fit, that works, and the molar volume, that doesn't (and I'm sorry, I don't know why).

What I am trying to do is to simultaneously fit the two sets of data to the Debye expressions to derive a self-consistent Debye temperature. If this is possible, I will try more sophisticated models to the data that should fit them better.

24-Ruby IV
(To:kevinsknight)

In the definition of SSD you erroneously used Vm instead of V.

If you change that the Vm.sheet works, too.

4-Participant
(To:Werner_E)

Thanks for pointing that out. Long day and brain not in gear

24-Ruby IV
(To:kevinsknight)

So you are looking for a common fit value thetaD ?

maybe the attached file helps.

For convenience I embedded the data into the file.

I got rid of your ranges "i" and used vectorization instead of the indexed variables.

Instead of using a single value to fit (the result of the SSD function) I give Mathcad the full vector of difference values to play with. This may give better results sometimes but in your case there seems to be no difference.

The sorting of the data in Vm is not necessary but makes for a nicer plot.

4-Participant
(To:Werner_E)

Thank you so much for the help. This is using bits of Mathcad I have not used before, so some homework will be necessary for me to fully understand.

Best regards

Kevin

24-Ruby IV
(To:kevinsknight)

@kevinsknight wrote:

Thank you so much for the help. This is using bits of Mathcad I have not used before, so some homework will be necessary for me to fully understand.

Best regards

Kevin

Feel free to come back and ask if there is any question

24-Ruby I
(To:kevinsknight)