Skip to main content
1-Visitor
March 21, 2018
Solved

Function won't recognize a variable when it is put as a power of e, (e^x). x is "undefined"

  • March 21, 2018
  • 1 reply
  • 3786 views

I'm using MathCad 3.1 and for some reason x in my function is always labeled as undefined and I can't figure out why. I played around with labeling the variables and such but it won't work. Normal functions work just fine. Is MathCad not able to do this?

 

A solution to a similar problem was done in mathcad 3.1 that worked fine, I could just enter 0 for x but i need to be able to use dp/dx in other equations

 HW2.png

 

Best answer by LucMeekes

Why are there brackets around x, like '(x)'   ?

And the argument to the exponential function must be unitless. You have defined x with unit of um, and have alpha with unit of 1/um. You should not put in an extra 'um' in the exponent !

Then, Pn0 is undefined... This triggers an error, but Mathcad is known to misplace error pointers.

Finally: apparently you cannot evaluate the function you define immediately.

LM_20180321_Variable.png

 

Success!
Luc

1 reply

LucMeekes23-Emerald IVAnswer
23-Emerald IV
March 21, 2018

Why are there brackets around x, like '(x)'   ?

And the argument to the exponential function must be unitless. You have defined x with unit of um, and have alpha with unit of 1/um. You should not put in an extra 'um' in the exponent !

Then, Pn0 is undefined... This triggers an error, but Mathcad is known to misplace error pointers.

Finally: apparently you cannot evaluate the function you define immediately.

LM_20180321_Variable.png

 

Success!
Luc

Walks1-VisitorAuthor
1-Visitor
March 21, 2018

Thank you I updated the picture and ya, I should have double checked the first picture I posted. Pn0 was defined but wasn't in the screen shot and the brackets were unnecessary but I don't think they should matter. I deleted the units but it still won't work.

23-Emerald IV
March 21, 2018

Check again, I updated my post.