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

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Regress and units

ValeryOchkov
24-Ruby IV

Regress and units

Units-In-Regress.png

7 REPLIES 7

I'm surprised this worked at all! Wat units should y have? The polynomial (given x has units of length) has different units for each term. Version 15 solved the issue by refusing units; but if you put in "UnitsOf()" you get the same answer,

Result as attached would be OK

Capture.PNG

Regards

Andy

Yes, it would!

The challenge is to get Mathcad to get the units right for the automatic solution.

That will be the challenge to the PTC programmers to 'fix' the regress, & other, function(s).

Prime itself seems to be capable of dealing with arrays of variables that do not have to have any unit relationships what-so-ever.

In this instance Prime has calculated the numeric answer for the coefficients A, B & C.

It should also know the unit that associates with the coefficient & perhaps it only needs to append this to the result it already gives.

Regards

Andy

But all is OK in the tandem regtess+interp:

Units-In-Regress-Interp.png

So, Prime is keeping the units but not showing them in k?

That's a little scary!

One feature I've thought about requesting is the ability to provide a scaling vectot to these many pre-packed functions.

The scaling vector would carry both the base dimensions for each of the elements, but would also carry the typical magnitude of the relevant 'signal'.

This would mean that after dividing through byb that scaling vecator all the values would be dimensionless and near unity, which generally makes these types of pre-pack functions really work well.

So we would have 'regressU' which would wrap a regular regress, with similar methods for the other functions.It would even cope with diferentials, integrals and power law difference between the input and output. It's all 'per unit' style scaling. If only those mathematicians had proper named dimensions !

Announcements

Top Tags