Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

** Community Tip** - Stay updated on what is happening on the PTC Community by subscribing to PTC Community Announcements.
X

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Feb 07, 2013
08:21 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Feb 07, 2013
08:21 PM

Extract Real parts from an equation??

Hello,

I have attached my mathcad sheet (ver 14).

I have an equation, and I need to extract the real and imaginary parts. However, my equation is full of variables, and mathcad says "this variable is undefined". It is undefined because it isn't known, its just a variable. I don't know how to tell analytix that my variable is just a variable, it could be any number.

Anyway, I would LOVE LOVE LOVE if somebody could help me!

Thanks!

2 REPLIES 2

Feb 07, 2013
09:42 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Feb 07, 2013
09:42 PM

"variable is undefined" is an error mesaage from the numeric engine. All variables have to be defined, otherwise a numerical evaluation is not possible. The way to satisfay the numerics is either use the boolean "=" to make an equation (which you may solve symbolically for a distinc variable) or turn the assignment into a function, e.g. write U(R,I):=R*I instead of U:=R*I.

In your worksheet there is no equation, at least not at the and. The expression you have at the end could be separeted symbolically in real and imaginary part by using the Re(...) and Im(...) function, but Mathcad can't do that, as all of your variables could be complex numbers, too. Adding the modifyer "assume, ALL=real" or even better "assume,ALL>0" if thats appropriate would do the job, but not in case of your expression because of the square root of (x+yi). Guess you couldn't separate real and imaginary part by hand either.

Feb 07, 2013
10:26 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Feb 07, 2013
10:26 PM

Addendum:

With a little manual calculation to split the square root of a generic complex number in real an imaginary part (Mathcad is not of any help here) you get the desired values.

Look at the attached file if its what you want