Skip to main content
1-Visitor
July 14, 2017
Solved

How to generate a best fit curve Z = aX^bY^c

  • July 14, 2017
  • 5 replies
  • 4462 views

Hello,

 

I have a set of data which I divided into 3 vectors X, Y, and Z. I am trying to generate a best fit equation for this data based on the formula Z = a*X^b*Y^c

 

Is there a function in Mathcad to determine a best-fit equation based on the above formula.

 

This question was posted before, but was lost when the PTC Community forum got migrated into a new platform, so I am trying to get back the answers I obtained.

 

Thanks,

 

Felipe Loo

Best answer by Werner_E

Here are some suggestions as to how to achieve what you demanded for.

5 replies

25-Diamond I
July 14, 2017

You may have a look at the Mathcad function "genfit".

EDIT:: genfit will not work with 2 independent variables. The multidimensional analogon in Mathcad is "multidfit".

 

Or you could use a solve block with "minerr"

 

EDIT: I didn't look too closely at the type of your equation. Now that I did I guesss that Alan's suggestion below is the best appraoch. You may use "polyfit"/"polyfitc" to do so.

19-Tanzanite
July 15, 2017

Or take logs and use a linear fit.

 

Alan

24-Ruby IV
July 15, 2017

@nanay001 wrote:

Hello,

 

I have a set of data which I divided into 3 vectors X, Y, and Z. I am trying to generate a best fit equation for this data based on the formula Z = a*X^b*Y^c

 

Is there a function in Mathcad to determine a best-fit equation based on the above formula.

 

This question was posted before, but was lost when the PTC Community forum got migrated into a new platform, so I am trying to get back the answers I obtained.

 

Thanks,

 

Felipe Loo


Sorry, it will be not a curve but a surface.

Give please us please your 3 vectirs!

24-Ruby IV
July 15, 2017

@nanay001 wrote:

Hello,

 

I have a set of data which I divided into 3 vectors X, Y, and Z. I am trying to generate a best fit equation for this data based on the formula Z = a*X^b*Y^c

 

Is there a function in Mathcad to determine a best-fit equation based on the above formula.

 

This question was posted before, but was lost when the PTC Community forum got migrated into a new platform, so I am trying to get back the answers I obtained.

 

Thanks,

 

Felipe Loo


Sorry, it will be not a curve but a surface.

Send please please your 3 vectirs!

Werner_E25-Diamond IAnswer
25-Diamond I
July 15, 2017

Here are some suggestions as to how to achieve what you demanded for.

24-Ruby IV
July 15, 2017