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

Units issue when defining a function

SOLVED
Newbie

Units issue when defining a function

Attached illustrates the problem where I calculate the constants a and b of a linear function. Next I define the function, but it doesn't really work - only partly.

What am I doing wrong?

Kind regards,

Michael

Tags (2)
1 ACCEPTED SOLUTION

Accepted Solutions

Re: Units issue when defining a function

Notice that the "a" in the function definition and the "a" in the function call look different? That's because the label for one is set to "variable". but for the other it's set to "function". They need to be set the same. Also, the symbolic processor does not really understand units. Notice that the "m" and "s" from the symbolic evaluation display as variables, not units. Split the symbolic evaluation from the function definition. When you call the function you also have "s" as a variable, which is not defined, rather than the defined unit for seconds. If you fix the other problems Mathcad should fix that for you automatically though.

View solution in original post

2 REPLIES 2

Re: Units issue when defining a function

Notice that the "a" in the function definition and the "a" in the function call look different? That's because the label for one is set to "variable". but for the other it's set to "function". They need to be set the same. Also, the symbolic processor does not really understand units. Notice that the "m" and "s" from the symbolic evaluation display as variables, not units. Split the symbolic evaluation from the function definition. When you call the function you also have "s" as a variable, which is not defined, rather than the defined unit for seconds. If you fix the other problems Mathcad should fix that for you automatically though.

View solution in original post

Re: Units issue when defining a function

Got it,

Thanks!

Announcements